Hi everybody,

 

I am using scintilla for a script editor (programming operator terminal device). Script commands do not follow any usual syntax. To support coloring of keywords, identifiers etc, I am using SCLEX_CONTAINER and SCN_STYLENEEDED notification according to the instructions in a documentation and html file about using container.

 

Everything works but with a strange behavior.

 

  1. When a file is loaded and displayed, only the first line is styled.
  2. If I click (mouse) on any line below, text is colored up to this line in batches of 2-3 lines with a time difference of < 1 sec between coloring of each 3 lines.
  3. If i scroll down with a key, text is immediatelly colored.
  4. If a resize a window, text is immediatelly colored but only visible text.
  5. When typing in a new (empty) file, coloring works great.

 

Since the application is a bidirectional (user can modify the script or user can use integrated dialogs to define behavior and a script is automatically modified to reflect changes in dialogs), I need to modify parts of the script programatically. To do this, I am using search and replace via a target. Works great. However, when a part of the file (fully colored) is replaced, replaced part is not colored at all. To color it, I need to scroll to that part from the beginning of the document.

 

I tried with SCI_COLOURISE message sent upon openning the document or after replacing part of it but it does not work.

 

What am I doing wrong?

 

Best regards,

 

Zoran Todorović

www.sca.co.yu

 

_______________________________________________
Scintilla-interest mailing list
[email protected]
http://mailman.lyra.org/mailman/listinfo/scintilla-interest

Reply via email to