TextEditorDefs flashSpeedIntervalMs

Hi Jules, would it be possible to get access to set this value? I’m having to hard code it right now to match the standard mac blink rate. (~500ms?) It would be nice to have the option to turn off blinking as well.


and I would like a choice of caret width (1 pixel instead of 2) just a reminder!

In fact the best thing would probably be to have the lookandfeel return a cursor component that draws and flashes itself. I’ll see what I can do.

Oh Jules!

Hey Jules, thanks for the CaretComponent class. It seems I have to use a workaround type approach to get it to work though. I don’t believe this would be intentional, but maybe I’m missing something or maybe I’m just off base.

//Create a new text editor (Creates caret from default LookAndFeel)  
TextEditor * tx = new TextEditor();

//Set specific LookAndFeel (too late, caret is already created)

//Zero out the caret by hiding it.

//Now zeroed, set to visible again to create from current LookAndFeel (now myTextEditorLookAndFeel)

I think the idea is that you override the global look and feel, or the look and feel of the TextEditor’s parent Component?

i suspect jules just needs to tweak the TextEditor’s lookAndFeelChanged() implementation

Ah, maybe I forgot to make it refresh the caret comp when the l+f is changed… I’ll check that.