Re: Text Color
- From: Brendan Murphy <bmurphy@xxxxxxxxxxxxxxxxxxxxx>
- To: ftcdev@xxxxxxxxxxxxx
- Date: Mon, 24 Mar 2008 09:55:51 -0500
Ron Benditt wrote:
What is the best way to initialize the display with a starting
color? I would think that the changeTextColor method would do it,
but it does not seem to work when I have nothing selected. I see
that for initializing the font and the font size, there are
defaultFont and defaultFontSize properties. Any chance of adding a
defaultFontColor property?
One way to do this is to fill in the DefaultParagraphStyle event.
See the FTDocument.createDefaultParagraphStyle method as an
example of what you should put in it. This gives you control of
the default paragraph style when new paragraphs are created.
Another way is to save the current selection range, select
everything, call changeTextColor, and then reselect the previously
selected range and then call update.
The DefaultFont/Size properties were their mainly for tab support
in order to give tabs proper dimensions. Yes I can give you a
default color property which would tie into the
createDefaultParagraphStyle method.
FTC Website: www.truenorthsoftware.com/Realbasic/FormattedText.html
Set List Options (digest and vacation modes): www.freelists.org/list/ftcdev
List Archive: www.freelists.org/archives/ftcdev
Unsubscribe: Send email to ftcdev-request@xxxxxxxxxxxxx with "unsubscribe" in
the subject field.
- Follow-Ups:
- Re: Text Color
- From: Ron Benditt
- References:
- Text Color
- From: Ron Benditt
Other related posts:
- » Text Color
- » Re: Text Color
- » Re: Text Color
- Re: Text Color
- From: Ron Benditt
- Text Color
- From: Ron Benditt