Own IWBasic 2.x ? -----> Get your free upgrade to 3.x now.........
Started by Andy, March 25, 2020, 06:04:06 am
0 Members and 1 Guest are viewing this topic.
for a = 0 to MaxLines - 1 CONTROLCMD(w1,1,@RTGETLINE,a,line$,255) WordPerLine2(w1,1,a+1,Line$) lc = ++ If lc = 25 lc = 0 setfocus w1,STATIC_4 endif next a
': Disable the event mask, for increased speed mask = CONTROLCMD (win, 1, @RTGETEVENTMASK) controlcmd win, 1, @rtseteventmask, 0 SendMessage(hEdit, WM_SETREDRAW, 0, 0) FormatCode(0,-1) :' Call the routine for syntax highlighting SendMessage(hEdit, WM_SETREDRAW, 1, 0) ': Restore the event mask controlcmd win, 1, @rtseteventmask, mask
SendMessage(rHandle,EM_SETSEL,(#i[GetLine].StartPos[c1]+Offset),(#i[GetLine].EndPos[c1]+Offset))'CONTROLCMD WinIn,ControlIn,@RTSETSELECTION,(#i[GetLine].StartPos[c1]+Offset),(#i[GetLine].EndPos[c1]+Offset)CONTROLCMD WinIn,ControlIn,@RTSETSELCOLOR,#h[GetLine].Colour[c1]
QuoteText FormattingAn application can send messages to a rich edit control to format characters and paragraphs and to retrieve formatting information. Paragraph formatting attributes include alignment, tabs, indents, and numbering. For characters, you can specify typeface, size, color, and effects such as bold, italic, and protected.You can apply paragraph formatting by using the EM_SETPARAFORMAT message. To determine the current paragraph formatting for the selected text, use the EM_GETPARAFORMAT message. The PARAFORMAT structure is used with both messages to specify paragraph formatting attributes.You can apply character formatting by using the EM_SETCHARFORMAT message. To determine the current character formatting for the selected text, you can use the EM_GETCHARFORMAT message. The CHARFORMAT structure is used with both messages to specify character attributes.You can also use EM_SETCHARFORMAT and EM_GETCHARFORMAT messages to set and retrieve the default character formatting, which is the formatting applied to any subsequently inserted characters. For example, if an application sets the default character formatting to bold and the user then types a character, that character is bold.The default character formatting is applied to newly inserted text only if the current selection is empty. Otherwise, the new text assumes the character formatting of the text it replaces. If the selection changes, the default character formatting changes to match the first character in the new selection.