0

SciTE text editor Version 3.6.0 compiled for GTK+ 3.16.7, Aug 17 2015 10:20:12.

Python script code:

print(" at data line " ) # output in red   color
print(" at line ")       # output in black color
print(" at . line ")     # output in red   color

run from within SciTE gives in SciTE output panel:

output in SciTE output panel

It seems to have something to do with " at ... line " what triggers the color change from black output to red.

Can someone confirm this behavior and/or even explain how it comes?

Claudio
  • 7,474
  • 3
  • 18
  • 48

1 Answers1

0

Colored lines in SciTE output panel are definitely not a bug. The behavior of this feature for highlighting error messages and probably also other purposes seems to be mostly undocumented. The colors and the trigger patterns vary in different SciTE versions.

Below a python script including some comments with further information and a picture of the script output in SciTE output panel. The feature allows even to jump to a script/program line specified in the output pane, putting a special mark (it's not a bookmark) in the line numbering column which can be seen in the attached image:

# from https://www.autoitscript.com/forum/topic/90424-red-output-text-from-sqlite/ : 
#   There are some color trigger pattern specified in RecogniseErrorListLine() in LexOthers.cxx.

# Line 4
# Line 5

print("! green output")
print("> blue output")
print("- mint green output")
print("+ dark blue output")
print("on2ClickJumpToAndSelectLine(5) : < dark green output")
print("on2ClickJumpToAndSelectLine:18:  < brown-red output")
print("(1) : = < dark green output > on2Click-NewFile")
print(" at ?x line < red output (leading space is significant)")
print("ERROR < black output")
print("jumpTo (4) warning < dark green output")

# Line 18
# ---

#   style.errorlist.2=fore:#800080
#   SCI_STYLEGETFORE(int styleNumber)

Below two pictures. One of the output pane with the python script output and the other of the editing area of SciTE after the jump to a line by double clicking the appropriate line in the output panel:

SciTE output panel

SciTE edit panel

Claudio
  • 7,474
  • 3
  • 18
  • 48