Appends text to rich text box, applying current format if set.
Takes richTextBoxID (Int) and text (String).
Returns 1 on success, 0 if rich text box not found.
BGI GUI
Parameters & Returns
Parameters
richTextBoxIDInt
textString
Returns
Int
Quick Summary
Appends text to rich text box, applying current format if set.
Takes richTextBoxID (Int) and text (String).
Returns 1 on success, 0 if rich text box not found.
Technical Exegesis...
Appends text to the end of a rich text box control, preserving existing content. Searches gizmoMap for the rich text box ID. Converts input string from UTF-8 to wide string. Moves caret to end with EM_SETSEL, records start position. Inserts text with EM_REPLACESEL (FALSE to disable undo). If format previously set via bgiSetRichTextFormat, applies stored CHARFORMATW to newly inserted text by selecting the new text range and sending EM_SETCHARFORMAT with SCF_SELECTION. Moves caret back to end.
Appends text to the end of a rich text box control, preserving existing content. Searches gizmoMap for the rich text box ID. Converts input string from UTF-8 to wide string. Moves caret to end with EM_SETSEL, records start position. Inserts text with EM_REPLACESEL (FALSE to disable undo). If format previously set via bgiSetRichTextFormat, applies stored CHARFORMATW to newly inserted text by selecting the new text range and sending EM_SETCHARFORMAT with SCF_SELECTION. Moves caret back to end. Returns 1 on success, 0 if rich text box not found.
This function adds text to the end while preserving existing content and format. If bgiSetRichTextFormat was called first, the stored format (bold, italic, color, font, size) is applied to the newly appended text. If no format was set, text uses the default control format. Use for building formatted logs, chat displays, or sequential text with different styles. Each call to bgiSetRichTextFormat followed by bgiAppendRichText applies that format to the appended portion only.