The setStyling doesn't work for me. I open a new editor and the console. I type some text into the editor. Then I type the following into the console:
But nothings happen. The editor.getStyledText returns 0 for styles.
The following code works fine:
editor.addStyledText(Cell("Hello in blue\n", ))
How can I change the styling of a text?
You need to set the lexer to the container, otherwise scintilla will ignore the calls for startStyling and so on.
Thank you for your incredible quick answer, it works! This plugin is awesome!
I'm definitely new to this Scintilla thing, but I'm wondering if someone knowledgeable can give me a short course on how to do what I want to do, which is basically to programmatically (pythonscript) be able to set (and clear) highlighting sort of like the N++ Search -> "Mark..." or "Mark All" features do.
I can affect text by following the hints earlier in this thread, but I notice if I switch the active file and then come back to the file that I attempted to change the style on, my styling disappears. I'd like it to persist until I turn it off. There are other oddities I see, but this is the biggest.
Perhaps general guidance would be best! Thanks for any help in this regard!
Log in to post a comment.