Textarea selected highlighting

I’m still working on my first Windows to OSX conversion. Have not been able to get the textarea’s selected text to highlight or otherwise indicate the text is selected (i.e. bold, underlined, etc). I have set sel.bold=true, sel.italic=true, etc but it does not seem to work. Does this not work on a Mac?, or what am I missing?

To select the entire text
TextArea1.SelLength= len(TextArea1.Text)

or select the text manually, then

TextArea1.SelBold = True
TextArea1.SelItalic = True


sel.bold = true and sel.italic = True should raise “This item does not exist”…

Thanks Michel,
Actually I mistyped, what I’m actually doing is …
In the controls open event I have…
me.SelBold = True
me.SelItalic = True

And this does not work for me.

When the control opens then nothing is selected.

Or in other words: where do you think you select some text?

Thanks Markus,
So you are saying that it is not actually a property of the textarea to bold/italic text when it is selected but rather a command that has to be applied to the text after it has been selected?

[quote=67970:@Rande Newberry]In the controls open event I have…
me.SelBold = True
me.SelItalic = True[/quote]

So you placed that in the TextArea open event and when you type it does not show as italic ?

You want to make sure to set the TextFont to a font that can show italic, such as Arial. Don’t forget to set the size as well, for instance 12. Easy to do in the inspector.

you can also go

me.TextFont = “Arial”
me.TextSize = 12
me.SelBold = True
me.SelItalic = True

Works fine here in the TextArea open event.

I may have gotten off on a tangent here…
In my code I programmatically select 2 characters in a textarea control, on Windows doing this highlights the text. On the Mac there is no visible change.
The tangent is: I tried to used the bold/italic as an alternate visual indicator that the text was selected (since highlighting did not seem to work)
The characters are being selected and are properly acted upon, it is just that there is no visual indication of which characters are selected.

That seems awfully strange. You mean when you select text, even manually, it does not show ? Here is what I get by pasting a copy of your post into a TextArea, and selecting text by code :

When you select in another Macintosh app, for instance in Xojo, it does not show ? ? ?

How is what you see different ? Can you post a screen capture ? (Shift-cmd-4)