A) I am using scintilla editor and recommend it to you:
http://www.thinbasic.com/community/s...ight=scintilla
B) try these code snippets:
Global typo As String
Global ProgOpt As Options
Type CHARFORMAT3
cbSize As Long
dwMask As DWord
dwEffects As DWord
yHeight As Long
yOffset As Long
crTextColor As DWord
bCharSet As Byte
bPitchAndFamily As Byte
szFaceName As Asciiz * %LF_FACESIZE
szDummy As Integer
End Type
Function setRichTextColor( ByVal NewColors As Long) As Long
Local cf As CHARFORMAT3
cf.cbSize = Len(cf)
cf.dwMask = %CFM_COLOR
cf.crTextColor = NewColors
Call SendMessage(myEdit, %EM_SETCHARFORMAT, %SCF_SELECTION, VarPtr(cf))
End Function
second:
Type Options
ShowOnStartup As Long
KeywordsColor As Long
EquatesColor As Long
StringsColor As Long
RemColor As Long
LastScripts(5) As String * 255
LastScriptsNum As Long
End Type
...
(use in 1) callback part or 2) scanline part for word parser )
CALL setRichTextColor (ProgOpt.KeywordsColor) 'set typo to specific color you wished! :)
...
3) you can use a colorpicker to colorize a single word you like too
bye, largo
Bookmarks