Version: 3.3.0
wxStyledTextCtrl Class Reference

#include <wx/stc/stc.h>

+ Inheritance diagram for wxStyledTextCtrl:

Detailed Description

A wxWidgets implementation of the Scintilla source code editing component.

As well as features found in standard text editing components, Scintilla includes features especially useful when editing and debugging source code. These include support for syntax styling, error indicators, code completion and call tips.

The selection margin can contain markers like those used in debuggers to indicate breakpoints and the current line. Styling choices are more open than with many editors, allowing the use of proportional fonts, bold and italics, multiple foreground and background colours and multiple fonts.

wxStyledTextCtrl is a 1 to 1 mapping of "raw" scintilla interface, whose documentation can be found in the Scintilla website (http://www.scintilla.org/).

Please see wxStyledTextEvent for the documentation of all event types you can use with wxStyledTextCtrl.

Index of the member groups

Links for quick access to the various categories of wxStyledTextCtrl functions:

Library:  wxSTC
Category:  Scintilla Text Editor
See also
wxStyledTextEvent

Public Member Functions

Constructors and related methods

 wxStyledTextCtrl (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxSTCNameStr)
 Ctor. More...
 
 wxStyledTextCtrl ()
 Default ctor. More...
 
 ~wxStyledTextCtrl ()
 Destructor. More...
 
bool Create (wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxSTCNameStr)
 Create the UI elements for a STC that was created with the default ctor. More...
 
Text retrieval and modification

void AddText (const wxString &text)
 Add text to the document at current position. More...
 
void AddStyledText (const wxMemoryBuffer &data)
 Add array of cells to document. More...
 
void InsertText (int pos, const wxString &text)
 Insert string at a position. More...
 
void ChangeInsertion (int length, const wxString &text)
 Change the text that is being inserted in response to wxSTC_MOD_INSERTCHECK. More...
 
void ClearAll ()
 Delete all text in the document. More...
 
void DeleteRange (int start, int lengthDelete)
 Delete a range of text in the document. More...
 
void ClearDocumentStyle ()
 Set all style bytes to 0, remove all folding information. More...
 
int GetCharAt (int pos) const
 Returns the character byte at the position. More...
 
int GetStyleAt (int pos) const
 Returns the style byte at the position. More...
 
void SetSavePoint ()
 Remember the current position in the undo history as the position at which the document was saved. More...
 
wxMemoryBuffer GetStyledText (int startPos, int endPos)
 Retrieve a buffer of cells. More...
 
bool GetReadOnly () const
 In read-only mode? More...
 
wxString GetLine (int line) const
 Retrieve the contents of a line. More...
 
wxString GetTextRange (int startPos, int endPos)
 Retrieve a range of text. More...
 
void ReplaceSelection (const wxString &text)
 Replace the selected text with the argument text. More...
 
void SetReadOnly (bool readOnly)
 Set to read only or read write. More...
 
void SetText (const wxString &text)
 Replace the contents of the document with the argument text. More...
 
wxString GetText () const
 Retrieve all the text in the document. More...
 
void AppendText (const wxString &text)
 Append a string to the end of the document without changing the selection. More...
 
void Allocate (int bytes)
 Enlarge the document to a particular size of text bytes. More...
 
void ReleaseAllExtendedStyles ()
 Release all extended (>255) style numbers. More...
 
int AllocateExtendedStyles (int numberStyles)
 Allocate some extended (>255) style numbers and return the start of the range. More...
 
Searching and replacing

int FindText (int minPos, int maxPos, const wxString &text, int flags=0, int *findEnd=nullptr)
 Find some text in the document. More...
 
void SetTargetStart (int start)
 Sets the position that starts the target which is used for updating the document without affecting the scroll position. More...
 
int GetTargetStart () const
 Get the position that starts the target. More...
 
void SetTargetEnd (int end)
 Sets the position that ends the target which is used for updating the document without affecting the scroll position. More...
 
int GetTargetEnd () const
 Get the position that ends the target. More...
 
void SetTargetRange (int start, int end)
 Sets both the start and end of the target in one call. More...
 
wxString GetTargetText () const
 Retrieve the text in the target. More...
 
void TargetFromSelection ()
 Make the target range start and end be the same as the selection range start and end. More...
 
void TargetWholeDocument ()
 Sets the target to the whole document. More...
 
int ReplaceTarget (const wxString &text)
 Replace the target text with the argument text. More...
 
int ReplaceTargetRE (const wxString &text)
 Replace the target text with the argument text after \d processing. More...
 
int SearchInTarget (const wxString &text)
 Search for a counted string in the target and set the target to the found range. More...
 
void SetSearchFlags (int searchFlags)
 Set the search flags used by SearchInTarget. More...
 
int GetSearchFlags () const
 Get the search flags used by SearchInTarget. More...
 
wxString GetTag (int tagNumber) const
 Retrieve the value of a tag from a regular expression search. More...
 
void SearchAnchor ()
 Sets the current caret position to be the search anchor. More...
 
int SearchNext (int searchFlags, const wxString &text)
 Find some text starting at the search anchor. More...
 
int SearchPrev (int searchFlags, const wxString &text)
 Find some text starting at the search anchor and moving backwards. More...
 
Overtype

void SetOvertype (bool overType)
 Set to overtype (true) or insert mode. More...
 
bool GetOvertype () const
 Returns true if overtype mode is active otherwise false is returned. More...
 
Cut copy and paste

bool CanPaste () const
 Will a paste succeed? More...
 
void Cut ()
 Cut the selection to the clipboard. More...
 
void Copy ()
 Copy the selection to the clipboard. More...
 
void Paste ()
 Paste the contents of the clipboard into the document replacing the selection. More...
 
void Clear ()
 Clear the selection. More...
 
void CopyRange (int start, int end)
 Copy a range of text to the clipboard. More...
 
void CopyText (int length, const wxString &text)
 Copy argument text to the clipboard. More...
 
void SetPasteConvertEndings (bool convert)
 Enable/Disable convert-on-paste for line endings. More...
 
bool GetPasteConvertEndings () const
 Get convert-on-paste setting. More...
 
void CopyAllowLine ()
 Copy the selection, if selection empty copy the line with the caret. More...
 
Error handling

void SetStatus (int status)
 Change error status - 0 = OK. More...
 
int GetStatus () const
 Get error status. More...
 
Undo and Redo

void Redo ()
 Redoes the next action on the undo history. More...
 
void SetUndoCollection (bool collectUndo)
 Choose between collecting actions into the undo history and discarding them. More...
 
bool CanRedo () const
 Are there any redoable actions in the undo history? More...
 
bool GetUndoCollection () const
 Is undo history being collected? More...
 
void BeginUndoAction ()
 Start a sequence of actions that is undone and redone as a unit. More...
 
void EndUndoAction ()
 End a sequence of actions that is undone and redone as a unit. More...
 
bool CanUndo () const
 Are there any undoable actions in the undo history? More...
 
void EmptyUndoBuffer ()
 Delete the undo history. More...
 
void Undo ()
 Undo one action in the undo history. More...
 
void AddUndoAction (int token, int flags)
 Add a container action to the undo stack. More...
 
Selection and information

int GetLength () const
 Returns the number of bytes in the document. More...
 
int GetCurrentPos () const
 Returns the position of the caret. More...
 
int GetAnchor () const
 Returns the position of the opposite end of the selection to the caret. More...
 
void SelectAll ()
 Select all the text in the document. More...
 
int PositionFromPoint (wxPoint pt) const
 Find the position from a point within the window. More...
 
int PositionFromPointClose (int x, int y)
 Find the position from a point within the window but return wxSTC_INVALID_POSITION if not close to text. More...
 
void GotoLine (int line)
 Set caret to start of a line and ensure it is visible. More...
 
void GotoPos (int caret)
 Set caret to a position and ensure it is visible. More...
 
void SetAnchor (int anchor)
 Set the selection anchor to a position. More...
 
wxString GetCurLine (int *linePos=nullptr)
 Retrieve the text of the line containing the caret. More...
 
int GetColumn (int pos) const
 Retrieve the column number of a position, taking tab width into account. More...
 
int CountCharacters (int start, int end)
 Count characters between two positions. More...
 
int GetLineEndPosition (int line) const
 Get the position after the last visible characters on a line. More...
 
void SetCurrentPos (int caret)
 Sets the position of the caret. More...
 
void SetSelectionStart (int anchor)
 Sets the position that starts the selection - this becomes the anchor. More...
 
int GetSelectionStart () const
 Returns the position at the start of the selection. More...
 
void SetSelectionEnd (int caret)
 Sets the position that ends the selection - this becomes the caret. More...
 
int GetSelectionEnd () const
 Returns the position at the end of the selection. More...
 
void SetEmptySelection (int caret)
 Set caret to a position, while removing any existing selection. More...
 
int GetLineCount () const
 Returns the number of lines in the document. More...
 
bool GetModify () const
 Is the document different from when it was last saved? More...
 
wxString GetSelectedText ()
 Retrieve the selected text. More...
 
void HideSelection (bool hide)
 Draw the selection either highlighted or in normal (non-highlighted) style. More...
 
wxPoint PointFromPosition (int pos)
 Retrieve the point in the window where a position is displayed. More...
 
int LineFromPosition (int pos) const
 Retrieve the line containing a position. More...
 
int PositionFromLine (int line) const
 Retrieve the position at the start of a line. More...
 
int GetTextLength () const
 Retrieve the number of characters in the document. More...
 
int TextWidth (int style, const wxString &text)
 Measure the pixel width of some text in a particular style. More...
 
int TextHeight (int line)
 Retrieve the height of a particular line of text in pixels. More...
 
void MoveCaretInsideView ()
 Move the caret inside current view if it's not there already. More...
 
int LineLength (int line) const
 How many characters are on a line, including end of line characters? More...
 
int LinesOnScreen () const
 Retrieves the number of lines completely visible. More...
 
bool SelectionIsRectangle () const
 Is the selection rectangular? The alternative is the more common stream selection. More...
 
void ChooseCaretX ()
 Set the last x chosen value to be the caret x position. More...
 
int PositionBefore (int pos)
 Given a valid document position, return the previous position taking code page into account. More...
 
int PositionAfter (int pos)
 Given a valid document position, return the next position taking code page into account. More...
 
int PositionRelative (int pos, int relative)
 Given a valid document position, return a position that differs in a number of characters. More...
 
void SetSelectionMode (int selectionMode)
 Set the selection mode to stream (wxSTC_SEL_STREAM) or rectangular (wxSTC_SEL_RECTANGLE/wxSTC_SEL_THIN) or by lines (wxSTC_SEL_LINES). More...
 
int GetSelectionMode () const
 Get the mode of the current selection. More...
 
int GetLineSelStartPosition (int line)
 Retrieve the position of the start of the selection at the given line (wxSTC_INVALID_POSITION if no selection on this line). More...
 
int GetLineSelEndPosition (int line)
 Retrieve the position of the end of the selection at the given line (wxSTC_INVALID_POSITION if no selection on this line). More...
 
int FindColumn (int line, int column)
 Find the position of a column on a line taking into account tabs and multi-byte characters. More...
 
int CharPositionFromPoint (int x, int y)
 Find the position of a character from a point within the window. More...
 
int CharPositionFromPointClose (int x, int y)
 Find the position of a character from a point within the window. More...
 
void SetMouseSelectionRectangularSwitch (bool mouseSelectionRectangularSwitch)
 Set whether switching to rectangular mode while selecting with the mouse is allowed. More...
 
bool GetMouseSelectionRectangularSwitch () const
 Whether switching to rectangular mode while selecting with the mouse is allowed. More...
 
void MoveSelectedLinesUp ()
 Move the selected lines up one line, shifting the line above after the selection. More...
 
void MoveSelectedLinesDown ()
 Move the selected lines down one line, shifting the line below before the selection. More...
 
Multiple Selection and Virtual Space

void SetMultiPaste (int multiPaste)
 Change the effect of pasting when there are multiple selections. More...
 
int GetMultiPaste () const
 Retrieve the effect of pasting when there are multiple selections. More...
 
void SetMultipleSelection (bool multipleSelection)
 Set whether multiple selections can be made. More...
 
bool GetMultipleSelection () const
 Whether multiple selections can be made. More...
 
void SetAdditionalSelectionTyping (bool additionalSelectionTyping)
 Set whether typing can be performed into multiple selections. More...
 
bool GetAdditionalSelectionTyping () const
 Whether typing can be performed into multiple selections. More...
 
void SetAdditionalCaretsBlink (bool additionalCaretsBlink)
 Set whether additional carets will blink. More...
 
bool GetAdditionalCaretsBlink () const
 Whether additional carets will blink. More...
 
void SetAdditionalCaretsVisible (bool additionalCaretsVisible)
 Set whether additional carets are visible. More...
 
bool GetAdditionalCaretsVisible () const
 Whether additional carets are visible. More...
 
int GetSelections () const
 How many selections are there? More...
 
bool GetSelectionEmpty () const
 Is every selected range empty? More...
 
void ClearSelections ()
 Clear selections to a single empty stream selection. More...
 
void AddSelection (int caret, int anchor)
 Add a selection. More...
 
void DropSelectionN (int selection)
 Drop one selection. More...
 
void SetMainSelection (int selection)
 Set the main selection. More...
 
int GetMainSelection () const
 Which selection is the main selection. More...
 
void SetSelectionNCaret (int selection, int caret)
 Set the caret position of the nth selection. More...
 
int GetSelectionNCaret (int selection) const
 Return the caret position of the nth selection. More...
 
void SetSelectionNAnchor (int selection, int anchor)
 Set the anchor position of the nth selection. More...
 
int GetSelectionNAnchor (int selection) const
 Return the anchor position of the nth selection. More...
 
void SetSelectionNCaretVirtualSpace (int selection, int space)
 Set the virtual space of the caret of the nth selection. More...
 
int GetSelectionNCaretVirtualSpace (int selection) const
 Return the virtual space of the caret of the nth selection. More...
 
void SetSelectionNAnchorVirtualSpace (int selection, int space)
 Set the virtual space of the anchor of the nth selection. More...
 
int GetSelectionNAnchorVirtualSpace (int selection) const
 Return the virtual space of the anchor of the nth selection. More...
 
void SetSelectionNStart (int selection, int anchor)
 Sets the position that starts the selection - this becomes the anchor. More...
 
int GetSelectionNStart (int selection) const
 Returns the position at the start of the selection. More...
 
void SetSelectionNEnd (int selection, int caret)
 Sets the position that ends the selection - this becomes the currentPosition. More...
 
int GetSelectionNEnd (int selection) const
 Returns the position at the end of the selection. More...
 
void SetRectangularSelectionCaret (int caret)
 Set the caret position of the rectangular selection. More...
 
int GetRectangularSelectionCaret () const
 Return the caret position of the rectangular selection. More...
 
void SetRectangularSelectionAnchor (int anchor)
 Set the anchor position of the rectangular selection. More...
 
int GetRectangularSelectionAnchor () const
 Return the anchor position of the rectangular selection. More...
 
void SetRectangularSelectionCaretVirtualSpace (int space)
 Set the virtual space of the caret of the rectangular selection. More...
 
int GetRectangularSelectionCaretVirtualSpace () const
 Return the virtual space of the caret of the rectangular selection. More...
 
void SetRectangularSelectionAnchorVirtualSpace (int space)
 Set the virtual space of the anchor of the rectangular selection. More...
 
int GetRectangularSelectionAnchorVirtualSpace () const
 Return the virtual space of the anchor of the rectangular selection. More...
 
void SetVirtualSpaceOptions (int virtualSpaceOptions)
 Set options for virtual space behaviour. More...
 
int GetVirtualSpaceOptions () const
 Return options for virtual space behaviour. More...
 
void SetRectangularSelectionModifier (int modifier)
 On GTK, allow selecting the modifier key to use for mouse-based rectangular selection. More...
 
int GetRectangularSelectionModifier () const
 Get the modifier key used for rectangular selection. More...
 
void SetAdditionalSelForeground (const wxColour &fore)
 Set the foreground colour of additional selections. More...
 
void SetAdditionalSelBackground (const wxColour &back)
 Set the background colour of additional selections. More...
 
void SetAdditionalSelAlpha (int alpha)
 Set the alpha of the selection. More...
 
int GetAdditionalSelAlpha () const
 Get the alpha of the selection. More...
 
void SetAdditionalCaretForeground (const wxColour &fore)
 Set the foreground colour of additional carets. More...
 
wxColour GetAdditionalCaretForeground () const
 Get the foreground colour of additional carets. More...
 
void RotateSelection ()
 Set the main selection to the next selection. More...
 
void SwapMainAnchorCaret ()
 Swap that caret and anchor of the main selection. More...
 
void MultipleSelectAddNext ()
 Add the next occurrence of the main selection to the set of selections as main. More...
 
void MultipleSelectAddEach ()
 Add each occurrence of the main selection in the target to the set of selections. More...
 
Scrolling and automatic scrolling

void SetUseHorizontalScrollBar (bool visible)
 Show or hide the horizontal scroll bar. More...
 
bool GetUseHorizontalScrollBar () const
 Is the horizontal scroll bar visible? More...
 
int GetFirstVisibleLine () const
 Retrieve the display line at the top of the display. More...
 
void LineScroll (int columns, int lines)
 Scroll horizontally and vertically. More...
 
void EnsureCaretVisible ()
 Ensure the caret is visible. More...
 
void ScrollRange (int secondary, int primary)
 Scroll the argument positions and the range between them into view giving priority to the primary position then the secondary position. More...
 
void SetScrollWidth (int pixelWidth)
 Sets the document width assumed for scrolling. More...
 
int GetScrollWidth () const
 Retrieve the document width assumed for scrolling. More...
 
void SetScrollWidthTracking (bool tracking)
 Sets whether the maximum width line displayed is used to set scroll width. More...
 
bool GetScrollWidthTracking () const
 Retrieve whether the scroll width tracks wide lines. More...
 
void SetEndAtLastLine (bool endAtLastLine)
 Sets the scroll range so that maximum scroll position has the last line at the bottom of the view (default). More...
 
bool GetEndAtLastLine () const
 Retrieve whether the maximum scroll position has the last line at the bottom of the view. More...
 
void SetUseVerticalScrollBar (bool visible)
 Show or hide the vertical scroll bar. More...
 
bool GetUseVerticalScrollBar () const
 Is the vertical scroll bar visible? More...
 
void SetFirstVisibleLine (int displayLine)
 Scroll so that a display line is at the top of the display. More...
 
void SetVisiblePolicy (int visiblePolicy, int visibleSlop)
 Set the way the display area is determined when a particular line is to be moved to by Find, FindNext, GotoLine, etc. More...
 
void SetXOffset (int xOffset)
 Set the xOffset (ie, horizontal scroll position). More...
 
int GetXOffset () const
 Get the xOffset (ie, horizontal scroll position). More...
 
void SetXCaretPolicy (int caretPolicy, int caretSlop)
 Set the way the caret is kept visible when going sideways. More...
 
void SetYCaretPolicy (int caretPolicy, int caretSlop)
 Set the way the line the caret is on is kept visible. More...
 
White space

int GetViewWhiteSpace () const
 Are white space characters currently visible? Returns one of wxSTC_WS_* constants. More...
 
void SetViewWhiteSpace (int viewWS)
 Make white space characters invisible, always visible or visible outside indentation. More...
 
int GetTabDrawMode () const
 Retrieve the current tab draw mode. More...
 
void SetTabDrawMode (int tabDrawMode)
 Set how tabs are drawn when visible. More...
 
void SetWhitespaceForeground (bool useSetting, const wxColour &fore)
 Set the foreground colour of all whitespace and whether to use this setting. More...
 
void SetWhitespaceBackground (bool useSetting, const wxColour &back)
 Set the background colour of all whitespace and whether to use this setting. More...
 
void SetWhitespaceSize (int size)
 Set the size of the dots used to mark space characters. More...
 
int GetWhitespaceSize () const
 Get the size of the dots used to mark space characters. More...
 
void SetExtraAscent (int extraAscent)
 Set extra ascent for each line. More...
 
int GetExtraAscent () const
 Get extra ascent for each line. More...
 
void SetExtraDescent (int extraDescent)
 Set extra descent for each line. More...
 
int GetExtraDescent () const
 Get extra descent for each line. More...
 
Cursor

void SetSTCCursor (int cursorType)
 Sets the cursor to one of the wxSTC_CURSOR* values. More...
 
int GetSTCCursor () const
 Get cursor type. More...
 
Mouse capture

void SetMouseDownCaptures (bool captures)
 Set whether the mouse is captured when its button is pressed. More...
 
bool GetMouseDownCaptures () const
 Get whether mouse gets captured. More...
 
void SetMouseWheelCaptures (bool captures)
 Set whether the mouse wheel can be active outside the window. More...
 
bool GetMouseWheelCaptures () const
 Get whether mouse wheel can be active outside the window. More...
 
Line endings

void ConvertEOLs (int eolMode)
 Convert all line endings in the document to one mode. More...
 
int GetEOLMode () const
 Retrieve the current end of line mode - one of wxSTC_EOL_CRLF, wxSTC_EOL_CR, or wxSTC_EOL_LF. More...
 
void SetEOLMode (int eolMode)
 Set the current end of line mode. More...
 
bool GetViewEOL () const
 Are the end of line characters visible? More...
 
void SetViewEOL (bool visible)
 Make the end of line characters visible or invisible. More...
 
void SetLineEndTypesAllowed (int lineEndBitSet)
 Set the line end types that the application wants to use. More...
 
int GetLineEndTypesAllowed () const
 Get the line end types currently allowed. More...
 
int GetLineEndTypesActive () const
 Get the line end types currently recognised. More...
 
int GetLineEndTypesSupported () const
 Bit set of LineEndType enumertion for which line ends beyond the standard LF, CR, and CRLF are supported by the lexer. More...
 
Words

void SetWordChars (const wxString &characters)
 Set the set of characters making up words for when moving or selecting by word. More...
 
wxString GetWordChars () const
 Get the set of characters making up words for when moving or selecting by word. More...
 
int WordStartPosition (int pos, bool onlyWordCharacters)
 Get position of start of word. More...
 
int WordEndPosition (int pos, bool onlyWordCharacters)
 Get position of end of word. More...
 
bool IsRangeWord (int start, int end)
 Is the range start..end considered a word? More...
 
void SetWhitespaceChars (const wxString &characters)
 Set the set of characters making up whitespace for when moving or selecting by word. More...
 
wxString GetWhitespaceChars () const
 Get the set of characters making up whitespace for when moving or selecting by word. More...
 
void SetPunctuationChars (const wxString &characters)
 Set the set of characters making up punctuation characters Should be called after SetWordChars. More...
 
wxString GetPunctuationChars () const
 Get the set of characters making up punctuation characters. More...
 
void SetCharsDefault ()
 Reset the set of characters for whitespace and word characters to the defaults. More...
 
Styling

int GetEndStyled () const
 Retrieve the position of the last correctly styled character. More...
 
void StartStyling (int start)
 Set the current styling position to start. More...
 
void SetStyling (int length, int style)
 Change style from current styling position for length characters to a style and move the current styling position to after this newly styled segment. More...
 
void SetStyleBytes (int length, char *styleBytes)
 Set the styles for a segment of the document. More...
 
void SetLineState (int line, int state)
 Used to hold extra styling information for each line. More...
 
int GetLineState (int line) const
 Retrieve the extra styling information for a line. More...
 
int GetMaxLineState () const
 Retrieve the last line number that has line state. More...
 
void SetIdleStyling (int idleStyling)
 Sets limits to idle styling. More...
 
int GetIdleStyling () const
 Retrieve the limits to idle styling. More...
 
Style definition

void StyleClearAll ()
 Clear all the styles and make equivalent to the global default style. More...
 
void StyleSetForeground (int style, const wxColour &fore)
 Set the foreground colour of a style. More...
 
void StyleSetBackground (int style, const wxColour &back)
 Set the background colour of a style. More...
 
void StyleSetBold (int style, bool bold)
 Set a style to be bold or not. More...
 
void StyleSetItalic (int style, bool italic)
 Set a style to be italic or not. More...
 
void StyleSetSize (int style, int sizePoints)
 Set the size of characters of a style. More...
 
void StyleSetFaceName (int style, const wxString &fontName)
 Set the font of a style. More...
 
void StyleSetEOLFilled (int style, bool eolFilled)
 Set a style to have its end of line filled or not. More...
 
void StyleResetDefault ()
 Reset the default style to its state at startup. More...
 
void StyleSetUnderline (int style, bool underline)
 Set a style to be underlined or not. More...
 
wxColour StyleGetForeground (int style) const
 Get the foreground colour of a style. More...
 
wxColour StyleGetBackground (int style) const
 Get the background colour of a style. More...
 
bool StyleGetBold (int style) const
 Get is a style bold or not. More...
 
bool StyleGetItalic (int style) const
 Get is a style italic or not. More...
 
int StyleGetSize (int style) const
 Get the size of characters of a style. More...
 
wxString StyleGetFaceName (int style)
 Get the font facename of a style. More...
 
bool StyleGetEOLFilled (int style) const
 Get is a style to have its end of line filled or not. More...
 
bool StyleGetUnderline (int style) const
 Get is a style underlined or not. More...
 
int StyleGetCase (int style) const
 Get is a style mixed case, or to force upper or lower case. More...
 
int StyleGetCharacterSet (int style) const
 Get the character get of the font in a style. More...
 
bool StyleGetVisible (int style) const
 Get is a style visible or not. More...
 
bool StyleGetChangeable (int style) const
 Get is a style changeable or not (read only). More...
 
bool StyleGetHotSpot (int style) const
 Get is a style a hotspot or not. More...
 
void StyleSetCase (int style, int caseVisible)
 Set a style to be mixed case, or to force upper or lower case. More...
 
void StyleSetSizeFractional (int style, int sizeHundredthPoints)
 Set the size of characters of a style. More...
 
int StyleGetSizeFractional (int style) const
 Get the size of characters of a style in points multiplied by 100. More...
 
void StyleSetWeight (int style, int weight)
 Set the weight of characters of a style. More...
 
int StyleGetWeight (int style) const
 Get the weight of characters of a style. More...
 
void StyleSetCharacterSet (int style, int characterSet)
 Set the character set of the font in a style. More...
 
void StyleSetHotSpot (int style, bool hotspot)
 Set a style to be a hotspot or not. More...
 
void StyleSetVisible (int style, bool visible)
 Set a style to be visible or not. More...
 
void StyleSetChangeable (int style, bool changeable)
 Set a style to be changeable or not (read only). More...
 
Caret selection and hotspot styles

void SetSelForeground (bool useSetting, const wxColour &fore)
 Set the foreground colour of the main and additional selections and whether to use this setting. More...
 
void SetSelBackground (bool useSetting, const wxColour &back)
 Set the background colour of the main and additional selections and whether to use this setting. More...
 
int GetSelAlpha () const
 Get the alpha of the selection. More...
 
void SetSelAlpha (int alpha)
 Set the alpha of the selection. More...
 
bool GetSelEOLFilled () const
 Is the selection end of line filled? More...
 
void SetSelEOLFilled (bool filled)
 Set the selection to have its end of line filled or not. More...
 
void SetCaretForeground (const wxColour &fore)
 Set the foreground colour of the caret. More...
 
int GetCaretPeriod () const
 Get the time in milliseconds that the caret is on and off. More...
 
void SetCaretPeriod (int periodMilliseconds)
 Get the time in milliseconds that the caret is on and off. More...
 
bool GetCaretLineVisible () const
 Is the background of the line containing the caret in a different colour? More...
 
void SetCaretLineVisible (bool show)
 Display the background of the line containing the caret in a different colour. More...
 
wxColour GetCaretLineBackground () const
 Get the colour of the background of the line containing the caret. More...
 
void SetCaretLineBackground (const wxColour &back)
 Set the colour of the background of the line containing the caret. More...
 
wxColour GetCaretForeground () const
 Get the foreground colour of the caret. More...
 
void SetCaretWidth (int pixelWidth)
 Set the width of the insert mode caret. More...
 
int GetCaretWidth () const
 Returns the width of the insert mode caret. More...
 
void SetHotspotActiveForeground (bool useSetting, const wxColour &fore)
 Set a fore colour for active hotspots. More...
 
wxColour GetHotspotActiveForeground () const
 Get the fore colour for active hotspots. More...
 
void SetHotspotActiveBackground (bool useSetting, const wxColour &back)
 Set a back colour for active hotspots. More...
 
wxColour GetHotspotActiveBackground () const
 Get the back colour for active hotspots. More...
 
void SetHotspotActiveUnderline (bool underline)
 Enable / Disable underlining active hotspots. More...
 
bool GetHotspotActiveUnderline () const
 Get whether underlining for active hotspots. More...
 
void SetHotspotSingleLine (bool singleLine)
 Limit hotspots to single line so hotspots on two lines don't merge. More...
 
bool GetHotspotSingleLine () const
 Get the HotspotSingleLine property. More...
 
int GetCaretSticky () const
 Can the caret preferred x position only be changed by explicit movement commands? More...
 
void SetCaretSticky (int useCaretStickyBehaviour)
 Stop the caret preferred x position changing when the user types. More...
 
void ToggleCaretSticky ()
 Switch between sticky and non-sticky: meant to be bound to a key. More...
 
void SetCaretLineBackAlpha (int alpha)
 Set background alpha of the caret line. More...
 
int GetCaretLineBackAlpha () const
 Get the background alpha of the caret line. More...
 
void SetCaretStyle (int caretStyle)
 Set the style of the caret to be drawn. More...
 
int GetCaretStyle () const
 Returns the current style of the caret. More...
 
bool GetCaretLineVisibleAlways () const
 Is the caret line always visible? More...
 
void SetCaretLineVisibleAlways (bool alwaysVisible)
 Sets the caret line to always visible. More...
 
Character representations

void SetControlCharSymbol (int symbol)
 Change the way control characters are displayed: If symbol is < 32, keep the drawn way, else, use the given character. More...
 
int GetControlCharSymbol () const
 Get the way control characters are displayed. More...
 
void SetRepresentation (const wxString &encodedCharacter, const wxString &representation)
 Set the way a character is drawn. More...
 
wxString GetRepresentation (const wxString &encodedCharacter) const
 Set the way a character is drawn. More...
 
void ClearRepresentation (const wxString &encodedCharacter)
 Remove a character representation. More...
 
Margins

void SetMarginType (int margin, int marginType)
 Set a margin to be either numeric or symbolic. More...
 
int GetMarginType (int margin) const
 Retrieve the type of a margin. More...
 
void SetMarginWidth (int margin, int pixelWidth)
 Set the width of a margin to a width expressed in pixels. More...
 
int GetMarginWidth (int margin) const
 Retrieve the width of a margin in pixels. More...
 
void SetMarginMask (int margin, int mask)
 Set a mask that determines which markers are displayed in a margin. More...
 
int GetMarginMask (int margin) const
 Retrieve the marker mask of a margin. More...
 
void SetMarginSensitive (int margin, bool sensitive)
 Make a margin sensitive or insensitive to mouse clicks. More...
 
bool GetMarginSensitive (int margin) const
 Retrieve the mouse click sensitivity of a margin. More...
 
void SetMarginCursor (int margin, int cursor)
 Set the cursor shown when the mouse is inside a margin. More...
 
int GetMarginCursor (int margin) const
 Retrieve the cursor shown in a margin. More...
 
void SetMarginBackground (int margin, const wxColour &back)
 Set the background colour of a margin. More...
 
wxColour GetMarginBackground (int margin) const
 Retrieve the background colour of a margin. More...
 
void SetMarginCount (int margins)
 Allocate a non-standard number of margins. More...
 
int GetMarginCount () const
 How many margins are there?. More...
 
void SetMarginLeft (int pixelWidth)
 Sets the size in pixels of the left margin. More...
 
int GetMarginLeft () const
 Returns the size in pixels of the left margin. More...
 
void SetMarginRight (int pixelWidth)
 Sets the size in pixels of the right margin. More...
 
int GetMarginRight () const
 Returns the size in pixels of the right margin. More...
 
void SetFoldMarginColour (bool useSetting, const wxColour &back)
 Set one of the colours used as a chequerboard pattern in the fold margin. More...
 
void SetFoldMarginHiColour (bool useSetting, const wxColour &fore)
 Set the other colour used as a chequerboard pattern in the fold margin. More...
 
void MarginSetText (int line, const wxString &text)
 Set the text in the text margin for a line. More...
 
wxString MarginGetText (int line) const
 Get the text in the text margin for a line. More...
 
void MarginSetStyle (int line, int style)
 Set the style number for the text margin for a line. More...
 
int MarginGetStyle (int line) const
 Get the style number for the text margin for a line. More...
 
void MarginSetStyles (int line, const wxString &styles)
 Set the style in the text margin for a line. More...
 
wxString MarginGetStyles (int line) const
 Get the styles in the text margin for a line. More...
 
void MarginTextClearAll ()
 Clear the margin text on all lines. More...
 
void MarginSetStyleOffset (int style)
 Get the start of the range of style numbers used for margin text. More...
 
int MarginGetStyleOffset () const
 Get the start of the range of style numbers used for margin text. More...
 
void SetMarginOptions (int marginOptions)
 Set the margin options. More...
 
int GetMarginOptions () const
 Get the margin options. More...
 
Annotations

void AnnotationSetText (int line, const wxString &text)
 Set the annotation text for a line. More...
 
wxString AnnotationGetText (int line) const
 Get the annotation text for a line. More...
 
void AnnotationSetStyle (int line, int style)
 Set the style number for the annotations for a line. More...
 
int AnnotationGetStyle (int line) const
 Get the style number for the annotations for a line. More...
 
void AnnotationSetStyles (int line, const wxString &styles)
 Set the annotation styles for a line. More...
 
wxString AnnotationGetStyles (int line) const
 Get the annotation styles for a line. More...
 
int AnnotationGetLines (int line) const
 Get the number of annotation lines for a line. More...
 
void AnnotationClearAll ()
 Clear the annotations from all lines. More...
 
void AnnotationSetVisible (int visible)
 Set the visibility for the annotations for a view. More...
 
int AnnotationGetVisible () const
 Get the visibility for the annotations for a view. More...
 
void AnnotationSetStyleOffset (int style)
 Get the start of the range of style numbers used for annotations. More...
 
int AnnotationGetStyleOffset () const
 Get the start of the range of style numbers used for annotations. More...
 
Other settings

int MarkerHandleFromLine (int line, int which)
 Retrieve marker handles of a line. More...
 
int MarkerNumberFromLine (int line, int which)
 Retrieve marker number of a marker handle. More...
 
bool GetBufferedDraw () const
 Is drawing done first into a buffer or direct to the screen? More...
 
void SetBufferedDraw (bool buffered)
 If drawing is buffered then each line of text is drawn into a bitmap buffer before drawing it to the screen to avoid flicker. More...
 
void SetTabMinimumWidth (int pixels)
 Set the minimum visual width of a tab. More...
 
int GetTabMinimumWidth () const
 Get the minimum visual width of a tab. More...
 
void SetCodePage (int codePage)
 Set the code page used to interpret the bytes of the document as characters. More...
 
int GetIMEInteraction () const
 Is the IME displayed in a window or inline? More...
 
void SetIMEInteraction (int imeInteraction)
 Choose to display the IME in a window or inline. More...
 
void SetCharacterCategoryOptimization (int countCharacters)
 Set the number of characters to have directly indexed categories. More...
 
int GetCharacterCategoryOptimization () const
 Get the number of characters to have directly indexed categories. More...
 
int GetCaretLineFrame () const
 Retrieve the caret line frame width. More...
 
void SetCaretLineFrame (int width)
 Display the caret line framed. More...
 
int CountCodeUnits (int start, int end)
 Count code units between two positions. More...
 
int GetCodePage () const
 Get the code page used to interpret the bytes of the document as characters. More...
 
void SetTargetStartVirtualSpace (int space)
 Sets the virtual space of the target start. More...
 
int GetTargetStartVirtualSpace () const
 Get the virtual space of the target start. More...
 
void SetTargetEndVirtualSpace (int space)
 Sets the virtual space of the target end. More...
 
int GetTargetEndVirtualSpace () const
 Get the virtual space of the target end. More...
 
int FoldDisplayTextGetStyle () const
 Get the style of fold display text. More...
 
void SetDefaultFoldDisplayText (const wxString &text)
 Set the default fold display text. More...
 
wxString GetDefaultFoldDisplayText () const
 Get the default fold display text. More...
 
void SetLayoutCache (int cacheMode)
 Sets the degree of caching of layout information. More...
 
int GetPhasesDraw () const
 How many phases is drawing done in? More...
 
void SetPhasesDraw (int phases)
 In one phase draw, text is drawn in a series of rectangular blocks with no overlap. More...
 
void SetFontQuality (int fontQuality)
 Choose the quality level for text. More...
 
int GetFontQuality () const
 Retrieve the quality level for text. More...
 
void SetAccessibility (int accessibility)
 Enable or disable accessibility. More...
 
int GetAccessibility () const
 Report accessibility status. More...
 
void LineReverse ()
 Reverse order of selected lines. More...
 
int BraceMatchNext (int pos, int startPos)
 Similar to BraceMatch, but matching starts at the explicit start position. More...
 
int GetMultiEdgeColumn (int which) const
 Get multi edge positions. More...
 
int GetDocumentOptions () const
 Get which document options are set. More...
 
void SetCommandEvents (bool commandEvents)
 Set whether command events are sent to the container. More...
 
bool GetCommandEvents () const
 Get whether command events are sent to the container. More...
 
void SetSTCFocus (bool focus)
 Change internal focus flag. More...
 
bool GetSTCFocus () const
 Get internal focus flag. More...
 
int PositionRelativeCodeUnits (int pos, int relative)
 Given a valid document position, return a position that differs in a number of UTF-16 code units. More...
 
bool GetMoveExtendsSelection () const
 Get whether or not regular caret moves will extend or reduce the selection. More...
 
int GetSelectionNStartVirtualSpace (int selection) const
 Returns the virtual space at the start of the selection. More...
 
int GetSelectionNEndVirtualSpace (int selection) const
 Returns the virtual space at the end of the selection. More...
 
void SetTechnology (int technology)
 Set the technology used. More...
 
int GetTechnology () const
 Get the tech. More...
 
void EOLAnnotationSetText (int line, const wxString &text)
 Set the end of line annotation text for a line. More...
 
wxString EOLAnnotationGetText (int line) const
 Get the end of line annotation text for a line. More...
 
void EOLAnnotationSetStyle (int line, int style)
 Set the style number for the end of line annotations for a line. More...
 
int EOLAnnotationGetStyle (int line) const
 Get the style number for the end of line annotations for a line. More...
 
void EOLAnnotationClearAll ()
 Clear the end of annotations from all lines. More...
 
void EOLAnnotationSetVisible (int visible)
 Set the visibility for the end of line annotations for a view. More...
 
int EOLAnnotationGetVisible () const
 Get the visibility for the end of line annotations for a view. More...
 
void EOLAnnotationSetStyleOffset (int style)
 Get the start of the range of style numbers used for end of line annotations. More...
 
int EOLAnnotationGetStyleOffset () const
 Get the start of the range of style numbers used for end of line annotations. More...
 
int GetNamedStyles () const
 Retrieve the number of named styles for the lexer. More...
 
wxString NameOfStyle (int style) const
 Retrieve the name of a style. More...
 
wxString TagsOfStyle (int style) const
 Retrieve a ' ' separated list of style tags like "literal quoted string". More...
 
wxString DescriptionOfStyle (int style) const
 Retrieve a description of a style. More...
 
void SetILexer (void *ilexer)
 Set the lexer from an ILexer*. More...
 
bool GetTwoPhaseDraw () const
 Is drawing done in two phases with backgrounds drawn before foregrounds? More...
 
void SetTwoPhaseDraw (bool twoPhase)
 In twoPhaseDraw mode, drawing is performed in two phases, first the background and then the foreground. More...
 
Brace highlighting

void BraceHighlight (int posA, int posB)
 Highlight the characters at two positions. More...
 
void BraceHighlightIndicator (bool useSetting, int indicator)
 Use specified indicator to highlight matching braces instead of changing their style. More...
 
void BraceBadLight (int pos)
 Highlight the character at a position indicating there is no matching brace. More...
 
void BraceBadLightIndicator (bool useSetting, int indicator)
 Use specified indicator to highlight non matching brace instead of changing its style. More...
 
int BraceMatch (int pos, int maxReStyle=0)
 Find the position of a matching brace or wxSTC_INVALID_POSITION if no match. More...
 
Tabs and Indentation Guides

void SetTabWidth (int tabWidth)
 Change the visible size of a tab to be a multiple of the width of a space character. More...
 
int GetTabWidth () const
 Retrieve the visible size of a tab. More...
 
void ClearTabStops (int line)
 Clear explicit tabstops on a line. More...
 
void AddTabStop (int line, int x)
 Add an explicit tab stop for a line. More...
 
int GetNextTabStop (int line, int x)
 Find the next explicit tab stop position on a line after a position. More...
 
void SetIndent (int indentSize)
 Set the number of spaces used for one level of indentation. More...
 
int GetIndent () const
 Retrieve indentation size. More...
 
void SetUseTabs (bool useTabs)
 Indentation will only use space characters if useTabs is false, otherwise it will use a combination of tabs and spaces. More...
 
bool GetUseTabs () const
 Retrieve whether tabs will be used in indentation. More...
 
void SetLineIndentation (int line, int indentation)
 Change the indentation of a line to a number of columns. More...
 
int GetLineIndentation (int line) const
 Retrieve the number of columns that a line is indented. More...
 
int GetLineIndentPosition (int line) const
 Retrieve the position before the first non indentation character on a line. More...
 
void SetIndentationGuides (int indentView)
 Show or hide indentation guides. More...
 
int GetIndentationGuides () const
 Are the indentation guides visible? More...
 
void SetHighlightGuide (int column)
 Set the highlighted indentation guide column. More...
 
int GetHighlightGuide () const
 Get the highlighted indentation guide column. More...
 
void SetTabIndents (bool tabIndents)
 Sets whether a tab pressed when caret is within indentation indents. More...
 
bool GetTabIndents () const
 Does a tab pressed when caret is within indentation indent? More...
 
void SetBackSpaceUnIndents (bool bsUnIndents)
 Sets whether a backspace pressed when caret is within indentation unindents. More...
 
bool GetBackSpaceUnIndents () const
 Does a backspace pressed when caret is within indentation unindent? More...
 
Markers
int MarkerLineFromHandle (int markerHandle)
 Retrieve the line number at which a particular marker is located. More...
 
void MarkerDeleteHandle (int markerHandle)
 Delete a marker. More...
 
void MarkerDefine (int markerNumber, int markerSymbol, const wxColour &foreground=wxNullColour, const wxColour &background=wxNullColour)
 Set the symbol used for a particular marker number, and optionally the fore and background colours. More...
 
void MarkerSetForeground (int markerNumber, const wxColour &fore)
 Set the foreground colour used for a particular marker number. More...
 
void MarkerSetBackground (int markerNumber, const wxColour &back)
 Set the background colour used for a particular marker number. More...
 
void MarkerSetBackgroundSelected (int markerNumber, const wxColour &back)
 Set the background colour used for a particular marker number when its folding block is selected. More...
 
void MarkerEnableHighlight (bool enabled)
 Enable/disable highlight for current folding block (smallest one that contains the caret) More...
 
int MarkerAdd (int line, int markerNumber)
 Add a marker to a line, returning an ID which can be used to find or delete the marker. More...
 
void MarkerDelete (int line, int markerNumber)
 Delete a marker from a line. More...
 
void MarkerDeleteAll (int markerNumber)
 Delete all markers with a particular number from all lines. More...
 
int MarkerGet (int line)
 Get a bit mask of all the markers set on a line. More...
 
int MarkerNext (int lineStart, int markerMask)
 Find the next line at or after lineStart that includes a marker in mask. More...
 
int MarkerPrevious (int lineStart, int markerMask)
 Find the previous line before lineStart that includes a marker in mask. More...
 
void MarkerDefinePixmap (int markerNumber, const char *const *xpmData)
 Define a marker from a bitmap. More...
 
void MarkerAddSet (int line, int markerSet)
 Add a set of markers to a line. More...
 
void MarkerSetAlpha (int markerNumber, int alpha)
 Set the alpha used for a marker that is drawn in the text area, not the margin. More...
 
int GetMarkerSymbolDefined (int markerNumber)
 Which symbol was defined for markerNumber with MarkerDefine. More...
 
void RGBAImageSetWidth (int width)
 Set the width for future RGBA image data. More...
 
void RGBAImageSetHeight (int height)
 Set the height for future RGBA image data. More...
 
void RGBAImageSetScale (int scalePercent)
 Set the scale factor in percent for future RGBA image data. More...
 
void MarkerDefineRGBAImage (int markerNumber, const unsigned char *pixels)
 Define a marker from RGBA data. More...
 
Indicators

void IndicatorSetStyle (int indicator, int indicatorStyle)
 Set an indicator to plain, squiggle or TT. More...
 
int IndicatorGetStyle (int indicator) const
 Retrieve the style of an indicator. More...
 
void IndicatorSetForeground (int indicator, const wxColour &fore)
 Set the foreground colour of an indicator. More...
 
wxColour IndicatorGetForeground (int indicator) const
 Retrieve the foreground colour of an indicator. More...
 
void IndicatorSetUnder (int indicator, bool under)
 Set an indicator to draw under text or over(default). More...
 
bool IndicatorGetUnder (int indicator) const
 Retrieve whether indicator drawn under or over text. More...
 
void IndicatorSetHoverStyle (int indicator, int indicatorStyle)
 Set a hover indicator to plain, squiggle or TT. More...
 
int IndicatorGetHoverStyle (int indicator) const
 Retrieve the hover style of an indicator. More...
 
void IndicatorSetHoverForeground (int indicator, const wxColour &fore)
 Set the foreground hover colour of an indicator. More...
 
wxColour IndicatorGetHoverForeground (int indicator) const
 Retrieve the foreground hover colour of an indicator. More...
 
void IndicatorSetFlags (int indicator, int flags)
 Set the attributes of an indicator. More...
 
int IndicatorGetFlags (int indicator) const
 Retrieve the attributes of an indicator. More...
 
void SetIndicatorCurrent (int indicator)
 Set the indicator used for IndicatorFillRange and IndicatorClearRange. More...
 
int GetIndicatorCurrent () const
 Get the current indicator. More...
 
void SetIndicatorValue (int value)
 Set the value used for IndicatorFillRange. More...
 
int GetIndicatorValue () const
 Get the current indicator value. More...
 
void IndicatorFillRange (int start, int lengthFill)
 Turn a indicator on over a range. More...
 
void IndicatorClearRange (int start, int lengthClear)
 Turn a indicator off over a range. More...
 
int IndicatorAllOnFor (int pos)
 Are any indicators present at pos? More...
 
int IndicatorValueAt (int indicator, int pos)
 What value does a particular indicator have at a position? More...
 
int IndicatorStart (int indicator, int pos)
 Where does a particular indicator start? More...
 
int IndicatorEnd (int indicator, int pos)
 Where does a particular indicator end? More...
 
void IndicatorSetAlpha (int indicator, int alpha)
 Set the alpha fill colour of the given indicator. More...
 
int IndicatorGetAlpha (int indicator) const
 Get the alpha fill colour of the given indicator. More...
 
void IndicatorSetOutlineAlpha (int indicator, int alpha)
 Set the alpha outline colour of the given indicator. More...
 
int IndicatorGetOutlineAlpha (int indicator) const
 Get the alpha outline colour of the given indicator. More...
 
Autocompletion
void AutoCompShow (int lengthEntered, const wxString &itemList)
 Display a auto-completion list. More...
 
void AutoCompCancel ()
 Remove the auto-completion list from the screen. More...
 
bool AutoCompActive ()
 Is there an auto-completion list visible? More...
 
int AutoCompPosStart ()
 Retrieve the position of the caret when the auto-completion list was displayed. More...
 
void AutoCompComplete ()
 User has selected an item so remove the list and insert the selection. More...
 
void AutoCompStops (const wxString &characterSet)
 Define a set of character that when typed cancel the auto-completion list. More...
 
void AutoCompSetSeparator (int separatorCharacter)
 Change the separator character in the string setting up an auto-completion list. More...
 
int AutoCompGetSeparator () const
 Retrieve the auto-completion list separator character. More...
 
void AutoCompSelect (const wxString &select)
 Select the item in the auto-completion list that starts with a string. More...
 
void AutoCompSetCancelAtStart (bool cancel)
 Should the auto-completion list be cancelled if the user backspaces to a position before where the box was created. More...
 
bool AutoCompGetCancelAtStart () const
 Retrieve whether auto-completion cancelled by backspacing before start. More...
 
void AutoCompSetFillUps (const wxString &characterSet)
 Define a set of characters that when typed will cause the autocompletion to choose the selected item. More...
 
void AutoCompSetChooseSingle (bool chooseSingle)
 Should a single item auto-completion list automatically choose the item. More...
 
bool AutoCompGetChooseSingle () const
 Retrieve whether a single item auto-completion list automatically choose the item. More...
 
void AutoCompSetIgnoreCase (bool ignoreCase)
 Set whether case is significant when performing auto-completion searches. More...
 
bool AutoCompGetIgnoreCase () const
 Retrieve state of ignore case flag. More...
 
void AutoCompSetAutoHide (bool autoHide)
 Set whether or not autocompletion is hidden automatically when nothing matches. More...
 
bool AutoCompGetAutoHide () const
 Retrieve whether or not autocompletion is hidden automatically when nothing matches. More...
 
void AutoCompSetDropRestOfWord (bool dropRestOfWord)
 Set whether or not autocompletion deletes any word characters after the inserted text upon completion. More...
 
bool AutoCompGetDropRestOfWord () const
 Retrieve whether or not autocompletion deletes any word characters after the inserted text upon completion. More...
 
void RegisterImage (int type, const char *const *xpmData)
 Register an image for use in autocompletion lists. More...
 
void ClearRegisteredImages ()
 Clear all the registered images. More...
 
int AutoCompGetTypeSeparator () const
 Retrieve the auto-completion list type-separator character. More...
 
void AutoCompSetTypeSeparator (int separatorCharacter)
 Change the type-separator character in the string setting up an auto-completion list. More...
 
void AutoCompSetMaxWidth (int characterCount)
 Set the maximum width, in characters, of auto-completion and user lists. More...
 
int AutoCompGetMaxWidth () const
 Get the maximum width, in characters, of auto-completion and user lists. More...
 
void AutoCompSetMaxHeight (int rowCount)
 Set the maximum height, in rows, of auto-completion and user lists. More...
 
int AutoCompGetMaxHeight () const
 Set the maximum height, in rows, of auto-completion and user lists. More...
 
int AutoCompGetCurrent () const
 Get currently selected item position in the auto-completion list. More...
 
wxString AutoCompGetCurrentText () const
 Get currently selected item text in the auto-completion list. More...
 
void AutoCompSetCaseInsensitiveBehaviour (int behaviour)
 Set auto-completion case insensitive behaviour to either prefer case-sensitive matches or have no preference. More...
 
int AutoCompGetCaseInsensitiveBehaviour () const
 Get auto-completion case insensitive behaviour. More...
 
void AutoCompSetMulti (int multi)
 Change the effect of autocompleting when there are multiple selections. More...
 
int AutoCompGetMulti () const
 Retrieve the effect of autocompleting when there are multiple selections. More...
 
void AutoCompSetOrder (int order)
 Set the way autocompletion lists are ordered. More...
 
int AutoCompGetOrder () const
 Get the way autocompletion lists are ordered. More...
 
void RegisterRGBAImage (int type, const unsigned char *pixels)
 Register an RGBA image for use in autocompletion lists. More...
 
User lists

void UserListShow (int listType, const wxString &itemList)
 Display a list of strings and send notification when user chooses one. More...
 
Call tips

void CallTipShow (int pos, const wxString &definition)
 Show a call tip containing a definition near position pos. More...
 
void CallTipCancel ()
 Remove the call tip from the screen. More...
 
bool CallTipActive ()
 Is there an active call tip? More...
 
int CallTipPosAtStart ()
 Retrieve the position where the caret was before displaying the call tip. More...
 
void CallTipSetPosAtStart (int posStart)
 Set the start position in order to change when backspacing removes the calltip. More...
 
void CallTipSetHighlight (int highlightStart, int highlightEnd)
 Highlight a segment of the definition. More...
 
void CallTipSetBackground (const wxColour &back)
 Set the background colour for the call tip. More...
 
void CallTipSetForeground (const wxColour &fore)
 Set the foreground colour for the call tip. More...
 
void CallTipSetForegroundHighlight (const wxColour &fore)
 Set the foreground colour for the highlighted part of the call tip. More...
 
void CallTipUseStyle (int tabSize)
 Enable use of wxSTC_STYLE_CALLTIP and set call tip tab size in pixels. More...
 
void CallTipSetPosition (bool above)
 Set position of calltip, above or below text. More...
 
Keyboard commands

void LineDown ()
 Move caret down one line. More...
 
void LineDownExtend ()
 Move caret down one line extending selection to new caret position. More...
 
void LineUp ()
 Move caret up one line. More...
 
void LineUpExtend ()
 Move caret up one line extending selection to new caret position. More...
 
void CharLeft ()
 Move caret left one character. More...
 
void CharLeftExtend ()
 Move caret left one character extending selection to new caret position. More...
 
void CharRight ()
 Move caret right one character. More...
 
void CharRightExtend ()
 Move caret right one character extending selection to new caret position. More...
 
void WordLeft ()
 Move caret left one word. More...
 
void WordLeftExtend ()
 Move caret left one word extending selection to new caret position. More...
 
void WordRight ()
 Move caret right one word. More...
 
void WordRightExtend ()
 Move caret right one word extending selection to new caret position. More...
 
void Home ()
 Move caret to first position on line. More...
 
void HomeExtend ()
 Move caret to first position on line extending selection to new caret position. More...
 
void LineEnd ()
 Move caret to last position on line. More...
 
void LineEndExtend ()
 Move caret to last position on line extending selection to new caret position. More...
 
void DocumentStart ()
 Move caret to first position in document. More...
 
void DocumentStartExtend ()
 Move caret to first position in document extending selection to new caret position. More...
 
void DocumentEnd ()
 Move caret to last position in document. More...
 
void DocumentEndExtend ()
 Move caret to last position in document extending selection to new caret position. More...
 
void PageUp ()
 Move caret one page up. More...
 
void PageUpExtend ()
 Move caret one page up extending selection to new caret position. More...
 
void PageDown ()
 Move caret one page down. More...
 
void PageDownExtend ()
 Move caret one page down extending selection to new caret position. More...
 
void EditToggleOvertype ()
 Switch from insert to overtype mode or the reverse. More...
 
void Cancel ()
 Cancel any modes such as call tip or auto-completion list display. More...
 
void DeleteBack ()
 Delete the selection or if no selection, the character before the caret. More...
 
void Tab ()
 If selection is empty or all on one line replace the selection with a tab character. More...
 
void BackTab ()
 Dedent the selected lines. More...
 
void NewLine ()
 Insert a new line, may use a CRLF, CR or LF depending on EOL mode. More...
 
void FormFeed ()
 Insert a Form Feed character. More...
 
void VCHome ()
 Move caret to before first visible character on line. More...
 
void VCHomeExtend ()
 Like VCHome but extending selection to new caret position. More...
 
void DelWordLeft ()
 Delete the word to the left of the caret. More...
 
void DelWordRight ()
 Delete the word to the right of the caret. More...
 
void DelWordRightEnd ()
 Delete the word to the right of the caret, but not the trailing non-word characters. More...
 
void LineCut ()
 Cut the line containing the caret. More...
 
void LineDelete ()
 Delete the line containing the caret. More...
 
void LineTranspose ()
 Switch the current line with the previous. More...
 
void LineDuplicate ()
 Duplicate the current line. More...
 
void LowerCase ()
 Transform the selection to lower case. More...
 
void UpperCase ()
 Transform the selection to upper case. More...
 
void LineScrollDown ()
 Scroll the document down, keeping the caret visible. More...
 
void LineScrollUp ()
 Scroll the document up, keeping the caret visible. More...
 
void DeleteBackNotLine ()
 Delete the selection or if no selection, the character before the caret. More...
 
void HomeDisplay ()
 Move caret to first position on display line. More...
 
void HomeDisplayExtend ()
 Move caret to first position on display line extending selection to new caret position. More...
 
void LineEndDisplay ()
 Move caret to last position on display line. More...
 
void LineEndDisplayExtend ()
 Move caret to last position on display line extending selection to new caret position. More...
 
void HomeWrap ()
 Like Home but when word-wrap is enabled goes first to start of display line HomeDisplay, then to start of document line Home. More...
 
void HomeWrapExtend ()
 Like HomeExtend but when word-wrap is enabled extends first to start of display line HomeDisplayExtend, then to start of document line HomeExtend. More...
 
void LineEndWrap ()
 Like LineEnd but when word-wrap is enabled goes first to end of display line LineEndDisplay, then to start of document line LineEnd. More...
 
void LineEndWrapExtend ()
 Like LineEndExtend but when word-wrap is enabled extends first to end of display line LineEndDisplayExtend, then to start of document line LineEndExtend. More...
 
void VCHomeWrap ()
 Like VCHome but when word-wrap is enabled goes first to start of display line VCHomeDisplay, then behaves like VCHome. More...
 
void VCHomeWrapExtend ()
 Like VCHomeExtend but when word-wrap is enabled extends first to start of display line VCHomeDisplayExtend, then behaves like VCHomeExtend. More...
 
void LineCopy ()
 Copy the line containing the caret. More...
 
void WordPartLeft ()
 Move to the previous change in capitalisation. More...
 
void WordPartLeftExtend ()
 Move to the previous change in capitalisation extending selection to new caret position. More...
 
void WordPartRight ()
 Move to the change next in capitalisation. More...
 
void WordPartRightExtend ()
 Move to the next change in capitalisation extending selection to new caret position. More...
 
void DelLineLeft ()
 Delete back from the current position to the start of the line. More...
 
void DelLineRight ()
 Delete forwards from the current position to the end of the line. More...
 
void ParaDown ()
 Move caret down one paragraph (delimited by empty lines). More...
 
void ParaDownExtend ()
 Extend selection down one paragraph (delimited by empty lines). More...
 
void ParaUp ()
 Move caret up one paragraph (delimited by empty lines). More...
 
void ParaUpExtend ()
 Extend selection up one paragraph (delimited by empty lines). More...
 
void LineDownRectExtend ()
 Move caret down one line, extending rectangular selection to new caret position. More...
 
void LineUpRectExtend ()
 Move caret up one line, extending rectangular selection to new caret position. More...
 
void CharLeftRectExtend ()
 Move caret left one character, extending rectangular selection to new caret position. More...
 
void CharRightRectExtend ()
 Move caret right one character, extending rectangular selection to new caret position. More...
 
void HomeRectExtend ()
 Move caret to first position on line, extending rectangular selection to new caret position. More...
 
void VCHomeRectExtend ()
 Move caret to before first visible character on line. More...
 
void LineEndRectExtend ()
 Move caret to last position on line, extending rectangular selection to new caret position. More...
 
void PageUpRectExtend ()
 Move caret one page up, extending rectangular selection to new caret position. More...
 
void PageDownRectExtend ()
 Move caret one page down, extending rectangular selection to new caret position. More...
 
void StutteredPageUp ()
 Move caret to top of page, or one page up if already at top of page. More...
 
void StutteredPageUpExtend ()
 Move caret to top of page, or one page up if already at top of page, extending selection to new caret position. More...
 
void StutteredPageDown ()
 Move caret to bottom of page, or one page down if already at bottom of page. More...
 
void StutteredPageDownExtend ()
 Move caret to bottom of page, or one page down if already at bottom of page, extending selection to new caret position. More...
 
void WordLeftEnd ()
 Move caret left one word, position cursor at end of word. More...
 
void WordLeftEndExtend ()
 Move caret left one word, position cursor at end of word, extending selection to new caret position. More...
 
void WordRightEnd ()
 Move caret right one word, position cursor at end of word. More...
 
void WordRightEndExtend ()
 Move caret right one word, position cursor at end of word, extending selection to new caret position. More...
 
void SelectionDuplicate ()
 Duplicate the selection. More...
 
void VerticalCentreCaret ()
 Centre current line in window. More...
 
void ScrollToStart ()
 Scroll to start of document. More...
 
void ScrollToEnd ()
 Scroll to end of document. More...
 
void VCHomeDisplay ()
 Move caret to before first visible character on display line. More...
 
void VCHomeDisplayExtend ()
 Like VCHomeDisplay but extending selection to new caret position. More...
 
Key bindings

void CmdKeyAssign (int key, int modifiers, int cmd)
 When key+modifier combination keyDefinition is pressed perform sciCommand. More...
 
void CmdKeyClear (int key, int modifiers)
 When key+modifier combination keyDefinition is pressed do nothing. More...
 
void CmdKeyClearAll ()
 Drop all key mappings. More...
 
Popup edit menu

void UsePopUp (int popUpMode)
 Set whether a pop up menu is displayed automatically when the user presses the wrong mouse button on certain areas. More...
 
Macro recording

void StartRecord ()
 Start notifying the container of all key presses and commands. More...
 
void StopRecord ()
 Stop notifying the container of all key presses and commands. More...
 
Printing

void SetPrintMagnification (int magnification)
 Sets the print magnification added to the point size of each style for printing. More...
 
int GetPrintMagnification () const
 Returns the print magnification. More...
 
void SetPrintColourMode (int mode)
 Modify colours when printing for clearer printed text. More...
 
int GetPrintColourMode () const
 Returns the print colour mode. More...
 
int FormatRange (bool doDraw, int startPos, int endPos, wxDC *draw, wxDC *target, wxRect renderRect, wxRect pageRect)
 On Windows, will draw the document into a display context such as a printer. More...
 
void SetPrintWrapMode (int wrapMode)
 Set printing to line wrapped (wxSTC_WRAP_WORD) or not line wrapped (wxSTC_WRAP_NONE). More...
 
int GetPrintWrapMode () const
 Is printing line wrapped? More...
 
Direct access

void * GetDirectFunction () const
 Retrieve a pointer to a function that processes messages for this Scintilla. More...
 
void * GetDirectPointer () const
 Retrieve a pointer value to use as the first argument when calling the function returned by GetDirectFunction. More...
 
const char * GetCharacterPointer () const
 Compact the document buffer and return a read-only pointer to the characters in the document. More...
 
const char * GetRangePointer (int position, int rangeLength) const
 Return a read-only pointer to a range of characters in the document. More...
 
int GetGapPosition () const
 Return a position which, to avoid performance costs, should not be within the range of a call to GetRangePointer. More...
 
Multiple views

void * GetDocPointer ()
 Retrieve a pointer to the document object. More...
 
void SetDocPointer (void *docPointer)
 Change the document object used. More...
 
void * CreateDocument ()
 Create a new document object. More...
 
void AddRefDocument (void *docPointer)
 Extend life of document. More...
 
void ReleaseDocument (void *docPointer)
 Release a reference to the document, deleting document if it fades to black. More...
 
Background loading and saving

void * CreateLoader (int bytes) const
 Create an ILoader*. More...
 
Folding

int VisibleFromDocLine (int docLine)
 Find the display line of a document line taking hidden lines into account. More...
 
int DocLineFromVisible (int displayLine)
 Find the document line of a display line taking hidden lines into account. More...
 
void SetFoldLevel (int line, int level)
 Set the fold level of a line. More...
 
int GetFoldLevel (int line) const
 Retrieve the fold level of a line. More...
 
int GetLastChild (int line, int level) const
 Find the last child line of a header line. More...
 
int GetFoldParent (int line) const
 Find the parent line of a child line. More...
 
void ShowLines (int lineStart, int lineEnd)
 Make a range of lines visible. More...
 
void HideLines (int lineStart, int lineEnd)
 Make a range of lines invisible. More...
 
bool GetLineVisible (int line) const
 Is a line visible? More...
 
bool GetAllLinesVisible () const
 Are all lines visible? More...
 
void SetFoldExpanded (int line, bool expanded)
 Show the children of a header line. More...
 
bool GetFoldExpanded (int line) const
 Is a header line expanded? More...
 
void ToggleFold (int line)
 Switch a header line between expanded and contracted. More...
 
void ToggleFoldShowText (int line, const wxString &text)
 Switch a header line between expanded and contracted and show some text after the line. More...
 
void FoldDisplayTextSetStyle (int style)
 Set the style of fold display text. More...
 
void FoldLine (int line, int action)
 Expand or contract a fold header. More...
 
void FoldChildren (int line, int action)
 Expand or contract a fold header and its children. More...
 
void ExpandChildren (int line, int level)
 Expand a fold header and all children. More...
 
void FoldAll (int action)
 Expand or contract all fold headers. More...
 
void EnsureVisible (int line)
 Ensure a particular line is visible by expanding any header line hiding it. More...
 
void SetAutomaticFold (int automaticFold)
 Set automatic folding behaviours. More...
 
int GetAutomaticFold () const
 Get automatic folding behaviours. More...
 
void SetFoldFlags (int flags)
 Set some style options for folding. More...
 
void EnsureVisibleEnforcePolicy (int line)
 Ensure a particular line is visible by expanding any header line hiding it. More...
 
int ContractedFoldNext (int lineStart)
 Find the next line at or after lineStart that is a contracted fold header line. More...
 
Line wrapping

int WrapCount (int docLine)
 The number of display lines needed to wrap a document line. More...
 
void SetWrapMode (int wrapMode)
 Sets whether text is word wrapped. More...
 
int GetWrapMode () const
 Retrieve whether text is word wrapped. More...
 
void SetWrapVisualFlags (int wrapVisualFlags)
 Set the display mode of visual flags for wrapped lines. More...
 
int GetWrapVisualFlags () const
 Retrieve the display mode of visual flags for wrapped lines. More...
 
void SetWrapVisualFlagsLocation (int wrapVisualFlagsLocation)
 Set the location of visual flags for wrapped lines. More...
 
int GetWrapVisualFlagsLocation () const
 Retrieve the location of visual flags for wrapped lines. More...
 
void SetWrapStartIndent (int indent)
 Set the start indent for wrapped lines. More...
 
int GetWrapStartIndent () const
 Retrieve the start indent for wrapped lines. More...
 
void SetWrapIndentMode (int wrapIndentMode)
 Sets how wrapped sublines are placed. More...
 
int GetWrapIndentMode () const
 Retrieve how wrapped sublines are placed. More...
 
int GetLayoutCache () const
 Retrieve the degree of caching of layout information. More...
 
void LinesJoin ()
 Join the lines in the target. More...
 
void LinesSplit (int pixelWidth)
 Split the lines in the target into lines that are less wide than pixelWidth where possible. More...
 
void SetPositionCacheSize (int size)
 Set number of entries in position cache. More...
 
int GetPositionCacheSize () const
 How many entries are allocated to the position cache? More...
 
Zooming

void ZoomIn ()
 Magnify the displayed text by increasing the sizes by 1 point. More...
 
void ZoomOut ()
 Make the displayed text smaller by decreasing the sizes by 1 point. More...
 
void SetZoom (int zoomInPoints)
 Set the zoom level. More...
 
int GetZoom () const
 Retrieve the zoom level. More...
 
Long lines

int GetEdgeColumn () const
 Retrieve the column number which text should be kept within. More...
 
void SetEdgeColumn (int column)
 Set the column number of the edge. More...
 
int GetEdgeMode () const
 Retrieve the edge highlight mode. More...
 
void SetEdgeMode (int edgeMode)
 The edge may be displayed by a line (wxSTC_EDGE_LINE/wxSTC_EDGE_MULTILINE) or by highlighting text that goes beyond it (wxSTC_EDGE_BACKGROUND) or not displayed at all (wxSTC_EDGE_NONE). More...
 
wxColour GetEdgeColour () const
 Retrieve the colour used in edge indication. More...
 
void SetEdgeColour (const wxColour &edgeColour)
 Change the colour used in edge indication. More...
 
void MultiEdgeAddLine (int column, const wxColour &edgeColour)
 Add a new vertical edge to the view. More...
 
void MultiEdgeClearAll ()
 Clear all vertical edges. More...
 
Lexer

int ChangeLexerState (int start, int end)
 Indicate that the internal state of a lexer has changed over a range and therefore there may be a need to redraw. More...
 
void SetLexer (int lexer)
 Set the lexing language of the document. More...
 
int GetLexer () const
 Retrieve the lexing language of the document. More...
 
void Colourise (int start, int end)
 Colourise a segment of the document using the current lexing language. More...
 
void SetProperty (const wxString &key, const wxString &value)
 Set up a value that may be used by a lexer for some optional feature. More...
 
void SetKeyWords (int keyWordSet, const wxString &keyWords)
 Set up the key words used by the lexer. More...
 
void SetLexerLanguage (const wxString &language)
 Set the lexing language of the document based on string name. More...
 
void LoadLexerLibrary (const wxString &path)
 Load a lexer library (dll / so). More...
 
wxString GetProperty (const wxString &key)
 Retrieve a "property" value previously set with SetProperty. More...
 
wxString GetPropertyExpanded (const wxString &key)
 Retrieve a "property" value previously set with SetProperty, with "$()" variable replacement on returned buffer. More...
 
int GetPropertyInt (const wxString &key, int defaultValue=0) const
 Retrieve a "property" value previously set with SetProperty, interpreted as an int AFTER any "$()" variable replacement. More...
 
wxString GetLexerLanguage () const
 Retrieve the lexing language of the document. More...
 
void * PrivateLexerCall (int operation, void *pointer)
 For private communication between an application and a known lexer. More...
 
wxString PropertyNames () const
 Retrieve a '\n' separated list of properties understood by the current lexer. More...
 
int PropertyType (const wxString &name)
 Retrieve the type of a property. More...
 
wxString DescribeProperty (const wxString &name) const
 Describe a property. More...
 
wxString DescribeKeyWordSets () const
 Retrieve a '\n' separated list of descriptions of the keyword sets understood by the current lexer. More...
 
int AllocateSubStyles (int styleBase, int numberStyles)
 Allocate a set of sub styles for a particular base style, returning start of range. More...
 
int GetSubStylesStart (int styleBase) const
 The starting style number for the sub styles associated with a base style. More...
 
int GetSubStylesLength (int styleBase) const
 The number of sub styles associated with a base style. More...
 
int GetStyleFromSubStyle (int subStyle) const
 For a sub style, return the base style, else return the argument. More...
 
int GetPrimaryStyleFromStyle (int style) const
 For a secondary style, return the primary style, else return the argument. More...
 
void FreeSubStyles ()
 Free allocated sub styles. More...
 
void SetIdentifiers (int style, const wxString &identifiers)
 Set the identifiers that are shown in a particular style. More...
 
int DistanceToSecondaryStyles () const
 Where styles are duplicated by a feature such as active/inactive code return the distance between the two types. More...
 
wxString GetSubStyleBases () const
 Get the set of base styles that can be extended with sub styles. More...
 
Event related items

void SetMouseDwellTime (int periodMilliseconds)
 Sets the time the mouse must sit still to generate a mouse dwell event. More...
 
int GetMouseDwellTime () const
 Retrieve the time the mouse must sit still to generate a mouse dwell event. More...
 
void SetModEventMask (int eventMask)
 Set which document modification events are sent to the container. More...
 
int GetModEventMask () const
 Get which document modification events are sent to the container. More...
 
void SetIdentifier (int identifier)
 Set the identifier reported as idFrom in notification messages. More...
 
int GetIdentifier () const
 Get the identifier. More...
 
Deprecated items

These methods should not be used in new code.

void SetStyleBits (int bits)
 Divide each styling byte into lexical class bits (default: 5) and indicator bits (default: 3). More...
 
int GetStyleBits () const
 Retrieve number of bits in style bytes used to hold the lexical state. More...
 
int GetStyleBitsNeeded () const
 Retrieve the number of bits the current lexer needs for styling. More...
 
Additional wxStyledTextCtrl methods

In addition to the standard Scintilla functions, wxStyledTextCtrl includes the following functions to simplify some tasks.

int GetCurrentLine ()
 Returns the line number of the line with the caret. More...
 
void StyleSetSpec (int styleNum, const wxString &spec)
 Extract style settings from a spec-string which is composed of one or more of the following comma separated elements: More...
 
wxFont StyleGetFont (int style)
 Get the font of a style. More...
 
void StyleSetFont (int styleNum, wxFont &font)
 Set style size, face, bold, italic, and underline attributes from a wxFont's attributes. More...
 
void StyleSetFontAttr (int styleNum, int size, const wxString &faceName, bool bold, bool italic, bool underline, wxFontEncoding encoding=wxFONTENCODING_DEFAULT)
 Set all font style attributes at once. More...
 
void StyleSetFontEncoding (int style, wxFontEncoding encoding)
 Set the font encoding to be used by a style. More...
 
void CmdKeyExecute (int cmd)
 Perform one of the operations defined by the wxSTC_CMD_* constants. More...
 
void SetMargins (int left, int right)
 Set the left and right margin in the edit area, measured in pixels. More...
 
void ScrollToLine (int line)
 Scroll enough to make the given line visible. More...
 
void ScrollToColumn (int column)
 Scroll enough to make the given column visible. More...
 
wxIntPtr SendMsg (int msg, wxUIntPtr wp=0, wxIntPtr lp=0) const
 Scintilla API call. More...
 
void SetVScrollBar (wxScrollBar *bar)
 Set the vertical scrollbar to use instead of the one that's built-in. More...
 
void SetHScrollBar (wxScrollBar *bar)
 Set the horizontal scrollbar to use instead of the one that's built-in. More...
 
bool GetLastKeydownProcessed ()
 Can be used to prevent the EVT_CHAR handler from adding the char. More...
 
void SetLastKeydownProcessed (bool val)
 Returns the line number of the line with the caret. More...
 
bool SaveFile (const wxString &filename)
 Write the contents of the editor to filename. More...
 
bool LoadFile (const wxString &filename)
 Load the contents of filename into the editor. More...
 
wxDragResult DoDragEnter (wxCoord x, wxCoord y, wxDragResult defaultRes)
 Allow for simulating a DnD DragEnter. More...
 
wxDragResult DoDragOver (wxCoord x, wxCoord y, wxDragResult defaultRes)
 Allow for simulating a DnD DragOver. More...
 
void DoDragLeave ()
 Allow for simulating a DnD DragLeave. More...
 
bool DoDropText (long x, long y, const wxString &data)
 Allow for simulating a DnD DropText. More...
 
void SetUseAntiAliasing (bool useAA)
 Specify whether anti-aliased fonts should be used. More...
 
bool GetUseAntiAliasing ()
 Returns the current UseAntiAliasing setting. More...
 
void AnnotationClearLine (int line)
 Clear annotations from the given line. More...
 
void MarkerDefineBitmap (int markerNumber, const wxBitmap &bmp)
 Define a marker with a wxBitmap. More...
 
void RegisterImage (int type, const wxBitmap &bmp)
 Register an image for use in autocompletion lists. More...
 
Raw variants <br>

These methods allow data to be sent to or received from the control using character buffers instead of using a wxString.

void AddTextRaw (const char *text, int length=-1)
 Add text to the document at current position. More...
 
void InsertTextRaw (int pos, const char *text)
 Insert string at a position. More...
 
wxCharBuffer GetCurLineRaw (int *linePos=nullptr)
 Retrieve the text of the line containing the caret. More...
 
wxCharBuffer GetLineRaw (int line)
 Retrieve the contents of a line. More...
 
wxCharBuffer GetSelectedTextRaw ()
 Retrieve the selected text. More...
 
wxCharBuffer GetTargetTextRaw ()
 Retrieve the target text. More...
 
wxCharBuffer GetTextRangeRaw (int startPos, int endPos)
 Retrieve a range of text. More...
 
void SetTextRaw (const char *text)
 Replace the contents of the document with the argument text. More...
 
wxCharBuffer GetTextRaw ()
 Retrieve all the text in the document. More...
 
void AppendTextRaw (const char *text, int length=-1)
 Append a string to the end of the document without changing the selection. More...
 
void ReplaceSelectionRaw (const char *text)
 Replace the current selection with text. More...
 
int ReplaceTargetRaw (const char *text, int length=-1)
 Replace the current target with text. More...
 
int ReplaceTargetRERaw (const char *text, int length=-1)
 Replace the current target with text using regular expressions. More...
 
Text entry methods

virtual void WriteText (const wxString &text)
 Writes the text into the text control at the current insertion position. More...
 
virtual void Remove (long from, long to)
 Removes the text starting at the first given position up to (but not including) the character at the last position. More...
 
virtual void Replace (long from, long to, const wxString &value)
 Replaces the text starting at the first position up to (but not including) the character at the last position with the given text. More...
 
virtual void SetInsertionPoint (long pos)
 Sets the insertion point at the given position. More...
 
virtual long GetInsertionPoint () const
 Returns the insertion point, or cursor, position. More...
 
virtual long GetLastPosition () const
 Returns the zero based index of the last position in the text control, which is equal to the number of characters in the control. More...
 
virtual void SetSelection (long from, long to)
 Selects the text starting at the first position up to (but not including) the character at the last position. More...
 
virtual void SelectNone ()
 Deselects selected text in the control. More...
 
virtual void GetSelection (long *from, long *to) const
 Gets the current selection span. More...
 
virtual bool IsEditable () const
 Returns true if the controls contents may be edited by user (note that it always can be changed by the program). More...
 
virtual void SetEditable (bool editable)
 Makes the text item editable or read-only, overriding the wxTE_READONLY flag. More...
 
Text area methods

virtual int GetLineLength (long lineNo) const
 Gets the length of the specified line, not including any trailing newline character(s). More...
 
virtual wxString GetLineText (long lineNo) const
 Returns the contents of a given line in the text control, not including any trailing newline character(s). More...
 
virtual int GetNumberOfLines () const
 Returns the number of lines in the text control buffer. More...
 
virtual bool IsModified () const
 Returns true if the text has been modified by user. More...
 
virtual void MarkDirty ()
 Mark text as modified (dirty). More...
 
virtual void DiscardEdits ()
 Resets the internal modified flag as if the current changes had been saved. More...
 
virtual bool SetStyle (long start, long end, const wxTextAttr &style)
 This method is inherited from wxTextAreaBase but is not implemented in wxStyledTextCtrl. More...
 
virtual bool GetStyle (long position, wxTextAttr &style)
 This method is inherited from wxTextAreaBase but is not implemented in wxStyledTextCtrl. More...
 
virtual bool SetDefaultStyle (const wxTextAttr &style)
 This method is inherited from wxTextAreaBase but is not implemented in wxStyledTextCtrl. More...
 
virtual long XYToPosition (long x, long y) const
 Converts the given zero based column and line number to a position. More...
 
virtual bool PositionToXY (long pos, long *x, long *y) const
 Converts given position to a zero-based column, line number pair. More...
 
virtual void ShowPosition (long pos)
 Makes the line containing the given position visible. More...
 
virtual wxTextCtrlHitTestResult HitTest (const wxPoint &pt, long *pos) const
 Finds the position of the character at the specified point. More...
 
virtual wxTextCtrlHitTestResult HitTest (const wxPoint &pt, wxTextCoord *col, wxTextCoord *row) const
 Finds the row and column of the character at the specified point. More...
 
- Public Member Functions inherited from wxControl
 wxControl (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxValidator &validator=wxDefaultValidator, const wxString &name=wxControlNameStr)
 Constructs a control. More...
 
 wxControl ()
 Default constructor to allow 2-phase creation. More...
 
bool Create (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxValidator &validator=wxDefaultValidator, const wxString &name=wxControlNameStr)
 
virtual void Command (wxCommandEvent &event)
 Simulates the effect of the user issuing a command to the item. More...
 
wxString GetLabel () const
 Returns the control's label, as it was passed to SetLabel(). More...
 
wxString GetLabelText () const
 Returns the control's label without mnemonics. More...
 
wxSize GetSizeFromTextSize (int xlen, int ylen=-1) const
 Determine the size needed by the control to leave the given area for its text. More...
 
wxSize GetSizeFromTextSize (const wxSize &tsize) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
wxSize GetSizeFromText (const wxString &text) const
 Determine the minimum size needed by the control to display the given text. More...
 
void SetLabel (const wxString &label)
 Sets the control's label. More...
 
void SetLabelText (const wxString &text)
 Sets the control's label to exactly the given string. More...
 
bool SetLabelMarkup (const wxString &markup)
 Sets the controls label to a string using markup. More...
 
- Public Member Functions inherited from wxWindow
 wxWindow ()
 Default constructor. More...
 
 wxWindow (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxPanelNameStr)
 Constructs a window, which can be a child of a frame, dialog or any other non-control window. More...
 
virtual ~wxWindow ()
 Destructor. More...
 
bool Create (wxWindow *parent, wxWindowID id, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=0, const wxString &name=wxPanelNameStr)
 Construct the actual window object after creating the C++ object. More...
 
void MSWDisableComposited ()
 Disable the use native double buffering in wxMSW. More...
 
virtual bool AcceptsFocus () const
 This method may be overridden in the derived classes to return false to indicate that this control doesn't accept input at all (i.e. behaves like e.g. wxStaticText) and so doesn't need focus. More...
 
virtual bool AcceptsFocusFromKeyboard () const
 This method may be overridden in the derived classes to return false to indicate that while this control can, in principle, have focus if the user clicks it with the mouse, it shouldn't be included in the TAB traversal chain when using the keyboard. More...
 
virtual bool AcceptsFocusRecursively () const
 Overridden to indicate whether this window or one of its children accepts focus. More...
 
void DisableFocusFromKeyboard ()
 Disable giving focus to this window using the keyboard navigation keys. More...
 
bool IsFocusable () const
 Can this window itself have focus? More...
 
bool CanAcceptFocus () const
 Can this window have focus right now? More...
 
bool CanAcceptFocusFromKeyboard () const
 Can this window be assigned focus from keyboard right now? More...
 
virtual bool HasFocus () const
 Returns true if the window (or in case of composite controls, its main child window) has focus. More...
 
virtual void SetCanFocus (bool canFocus)
 This method is only implemented by ports which have support for native TAB traversal (such as GTK+ 2.0). More...
 
virtual void EnableVisibleFocus (bool enable)
 Enables or disables visible indication of keyboard focus. More...
 
virtual void SetFocus ()
 This sets the window to receive keyboard input. More...
 
virtual void SetFocusFromKbd ()
 This function is called by wxWidgets keyboard navigation code when the user gives the focus to this window from keyboard (e.g. using TAB key). More...
 
virtual void AddChild (wxWindow *child)
 Adds a child window. More...
 
template<typename T >
void CallForEachChild (const T &functor)
 Invoke the given functor for all children of the given window recursively. More...
 
bool DestroyChildren ()
 Destroys all children of a window. More...
 
wxWindowFindWindow (long id) const
 Find a child of this window, by id. More...
 
wxWindowFindWindow (const wxString &name) const
 Find a child of this window, by name. More...
 
wxWindowList & GetChildren ()
 Returns a reference to the list of the window's children. More...
 
const wxWindowList & GetChildren () const
 Returns a const reference to the list of the window's children. More...
 
virtual void RemoveChild (wxWindow *child)
 Removes a child window. More...
 
wxWindowGetGrandParent () const
 Returns the grandparent of a window, or nullptr if there isn't one. More...
 
wxWindowGetNextSibling () const
 Returns the next window after this one among the parent's children or nullptr if this window is the last child. More...
 
wxWindowGetParent () const
 Returns the parent of the window, or nullptr if there is no parent. More...
 
wxWindowGetPrevSibling () const
 Returns the previous window before this one among the parent's children or nullptr if this window is the first child. More...
 
bool IsDescendant (wxWindow *win) const
 Check if the specified window is a descendant of this one. More...
 
virtual bool Reparent (wxWindow *newParent)
 Reparents the window, i.e. the window will be removed from its current parent window (e.g. More...
 
virtual void AlwaysShowScrollbars (bool hflag=true, bool vflag=true)
 Call this function to force one or both scrollbars to be always shown, even if the window is big enough to show its entire contents without scrolling. More...
 
virtual int GetScrollPos (int orientation) const
 Returns the built-in scrollbar position. More...
 
virtual int GetScrollRange (int orientation) const
 Returns the built-in scrollbar range. More...
 
virtual int GetScrollThumb (int orientation) const
 Returns the built-in scrollbar thumb size. More...
 
bool CanScroll (int orient) const
 Returns true if this window can have a scroll bar in this orientation. More...
 
bool HasScrollbar (int orient) const
 Returns true if this window currently has a scroll bar for this orientation. More...
 
virtual bool IsScrollbarAlwaysShown (int orient) const
 Return whether a scrollbar is always shown. More...
 
virtual bool ScrollLines (int lines)
 Scrolls the window by the given number of lines down (if lines is positive) or up. More...
 
virtual bool ScrollPages (int pages)
 Scrolls the window by the given number of pages down (if pages is positive) or up. More...
 
virtual void ScrollWindow (int dx, int dy, const wxRect *rect=nullptr)
 Physically scrolls the pixels in the window and move child windows accordingly. More...
 
bool LineUp ()
 Same as ScrollLines (-1). More...
 
bool LineDown ()
 Same as ScrollLines (1). More...
 
bool PageUp ()
 Same as ScrollPages (-1). More...
 
bool PageDown ()
 Same as ScrollPages (1). More...
 
virtual void SetScrollPos (int orientation, int pos, bool refresh=true)
 Sets the position of one of the built-in scrollbars. More...
 
virtual void SetScrollbar (int orientation, int position, int thumbSize, int range, bool refresh=true)
 Sets the scrollbar properties of a built-in scrollbar. More...
 
void Center (int dir=wxBOTH)
 A synonym for Centre(). More...
 
void CenterOnParent (int dir=wxBOTH)
 A synonym for CentreOnParent(). More...
 
void Centre (int direction=wxBOTH)
 Centres the window. More...
 
void CentreOnParent (int direction=wxBOTH)
 Centres the window on its parent. More...
 
void GetPosition (int *x, int *y) const
 This gets the position of the window in pixels, relative to the parent window for the child windows or relative to the display origin for the top level windows. More...
 
wxPoint GetPosition () const
 This gets the position of the window in pixels, relative to the parent window for the child windows or relative to the display origin for the top level windows. More...
 
wxRect GetRect () const
 Returns the position and size of the window as a wxRect object. More...
 
void GetScreenPosition (int *x, int *y) const
 Returns the window position in screen coordinates, whether the window is a child window or a top level one. More...
 
wxPoint GetScreenPosition () const
 Returns the window position in screen coordinates, whether the window is a child window or a top level one. More...
 
wxRect GetScreenRect () const
 Returns the position and size of the window on the screen as a wxRect object. More...
 
virtual wxPoint GetClientAreaOrigin () const
 Get the origin of the client area of the window relative to the window top left corner (the client area may be shifted because of the borders, scrollbars, other decorations...) More...
 
wxRect GetClientRect () const
 Get the client rectangle in window (i.e. client) coordinates. More...
 
void Move (int x, int y, int flags=wxSIZE_USE_EXISTING)
 Moves the window to the given position. More...
 
void Move (const wxPoint &pt, int flags=wxSIZE_USE_EXISTING)
 Moves the window to the given position. More...
 
void SetPosition (const wxPoint &pt)
 Moves the window to the specified position. More...
 
void ClientToScreen (int *x, int *y) const
 Converts to screen coordinates from coordinates relative to this window. More...
 
wxPoint ClientToScreen (const wxPoint &pt) const
 Converts to screen coordinates from coordinates relative to this window. More...
 
wxPoint ConvertDialogToPixels (const wxPoint &pt) const
 Converts a point or size from dialog units to pixels. More...
 
wxSize ConvertDialogToPixels (const wxSize &sz) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
wxPoint ConvertPixelsToDialog (const wxPoint &pt) const
 Converts a point or size from pixels to dialog units. More...
 
wxSize ConvertPixelsToDialog (const wxSize &sz) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void ScreenToClient (int *x, int *y) const
 Converts from screen to client window coordinates. More...
 
wxPoint ScreenToClient (const wxPoint &pt) const
 Converts from screen to client window coordinates. More...
 
virtual void ClearBackground ()
 Clears the window by filling it with the current background colour. More...
 
void Freeze ()
 Freezes the window or, in other words, prevents any updates from taking place on screen, the window is not redrawn at all. More...
 
void Thaw ()
 Re-enables window updating after a previous call to Freeze(). More...
 
bool IsFrozen () const
 Returns true if the window is currently frozen by a call to Freeze(). More...
 
wxColour GetBackgroundColour () const
 Returns the background colour of the window. More...
 
virtual wxBackgroundStyle GetBackgroundStyle () const
 Returns the background style of the window. More...
 
virtual int GetCharHeight () const
 Returns the character height for this window. More...
 
virtual int GetCharWidth () const
 Returns the average character width for this window. More...
 
virtual wxVisualAttributes GetDefaultAttributes () const
 Currently this is the same as calling wxWindow::GetClassDefaultAttributes(wxWindow::GetWindowVariant()). More...
 
virtual wxSize GetDPI () const
 Return the DPI of the display used by this window. More...
 
wxFont GetFont () const
 Returns the font for this window. More...
 
wxColour GetForegroundColour () const
 Returns the foreground colour of the window. More...
 
void GetTextExtent (const wxString &string, int *w, int *h, int *descent=nullptr, int *externalLeading=nullptr, const wxFont *font=nullptr) const
 Gets the dimensions of the string as it would be drawn on the window with the currently selected font. More...
 
wxSize GetTextExtent (const wxString &string) const
 Gets the dimensions of the string as it would be drawn on the window with the currently selected font. More...
 
const wxRegionGetUpdateRegion () const
 Returns the region specifying which parts of the window have been damaged. More...
 
wxRect GetUpdateClientRect () const
 Get the update rectangle bounding box in client coords. More...
 
virtual bool HasTransparentBackground ()
 Returns true if this window background is transparent (as, for example, for wxStaticText) and should show the parent window background. More...
 
virtual void Refresh (bool eraseBackground=true, const wxRect *rect=nullptr)
 Causes this window, and all of its children recursively, to be repainted. More...
 
void RefreshRect (const wxRect &rect, bool eraseBackground=true)
 Redraws the contents of the given rectangle: only the area inside it will be repainted. More...
 
virtual void Update ()
 Calling this method immediately repaints the invalidated area of the window and all of its children recursively (this normally only happens when the flow of control returns to the event loop). More...
 
virtual bool SetBackgroundColour (const wxColour &colour)
 Sets the background colour of the window. More...
 
virtual bool SetBackgroundStyle (wxBackgroundStyle style)
 Sets the background style of the window. More...
 
virtual bool IsTransparentBackgroundSupported (wxString *reason=nullptr) const
 Checks whether using transparent background might work. More...
 
virtual bool SetFont (const wxFont &font)
 Sets the font for this window. More...
 
virtual bool SetForegroundColour (const wxColour &colour)
 Sets the foreground colour of the window. More...
 
void SetOwnBackgroundColour (const wxColour &colour)
 Sets the background colour of the window but prevents it from being inherited by the children of this window. More...
 
bool InheritsBackgroundColour () const
 Return true if this window inherits the background colour from its parent. More...
 
bool UseBgCol () const
 Return true if a background colour has been set for this window. More...
 
bool UseBackgroundColour () const
 Return true if a background colour has been set for this window. More...
 
void SetOwnFont (const wxFont &font)
 Sets the font of the window but prevents it from being inherited by the children of this window. More...
 
void SetOwnForegroundColour (const wxColour &colour)
 Sets the foreground colour of the window but prevents it from being inherited by the children of this window. More...
 
bool UseForegroundColour () const
 Return true if a foreground colour has been set for this window. More...
 
bool InheritsForegroundColour () const
 Return true if this window inherits the foreground colour from its parent. More...
 
void SetPalette (const wxPalette &pal)
 
virtual bool ShouldInheritColours () const
 Return true from here to allow the colours of this window to be changed by InheritAttributes(). More...
 
virtual void SetThemeEnabled (bool enable)
 This function tells a window if it should use the system's "theme" code to draw the windows' background instead of its own background drawing code. More...
 
virtual bool GetThemeEnabled () const
 Returns true if the window uses the system theme for drawing its background. More...
 
virtual bool CanSetTransparent ()
 Returns true if the system supports transparent windows and calling SetTransparent() may succeed. More...
 
virtual bool SetTransparent (wxByte alpha)
 Set the transparency of the window. More...
 
wxEvtHandlerGetEventHandler () const
 Returns the event handler for this window. More...
 
bool HandleAsNavigationKey (const wxKeyEvent &event)
 This function will generate the appropriate call to Navigate() if the key event is one normally used for keyboard navigation and return true in this case. More...
 
bool HandleWindowEvent (wxEvent &event) const
 Shorthand for: More...
 
bool ProcessWindowEvent (wxEvent &event)
 Convenient wrapper for ProcessEvent(). More...
 
bool ProcessWindowEventLocally (wxEvent &event)
 Wrapper for wxEvtHandler::ProcessEventLocally(). More...
 
wxEvtHandlerPopEventHandler (bool deleteHandler=false)
 Removes and returns the top-most event handler on the event handler stack. More...
 
void PushEventHandler (wxEvtHandler *handler)
 Pushes this event handler onto the event stack for the window. More...
 
bool RemoveEventHandler (wxEvtHandler *handler)
 Find the given handler in the windows event handler stack and removes (but does not delete) it from the stack. More...
 
void SetEventHandler (wxEvtHandler *handler)
 Sets the event handler for this window. More...
 
virtual void SetNextHandler (wxEvtHandler *handler)
 wxWindows cannot be used to form event handler chains; this function thus will assert when called. More...
 
virtual void SetPreviousHandler (wxEvtHandler *handler)
 wxWindows cannot be used to form event handler chains; this function thus will assert when called. More...
 
long GetExtraStyle () const
 Returns the extra style bits for the window. More...
 
virtual long GetWindowStyleFlag () const
 Gets the window style that was passed to the constructor or Create() method. More...
 
long GetWindowStyle () const
 See GetWindowStyleFlag() for more info. More...
 
bool HasExtraStyle (int exFlag) const
 Returns true if the window has the given exFlag bit set in its extra styles. More...
 
bool HasFlag (int flag) const
 Returns true if the window has the given flag bit set. More...
 
virtual void SetExtraStyle (long exStyle)
 Sets the extra style bits for the window. More...
 
virtual void SetWindowStyleFlag (long style)
 Sets the style of the window. More...
 
void SetWindowStyle (long style)
 See SetWindowStyleFlag() for more info. More...
 
bool ToggleWindowStyle (int flag)
 Turns the given flag on if it's currently turned off and vice versa. More...
 
void MoveAfterInTabOrder (wxWindow *win)
 Moves this window in the tab navigation order after the specified win. More...
 
void MoveBeforeInTabOrder (wxWindow *win)
 Same as MoveAfterInTabOrder() except that it inserts this window just before win instead of putting it right after it. More...
 
bool Navigate (int flags=wxNavigationKeyEvent::IsForward)
 Performs a keyboard navigation action starting from this window. More...
 
bool NavigateIn (int flags=wxNavigationKeyEvent::IsForward)
 Performs a keyboard navigation action inside this window. More...
 
virtual void Lower ()
 Lowers the window to the bottom of the window hierarchy (Z-order). More...
 
virtual void Raise ()
 Raises the window to the top of the window hierarchy (Z-order). More...
 
bool Hide ()
 Equivalent to calling wxWindow::Show(false). More...
 
virtual bool HideWithEffect (wxShowEffect effect, unsigned int timeout=0)
 This function hides a window, like Hide(), but using a special visual effect if possible. More...
 
bool IsEnabled () const
 Returns true if the window is enabled, i.e. if it accepts user input, false otherwise. More...
 
bool IsExposed (int x, int y) const
 Returns true if the given point or rectangle area has been exposed since the last repaint. More...
 
bool IsExposed (wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
bool IsExposed (int x, int y, int w, int h) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
bool IsExposed (wxRect &rect) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
virtual bool IsShown () const
 Returns true if the window is shown, false if it has been hidden. More...
 
virtual bool IsShownOnScreen () const
 Returns true if the window is physically visible on the screen, i.e. it is shown and all its parents up to the toplevel window are shown as well. More...
 
bool Disable ()
 Disables the window. More...
 
virtual bool Enable (bool enable=true)
 Enable or disable the window for user input. More...
 
virtual bool Show (bool show=true)
 Shows or hides the window. More...
 
virtual bool ShowWithEffect (wxShowEffect effect, unsigned int timeout=0)
 This function shows a window, like Show(), but using a special visual effect if possible. More...
 
wxString GetHelpText () const
 Gets the help text to be used as context-sensitive help for this window. More...
 
void SetHelpText (const wxString &helpText)
 Sets the help text to be used as context-sensitive help for this window. More...
 
virtual wxString GetHelpTextAtPoint (const wxPoint &point, wxHelpEvent::Origin origin) const
 Gets the help text to be used as context-sensitive help for this window. More...
 
wxToolTipGetToolTip () const
 Get the associated tooltip or nullptr if none. More...
 
wxString GetToolTipText () const
 Get the text of the associated tooltip or empty string if none. More...
 
void SetToolTip (const wxString &tipString)
 Attach a tooltip to the window. More...
 
void SetToolTip (wxToolTip *tip)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void UnsetToolTip ()
 Unset any existing tooltip. More...
 
int GetPopupMenuSelectionFromUser (wxMenu &menu, const wxPoint &pos=wxDefaultPosition)
 This function shows a popup menu at the given position in this window and returns the selected id. More...
 
int GetPopupMenuSelectionFromUser (wxMenu &menu, int x, int y)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
bool PopupMenu (wxMenu *menu, const wxPoint &pos=wxDefaultPosition)
 Pops up the given menu at the specified coordinates, relative to this window, and returns control when the user has dismissed the menu. More...
 
bool PopupMenu (wxMenu *menu, int x, int y)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
virtual wxValidatorGetValidator ()
 Validator functions. More...
 
virtual void SetValidator (const wxValidator &validator)
 Deletes the current validator (if any) and sets the window validator, having called wxValidator::Clone to create a new validator of this type. More...
 
virtual bool TransferDataFromWindow ()
 Transfers values from child controls to data areas specified by their validators. More...
 
virtual bool TransferDataToWindow ()
 Transfers values to child controls from data areas specified by their validators. More...
 
virtual bool Validate ()
 Validates the current values of the child controls using their validators. More...
 
wxWindowID GetId () const
 Returns the identifier of the window. More...
 
virtual wxLayoutDirection GetLayoutDirection () const
 Returns the layout direction for this window, Note that wxLayout_Default is returned if layout direction is not supported. More...
 
virtual wxCoord AdjustForLayoutDirection (wxCoord x, wxCoord width, wxCoord widthTotal) const
 Mirror coordinates for RTL layout if this window uses it and if the mirroring is not done automatically like Win32. More...
 
virtual wxString GetName () const
 Returns the window's name. More...
 
wxWindowVariant GetWindowVariant () const
 Returns the value previously passed to SetWindowVariant(). More...
 
void SetId (wxWindowID winid)
 Sets the identifier of the window. More...
 
virtual void SetLayoutDirection (wxLayoutDirection dir)
 Sets the layout direction for this window. More...
 
virtual void SetName (const wxString &name)
 Sets the window's name. More...
 
void SetWindowVariant (wxWindowVariant variant)
 Chooses a different variant of the window display to use. More...
 
wxAcceleratorTableGetAcceleratorTable ()
 Gets the accelerator table for this window. More...
 
wxAccessibleGetAccessible ()
 Returns the accessible object for this window, if any. More...
 
virtual void SetAcceleratorTable (const wxAcceleratorTable &accel)
 Sets the accelerator table for this window. More...
 
void SetAccessible (wxAccessible *accessible)
 Sets the accessible for this window. More...
 
virtual wxAccessibleCreateAccessible ()
 Override to create a specific accessible object. More...
 
wxAccessibleGetOrCreateAccessible ()
 Returns the accessible object, calling CreateAccessible if necessary. More...
 
bool Close (bool force=false)
 This function simply generates a wxCloseEvent whose handler usually tries to close the window. More...
 
virtual bool Destroy ()
 Destroys the window safely. More...
 
bool IsBeingDeleted () const
 Returns true if this window is in process of being destroyed. More...
 
virtual wxDropTargetGetDropTarget () const
 Returns the associated drop target, which may be nullptr. More...
 
virtual void SetDropTarget (wxDropTarget *target)
 Associates a drop target with this window. More...
 
virtual void DragAcceptFiles (bool accept)
 Enables or disables eligibility for drop file events (OnDropFiles). More...
 
wxSizerGetContainingSizer () const
 Returns the sizer of which this window is a member, if any, otherwise nullptr. More...
 
wxSizerGetSizer () const
 Returns the sizer associated with the window by a previous call to SetSizer(), or nullptr. More...
 
void SetSizer (wxSizer *sizer, bool deleteOld=true)
 Sets the window to have the given layout sizer. More...
 
void SetSizerAndFit (wxSizer *sizer, bool deleteOld=true)
 Associate the sizer with the window and set the window size and minimal size accordingly. More...
 
wxLayoutConstraintsGetConstraints () const
 Returns a pointer to the window's layout constraints, or nullptr if there are none. More...
 
void SetConstraints (wxLayoutConstraints *constraints)
 Sets the window to have the given layout constraints. More...
 
virtual bool Layout ()
 Lays out the children of this window using the associated sizer. More...
 
void SetAutoLayout (bool autoLayout)
 Determines whether the Layout() function will be called automatically when the window is resized. More...
 
bool GetAutoLayout () const
 Returns true if Layout() is called automatically when the window is resized. More...
 
void CaptureMouse ()
 Directs all mouse input to this window. More...
 
wxCaretGetCaret () const
 Returns the caret() associated with the window. More...
 
const wxCursorGetCursor () const
 Return the cursor associated with this window. More...
 
virtual bool HasCapture () const
 Returns true if this window has the current mouse capture. More...
 
void ReleaseMouse ()
 Releases mouse input captured with CaptureMouse(). More...
 
void SetCaret (wxCaret *caret)
 Sets the caret() associated with the window. More...
 
virtual bool SetCursor (const wxCursor &cursor)
 Sets the window's cursor. More...
 
virtual void WarpPointer (int x, int y)
 Moves the pointer to the given position on the window. More...
 
virtual bool EnableTouchEvents (int eventsMask)
 Request generation of touch events for this window. More...
 
wxHitTest HitTest (wxCoord x, wxCoord y) const
 Return where the given point lies, exactly. More...
 
wxHitTest HitTest (const wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
wxBorder GetBorder (long flags) const
 Get the window border style from the given flags: this is different from simply doing flags & wxBORDER_MASK because it uses GetDefaultBorder() to translate wxBORDER_DEFAULT to something reasonable. More...
 
wxBorder GetBorder () const
 Get border for the flags of this window. More...
 
virtual void DoUpdateWindowUI (wxUpdateUIEvent &event)
 Does the window-specific updating after processing the update event. More...
 
virtual WXWidget GetHandle () const
 Returns the platform-specific handle of the physical window. More...
 
WXHWND GTKGetWin32Handle () const
 This function is used only with wxGTK when running on Windows, to receive a wxWindow's underlying HWND. More...
 
virtual bool HasMultiplePages () const
 This method should be overridden to return true if this window has multiple pages. More...
 
virtual void InheritAttributes ()
 This function is (or should be, in case of custom controls) called during window creation to intelligently set up the window visual attributes, that is the font and the foreground and background colours. More...
 
virtual void InitDialog ()
 Sends an wxEVT_INIT_DIALOG event, whose handler usually transfers data to the dialog via validators. More...
 
virtual bool IsDoubleBuffered () const
 Returns true if the window contents is double-buffered by the system, i.e. if any drawing done on the window is really done on a temporary backing surface and transferred to the screen all at once later. More...
 
void SetDoubleBuffered (bool on)
 Turn on or off double buffering of the window if the system supports it. More...
 
virtual bool IsRetained () const
 Returns true if the window is retained, false otherwise. More...
 
bool IsThisEnabled () const
 Returns true if this window is intrinsically enabled, false otherwise, i.e. if Enable() Enable(false) had been called. More...
 
virtual bool IsTopLevel () const
 Returns true if the given window is a top-level one. More...
 
virtual void OnInternalIdle ()
 This virtual function is normally only used internally, but sometimes an application may need it to implement functionality that should not be disabled by an application defining an OnIdle handler in a derived class. More...
 
virtual bool SendIdleEvents (wxIdleEvent &event)
 Send idle event to window and all subwindows. More...
 
virtual bool RegisterHotKey (int hotkeyId, int modifiers, int virtualKeyCode)
 Registers a system wide hotkey. More...
 
virtual bool UnregisterHotKey (int hotkeyId)
 Unregisters a system wide hotkey. More...
 
virtual void UpdateWindowUI (long flags=wxUPDATE_UI_NONE)
 This function sends one or more wxUpdateUIEvent to the window. More...
 
bool BeginRepositioningChildren ()
 Prepare for changing positions of multiple child windows. More...
 
void EndRepositioningChildren ()
 Fix child window positions after setting all of them at once. More...
 
void CacheBestSize (const wxSize &size) const
 Sets the cached best size value. More...
 
virtual wxSize ClientToWindowSize (const wxSize &size) const
 Converts client area size size to corresponding window size. More...
 
virtual wxSize WindowToClientSize (const wxSize &size) const
 Converts window size size to corresponding client area size In other words, the returned value is what would GetClientSize() return if this window had given window size. More...
 
virtual void Fit ()
 Sizes the window to fit its best size. More...
 
virtual void FitInside ()
 Similar to Fit(), but sizes the interior (virtual) size of a window. More...
 
wxSize FromDIP (const wxSize &sz) const
 Convert DPI-independent pixel values to the value in pixels appropriate for the current toolkit. More...
 
wxPoint FromDIP (const wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
int FromDIP (int d) const
 Convert DPI-independent distance in pixels to the value in pixels appropriate for the current toolkit. More...
 
wxSize ToDIP (const wxSize &sz) const
 Convert pixel values of the current toolkit to DPI-independent pixel values. More...
 
wxPoint ToDIP (const wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
int ToDIP (int d) const
 Convert pixel values of the current toolkit to DPI-independent pixel values. More...
 
wxSize FromPhys (const wxSize &sz) const
 Convert from physical pixels to logical pixels. More...
 
wxPoint FromPhys (const wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
int FromPhys (int d) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
wxSize ToPhys (const wxSize &sz) const
 Convert from logical pixels to physical pixels. More...
 
wxPoint ToPhys (const wxPoint &pt) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
int ToPhys (int d) const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
wxSize GetBestSize () const
 This functions returns the best acceptable minimal size for the window. More...
 
int GetBestHeight (int width) const
 Returns the best height needed by this window if it had the given width. More...
 
int GetBestWidth (int height) const
 Returns the best width needed by this window if it had the given height. More...
 
void GetClientSize (int *width, int *height) const
 Returns the size of the window 'client area' in pixels. More...
 
wxSize GetClientSize () const
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
virtual wxSize GetEffectiveMinSize () const
 Merges the window's best size into the min size and returns the result. More...
 
virtual wxSize GetMaxClientSize () const
 Returns the maximum size of window's client area. More...
 
virtual wxSize GetMaxSize () const
 Returns the maximum size of the window. More...
 
virtual wxSize GetMinClientSize () const
 Returns the minimum size of window's client area, an indication to the sizer layout mechanism that this is the minimum required size of its client area. More...
 
virtual wxSize GetMinSize () const
 Returns the minimum size of the window, an indication to the sizer layout mechanism that this is the minimum required size. More...
 
int GetMinWidth () const
 Returns the horizontal component of window minimal size. More...
 
int GetMinHeight () const
 Returns the vertical component of window minimal size. More...
 
int GetMaxWidth () const
 Returns the horizontal component of window maximal size. More...
 
int GetMaxHeight () const
 Returns the vertical component of window maximal size. More...
 
void GetSize (int *width, int *height) const
 Returns the size of the entire window in pixels, including title bar, border, scrollbars, etc. More...
 
wxSize GetSize () const
 See the GetSize(int*,int*) overload for more info. More...
 
wxSize GetVirtualSize () const
 This gets the virtual size of the window in pixels. More...
 
void GetVirtualSize (int *width, int *height) const
 Like the other GetVirtualSize() overload but uses pointers instead. More...
 
virtual wxSize GetBestVirtualSize () const
 Return the largest of ClientSize and BestSize (as determined by a sizer, interior children, or other means) More...
 
double GetContentScaleFactor () const
 Returns the factor mapping logical pixels of this window to physical pixels. More...
 
double GetDPIScaleFactor () const
 Returns the ratio of the DPI used by this window to the standard DPI. More...
 
virtual wxSize GetWindowBorderSize () const
 Returns the size of the left/right and top/bottom borders of this window in x and y components of the result respectively. More...
 
virtual bool InformFirstDirection (int direction, int size, int availableOtherDir)
 wxSizer and friends use this to give a chance to a component to recalc its min size once one of the final size components is known. More...
 
void InvalidateBestSize ()
 Resets the cached best size value so it will be recalculated the next time it is needed. More...
 
void PostSizeEvent ()
 Posts a size event to the window. More...
 
void PostSizeEventToParent ()
 Posts a size event to the parent of this window. More...
 
virtual void SendSizeEvent (int flags=0)
 This function sends a dummy size event to the window allowing it to re-layout its children positions. More...
 
void SendSizeEventToParent (int flags=0)
 Safe wrapper for GetParent()->SendSizeEvent(). More...
 
void SetClientSize (int width, int height)
 This sets the size of the window client area in pixels. More...
 
void SetClientSize (const wxSize &size)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void SetClientSize (const wxRect &rect)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void SetContainingSizer (wxSizer *sizer)
 Used by wxSizer internally to notify the window about being managed by the given sizer. More...
 
void SetInitialSize (const wxSize &size=wxDefaultSize)
 A smart SetSize that will fill in default size components with the window's best size values. More...
 
virtual void SetMaxClientSize (const wxSize &size)
 Sets the maximum client size of the window, to indicate to the sizer layout mechanism that this is the maximum possible size of its client area. More...
 
virtual void SetMaxSize (const wxSize &size)
 Sets the maximum size of the window, to indicate to the sizer layout mechanism that this is the maximum possible size. More...
 
virtual void SetMinClientSize (const wxSize &size)
 Sets the minimum client size of the window, to indicate to the sizer layout mechanism that this is the minimum required size of window's client area. More...
 
virtual void SetMinSize (const wxSize &size)
 Sets the minimum size of the window, to indicate to the sizer layout mechanism that this is the minimum required size. More...
 
void SetSize (int x, int y, int width, int height, int sizeFlags=wxSIZE_AUTO)
 Sets the size of the window in pixels. More...
 
void SetSize (const wxRect &rect)
 Sets the size of the window in pixels. More...
 
void SetSize (const wxSize &size)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void SetSize (int width, int height)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
virtual void SetSizeHints (const wxSize &minSize, const wxSize &maxSize=wxDefaultSize, const wxSize &incSize=wxDefaultSize)
 Use of this function for windows which are not toplevel windows (such as wxDialog or wxFrame) is discouraged. More...
 
virtual void SetSizeHints (int minW, int minH, int maxW=-1, int maxH=-1, int incW=-1, int incH=-1)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
void SetVirtualSize (int width, int height)
 Sets the virtual size of the window in pixels. More...
 
void SetVirtualSize (const wxSize &size)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
- Public Member Functions inherited from wxEvtHandler
 wxEvtHandler ()
 Constructor. More...
 
virtual ~wxEvtHandler ()
 Destructor. More...
 
template<typename T , typename T1 , ... >
void CallAfter (void(T::*method)(T1,...), T1 x1,...)
 Asynchronously call the given method. More...
 
template<typename T >
void CallAfter (const T &functor)
 Asynchronously call the given functor. More...
 
bool ProcessEventLocally (wxEvent &event)
 Try to process the event in this handler and all those chained to it. More...
 
bool SafelyProcessEvent (wxEvent &event)
 Processes an event by calling ProcessEvent() and handles any exceptions that occur in the process. More...
 
void ProcessPendingEvents ()
 Processes the pending events previously queued using QueueEvent() or AddPendingEvent(); you must call this function only if you are sure there are pending events for this handler, otherwise a wxCHECK will fail. More...
 
void DeletePendingEvents ()
 Deletes all events queued on this event handler using QueueEvent() or AddPendingEvent(). More...
 
void Connect (int id, int lastId, wxEventType eventType, wxObjectEventFunction function, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 Connects the given function dynamically with the event handler, id and event type. More...
 
void Connect (int id, wxEventType eventType, wxObjectEventFunction function, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 See the Connect(int, int, wxEventType, wxObjectEventFunction, wxObject*, wxEvtHandler*) overload for more info. More...
 
void Connect (wxEventType eventType, wxObjectEventFunction function, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 See the Connect(int, int, wxEventType, wxObjectEventFunction, wxObject*, wxEvtHandler*) overload for more info. More...
 
bool Disconnect (wxEventType eventType, wxObjectEventFunction function, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 Disconnects the given function dynamically from the event handler, using the specified parameters as search criteria and returning true if a matching function has been found and removed. More...
 
bool Disconnect (int id=wxID_ANY, wxEventType eventType=wxEVT_NULL, wxObjectEventFunction function=nullptr, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 See the Disconnect(wxEventType, wxObjectEventFunction, wxObject*, wxEvtHandler*) overload for more info. More...
 
bool Disconnect (int id, int lastId, wxEventType eventType, wxObjectEventFunction function=nullptr, wxObject *userData=nullptr, wxEvtHandler *eventSink=nullptr)
 See the Disconnect(wxEventType, wxObjectEventFunction, wxObject*, wxEvtHandler*) overload for more info. More...
 
template<typename EventTag , typename Functor >
void Bind (const EventTag &eventType, Functor functor, int id=wxID_ANY, int lastId=wxID_ANY, wxObject *userData=nullptr)
 Binds the given function, functor or method dynamically with the event. More...
 
template<typename EventTag , typename Class , typename EventArg , typename EventHandler >
void Bind (const EventTag &eventType, void(Class::*method)(EventArg &), EventHandler *handler, int id=wxID_ANY, int lastId=wxID_ANY, wxObject *userData=nullptr)
 See the Bind<>(const EventTag&, Functor, int, int, wxObject*) overload for more info. More...
 
template<typename EventTag , typename Functor >
bool Unbind (const EventTag &eventType, Functor functor, int id=wxID_ANY, int lastId=wxID_ANY, wxObject *userData=nullptr)
 Unbinds the given function, functor or method dynamically from the event handler, using the specified parameters as search criteria and returning true if a matching function has been found and removed. More...
 
template<typename EventTag , typename Class , typename EventArg , typename EventHandler >
bool Unbind (const EventTag &eventType, void(Class::*method)(EventArg &), EventHandler *handler, int id=wxID_ANY, int lastId=wxID_ANY, wxObject *userData=nullptr)
 See the Unbind<>(const EventTag&, Functor, int, int, wxObject*) overload for more info. More...
 
void * GetClientData () const
 Returns user-supplied client data. More...
 
wxClientDataGetClientObject () const
 Returns a pointer to the user-supplied client data object. More...
 
void SetClientData (void *data)
 Sets user-supplied client data. More...
 
void SetClientObject (wxClientData *data)
 Set the client data object. More...
 
bool GetEvtHandlerEnabled () const
 Returns true if the event handler is enabled, false otherwise. More...
 
wxEvtHandlerGetNextHandler () const
 Returns the pointer to the next handler in the chain. More...
 
wxEvtHandlerGetPreviousHandler () const
 Returns the pointer to the previous handler in the chain. More...
 
void SetEvtHandlerEnabled (bool enabled)
 Enables or disables the event handler. More...
 
void Unlink ()
 Unlinks this event handler from the chain it's part of (if any); then links the "previous" event handler to the "next" one (so that the chain won't be interrupted). More...
 
bool IsUnlinked () const
 Returns true if the next and the previous handler pointers of this event handler instance are nullptr. More...
 
- Public Member Functions inherited from wxObject
 wxObject ()
 Default ctor; initializes to nullptr the internal reference data. More...
 
 wxObject (const wxObject &other)
 Copy ctor. More...
 
virtual ~wxObject ()
 Destructor. More...
 
virtual wxClassInfoGetClassInfo () const
 This virtual function is redefined for every class that requires run-time type information, when using the wxDECLARE_CLASS macro (or similar). More...
 
wxObjectRefDataGetRefData () const
 Returns the wxObject::m_refData pointer, i.e. the data referenced by this object. More...
 
bool IsKindOf (const wxClassInfo *info) const
 Determines whether this class is a subclass of (or the same class as) the given class. More...
 
bool IsSameAs (const wxObject &obj) const
 Returns true if this object has the same data pointer as obj. More...
 
void Ref (const wxObject &clone)
 Makes this object refer to the data in clone. More...
 
void SetRefData (wxObjectRefData *data)
 Sets the wxObject::m_refData pointer. More...
 
void UnRef ()
 Decrements the reference count in the associated data, and if it is zero, deletes the data. More...
 
void UnShare ()
 This is the same of AllocExclusive() but this method is public. More...
 
void operator delete (void *buf)
 The delete operator is defined for debugging versions of the library only, when the identifier __WXDEBUG__ is defined. More...
 
void * operator new (size_t size, const wxString &filename=nullptr, int lineNum=0)
 The new operator is defined for debugging versions of the library only, when the identifier __WXDEBUG__ is defined. More...
 
- Public Member Functions inherited from wxTextEntry
bool AutoComplete (const wxArrayString &choices)
 Call this function to enable auto-completion of the text typed in a single-line text control using the given choices. More...
 
bool AutoComplete (wxTextCompleter *completer)
 Enable auto-completion using the provided completer object. More...
 
bool AutoCompleteFileNames ()
 Call this function to enable auto-completion of the text typed in a single-line text control using all valid file system paths. More...
 
bool AutoCompleteDirectories ()
 Call this function to enable auto-completion of the text using the file system directories. More...
 
virtual bool CanCopy () const
 Returns true if the selection can be copied to the clipboard. More...
 
virtual bool CanCut () const
 Returns true if the selection can be cut to the clipboard. More...
 
virtual void ChangeValue (const wxString &value)
 Sets the new text control value. More...
 
void ForceUpper ()
 Convert all text entered into the control to upper case. More...
 
virtual wxString GetRange (long from, long to) const
 Returns the string containing the text starting in the positions from and up to to in the control. More...
 
virtual wxString GetStringSelection () const
 Gets the text currently selected in the control. More...
 
virtual wxString GetValue () const
 Gets the contents of the control. More...
 
virtual bool IsEmpty () const
 Returns true if the control is currently empty. More...
 
virtual void SetInsertionPointEnd ()
 Sets the insertion point at the end of the text control. More...
 
virtual void SetMaxLength (unsigned long len)
 This function sets the maximum number of characters the user can enter into the control. More...
 
virtual bool SetHint (const wxString &hint)
 Sets a hint shown in an empty unfocused text control. More...
 
virtual wxString GetHint () const
 Returns the current hint string. More...
 
wxPoint GetMargins () const
 Returns the margins used by the control. More...
 
virtual void SetValue (const wxString &value)
 Sets the new text control value. More...
 
bool SetMargins (const wxPoint &pt)
 Attempts to set the control margins. More...
 
bool SetMargins (wxCoord left, wxCoord top=-1)
 Attempts to set the control margins. More...
 

Static Public Member Functions

static wxVersionInfo GetLibraryVersionInfo ()
 Returns the version of the Scintilla library used by this control. More...
 
- Static Public Member Functions inherited from wxControl
static wxString GetLabelText (const wxString &label)
 Returns the given label string without mnemonics ("&" characters). More...
 
static wxString RemoveMnemonics (const wxString &str)
 Returns the given str string without mnemonics ("&" characters). More...
 
static wxString EscapeMnemonics (const wxString &text)
 Escapes the special mnemonics characters ("&") in the given string. More...
 
static wxString Ellipsize (const wxString &label, const wxDC &dc, wxEllipsizeMode mode, int maxWidth, int flags=wxELLIPSIZE_FLAGS_DEFAULT)
 Replaces parts of the label string with ellipsis, if needed, so that it fits into maxWidth pixels if possible. More...
 
- Static Public Member Functions inherited from wxWindow
static wxVisualAttributes GetClassDefaultAttributes (wxWindowVariant variant=wxWINDOW_VARIANT_NORMAL)
 Returns the default font and colours which are used by the control. More...
 
static wxWindowFindFocus ()
 Finds the window or control which currently has the keyboard focus. More...
 
static wxWindowFindWindowById (long id, const wxWindow *parent=0)
 Find the first window with the given id. More...
 
static wxWindowFindWindowByLabel (const wxString &label, const wxWindow *parent=0)
 Find a window by its label. More...
 
static wxWindowFindWindowByName (const wxString &name, const wxWindow *parent=0)
 Find a window by its name (as given in a window constructor or Create() function call). More...
 
static wxWindowGetCapture ()
 Returns the currently captured window. More...
 
static wxWindowID NewControlId (int count=1)
 Create a new ID or range of IDs that are not currently in use. More...
 
static void UnreserveControlId (wxWindowID id, int count=1)
 Unreserve an ID or range of IDs that was reserved by NewControlId(). More...
 
static wxSize FromDIP (const wxSize &sz, const wxWindow *w)
 Non window-specific DPI-independent pixels conversion functions. More...
 
static wxPoint FromDIP (const wxPoint &pt, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static int FromDIP (int d, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static wxSize ToDIP (const wxSize &sz, const wxWindow *w)
 Non window-specific pixel to DPI-independent pixels conversion functions. More...
 
static wxPoint ToDIP (const wxPoint &pt, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static int ToDIP (int d, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static wxSize FromPhys (const wxSize &sz, const wxWindow *w)
 Convert from physical pixels to logical pixels for any window. More...
 
static wxPoint FromPhys (const wxPoint &pt, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static int FromPhys (int d, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static wxSize ToPhys (const wxSize &sz, const wxWindow *w)
 Convert from logical pixels to physical pixels for any window. More...
 
static wxPoint ToPhys (const wxPoint &pt, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
static int ToPhys (int d, const wxWindow *w)
 This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. More...
 
- Static Public Member Functions inherited from wxEvtHandler
static void AddFilter (wxEventFilter *filter)
 Add an event filter whose FilterEvent() method will be called for each and every event processed by wxWidgets. More...
 
static void RemoveFilter (wxEventFilter *filter)
 Remove a filter previously installed with AddFilter(). More...
 

Additional Inherited Members

- Protected Member Functions inherited from wxWindow
virtual void DoCentre (int direction)
 Centres the window. More...
 
virtual wxSize DoGetBestSize () const
 Implementation of GetBestSize() that can be overridden. More...
 
virtual wxSize DoGetBestClientSize () const
 Override this method to return the best size for a custom control. More...
 
virtual int DoGetBestClientHeight (int width) const
 Override this method to implement height-for-width best size calculation. More...
 
virtual int DoGetBestClientWidth (int height) const
 Override this method to implement width-for-height best size calculation. More...
 
virtual void SetInitialBestSize (const wxSize &size)
 Sets the initial window size if none is given (i.e. at least one of the components of the size passed to ctor/Create() is wxDefaultCoord). More...
 
void SendDestroyEvent ()
 Generate wxWindowDestroyEvent for this window. More...
 
virtual bool ProcessEvent (wxEvent &event)
 This function is public in wxEvtHandler but protected in wxWindow because for wxWindows you should always call ProcessEvent() on the pointer returned by GetEventHandler() and not on the wxWindow object itself. More...
 
bool SafelyProcessEvent (wxEvent &event)
 See ProcessEvent() for more info about why you shouldn't use this function and the reason for making this function protected in wxWindow. More...
 
virtual void QueueEvent (wxEvent *event)
 See ProcessEvent() for more info about why you shouldn't use this function and the reason for making this function protected in wxWindow. More...
 
virtual void AddPendingEvent (const wxEvent &event)
 See ProcessEvent() for more info about why you shouldn't use this function and the reason for making this function protected in wxWindow. More...
 
void ProcessPendingEvents ()
 See ProcessEvent() for more info about why you shouldn't use this function and the reason for making this function protected in wxWindow. More...
 
bool ProcessThreadEvent (const wxEvent &event)
 See ProcessEvent() for more info about why you shouldn't use this function and the reason for making this function protected in wxWindow. More...
 
- Protected Member Functions inherited from wxEvtHandler
virtual bool TryBefore (wxEvent &event)
 Method called by ProcessEvent() before examining this object event tables. More...
 
virtual bool TryAfter (wxEvent &event)
 Method called by ProcessEvent() as last resort. More...
 
- Protected Member Functions inherited from wxObject
void AllocExclusive ()
 Ensure that this object's data is not shared with any other object. More...
 
virtual wxObjectRefDataCreateRefData () const
 Creates a new instance of the wxObjectRefData-derived class specific to this object and returns it. More...
 
virtual wxObjectRefDataCloneRefData (const wxObjectRefData *data) const
 Creates a new instance of the wxObjectRefData-derived class specific to this object and initializes it copying data. More...
 
- Protected Attributes inherited from wxObject
wxObjectRefDatam_refData
 Pointer to an object which is the object's reference-counted data. More...
 

Constructor & Destructor Documentation

◆ wxStyledTextCtrl() [1/2]

wxStyledTextCtrl::wxStyledTextCtrl ( wxWindow parent,
wxWindowID  id = wxID_ANY,
const wxPoint pos = wxDefaultPosition,
const wxSize size = wxDefaultSize,
long  style = 0,
const wxString name = wxSTCNameStr 
)

Ctor.

◆ wxStyledTextCtrl() [2/2]

wxStyledTextCtrl::wxStyledTextCtrl ( )

Default ctor.

◆ ~wxStyledTextCtrl()

wxStyledTextCtrl::~wxStyledTextCtrl ( )

Destructor.

Member Function Documentation

◆ AddRefDocument()

void wxStyledTextCtrl::AddRefDocument ( void *  docPointer)

Extend life of document.

◆ AddSelection()

void wxStyledTextCtrl::AddSelection ( int  caret,
int  anchor 
)

Add a selection.

◆ AddStyledText()

void wxStyledTextCtrl::AddStyledText ( const wxMemoryBuffer data)

Add array of cells to document.

◆ AddTabStop()

void wxStyledTextCtrl::AddTabStop ( int  line,
int  x 
)

Add an explicit tab stop for a line.

Since
3.1.0

◆ AddText()

void wxStyledTextCtrl::AddText ( const wxString text)

Add text to the document at current position.

◆ AddTextRaw()

void wxStyledTextCtrl::AddTextRaw ( const char *  text,
int  length = -1 
)

Add text to the document at current position.

◆ AddUndoAction()

void wxStyledTextCtrl::AddUndoAction ( int  token,
int  flags 
)

Add a container action to the undo stack.

The flags argument can be either 0 or wxSTC_UNDO_MAY_COALESCE.

◆ Allocate()

void wxStyledTextCtrl::Allocate ( int  bytes)

Enlarge the document to a particular size of text bytes.

◆ AllocateExtendedStyles()

int wxStyledTextCtrl::AllocateExtendedStyles ( int  numberStyles)

Allocate some extended (>255) style numbers and return the start of the range.

Since
3.1.0

◆ AllocateSubStyles()

int wxStyledTextCtrl::AllocateSubStyles ( int  styleBase,
int  numberStyles 
)

Allocate a set of sub styles for a particular base style, returning start of range.

Since
3.1.0

◆ AnnotationClearAll()

void wxStyledTextCtrl::AnnotationClearAll ( )

Clear the annotations from all lines.

◆ AnnotationClearLine()

void wxStyledTextCtrl::AnnotationClearLine ( int  line)

Clear annotations from the given line.

◆ AnnotationGetLines()

int wxStyledTextCtrl::AnnotationGetLines ( int  line) const

Get the number of annotation lines for a line.

◆ AnnotationGetStyle()

int wxStyledTextCtrl::AnnotationGetStyle ( int  line) const

Get the style number for the annotations for a line.

◆ AnnotationGetStyleOffset()

int wxStyledTextCtrl::AnnotationGetStyleOffset ( ) const

Get the start of the range of style numbers used for annotations.

◆ AnnotationGetStyles()

wxString wxStyledTextCtrl::AnnotationGetStyles ( int  line) const

Get the annotation styles for a line.

◆ AnnotationGetText()

wxString wxStyledTextCtrl::AnnotationGetText ( int  line) const

Get the annotation text for a line.

◆ AnnotationGetVisible()

int wxStyledTextCtrl::AnnotationGetVisible ( ) const

Get the visibility for the annotations for a view.

The return value will be one of the wxSTC_ANNOTATION_* constants.

◆ AnnotationSetStyle()

void wxStyledTextCtrl::AnnotationSetStyle ( int  line,
int  style 
)

Set the style number for the annotations for a line.

◆ AnnotationSetStyleOffset()

void wxStyledTextCtrl::AnnotationSetStyleOffset ( int  style)

Get the start of the range of style numbers used for annotations.

◆ AnnotationSetStyles()

void wxStyledTextCtrl::AnnotationSetStyles ( int  line,
const wxString styles 
)

Set the annotation styles for a line.

◆ AnnotationSetText()

void wxStyledTextCtrl::AnnotationSetText ( int  line,
const wxString text 
)

Set the annotation text for a line.

◆ AnnotationSetVisible()

void wxStyledTextCtrl::AnnotationSetVisible ( int  visible)

Set the visibility for the annotations for a view.

The input should be one of the wxSTC_ANNOTATION_* constants.

◆ AppendText()

void wxStyledTextCtrl::AppendText ( const wxString text)
virtual

Append a string to the end of the document without changing the selection.

Reimplemented from wxTextEntry.

◆ AppendTextRaw()

void wxStyledTextCtrl::AppendTextRaw ( const char *  text,
int  length = -1 
)

Append a string to the end of the document without changing the selection.

◆ AutoCompActive()

bool wxStyledTextCtrl::AutoCompActive ( )

Is there an auto-completion list visible?

◆ AutoCompCancel()

void wxStyledTextCtrl::AutoCompCancel ( )

Remove the auto-completion list from the screen.

◆ AutoCompComplete()

void wxStyledTextCtrl::AutoCompComplete ( )

User has selected an item so remove the list and insert the selection.

◆ AutoCompGetAutoHide()

bool wxStyledTextCtrl::AutoCompGetAutoHide ( ) const

Retrieve whether or not autocompletion is hidden automatically when nothing matches.

◆ AutoCompGetCancelAtStart()

bool wxStyledTextCtrl::AutoCompGetCancelAtStart ( ) const

Retrieve whether auto-completion cancelled by backspacing before start.

◆ AutoCompGetCaseInsensitiveBehaviour()

int wxStyledTextCtrl::AutoCompGetCaseInsensitiveBehaviour ( ) const

Get auto-completion case insensitive behaviour.

The return value will be one of the wxSTC_CASEINSENSITIVEBEHAVIOUR_* constants.

◆ AutoCompGetChooseSingle()

bool wxStyledTextCtrl::AutoCompGetChooseSingle ( ) const

Retrieve whether a single item auto-completion list automatically choose the item.

◆ AutoCompGetCurrent()

int wxStyledTextCtrl::AutoCompGetCurrent ( ) const

Get currently selected item position in the auto-completion list.

◆ AutoCompGetCurrentText()

wxString wxStyledTextCtrl::AutoCompGetCurrentText ( ) const

Get currently selected item text in the auto-completion list.

Since
3.1.1

◆ AutoCompGetDropRestOfWord()

bool wxStyledTextCtrl::AutoCompGetDropRestOfWord ( ) const

Retrieve whether or not autocompletion deletes any word characters after the inserted text upon completion.

◆ AutoCompGetIgnoreCase()

bool wxStyledTextCtrl::AutoCompGetIgnoreCase ( ) const

Retrieve state of ignore case flag.

◆ AutoCompGetMaxHeight()

int wxStyledTextCtrl::AutoCompGetMaxHeight ( ) const

Set the maximum height, in rows, of auto-completion and user lists.

◆ AutoCompGetMaxWidth()

int wxStyledTextCtrl::AutoCompGetMaxWidth ( ) const

Get the maximum width, in characters, of auto-completion and user lists.

◆ AutoCompGetMulti()

int wxStyledTextCtrl::AutoCompGetMulti ( ) const

Retrieve the effect of autocompleting when there are multiple selections.

The return value will be one of the wxSTC_MULTIAUTOC_* constants.

Since
3.1.0

◆ AutoCompGetOrder()

int wxStyledTextCtrl::AutoCompGetOrder ( ) const

Get the way autocompletion lists are ordered.

The return value will be one of the wxSTC_ORDER_* constants.

Since
3.1.0

◆ AutoCompGetSeparator()

int wxStyledTextCtrl::AutoCompGetSeparator ( ) const

Retrieve the auto-completion list separator character.

◆ AutoCompGetTypeSeparator()

int wxStyledTextCtrl::AutoCompGetTypeSeparator ( ) const

Retrieve the auto-completion list type-separator character.

◆ AutoCompPosStart()

int wxStyledTextCtrl::AutoCompPosStart ( )

Retrieve the position of the caret when the auto-completion list was displayed.

◆ AutoCompSelect()

void wxStyledTextCtrl::AutoCompSelect ( const wxString select)

Select the item in the auto-completion list that starts with a string.

◆ AutoCompSetAutoHide()

void wxStyledTextCtrl::AutoCompSetAutoHide ( bool  autoHide)

Set whether or not autocompletion is hidden automatically when nothing matches.

◆ AutoCompSetCancelAtStart()

void wxStyledTextCtrl::AutoCompSetCancelAtStart ( bool  cancel)

Should the auto-completion list be cancelled if the user backspaces to a position before where the box was created.

◆ AutoCompSetCaseInsensitiveBehaviour()

void wxStyledTextCtrl::AutoCompSetCaseInsensitiveBehaviour ( int  behaviour)

Set auto-completion case insensitive behaviour to either prefer case-sensitive matches or have no preference.

The input should be one of the wxSTC_CASEINSENSITIVEBEHAVIOUR_* constants.

◆ AutoCompSetChooseSingle()

void wxStyledTextCtrl::AutoCompSetChooseSingle ( bool  chooseSingle)

Should a single item auto-completion list automatically choose the item.

◆ AutoCompSetDropRestOfWord()

void wxStyledTextCtrl::AutoCompSetDropRestOfWord ( bool  dropRestOfWord)

Set whether or not autocompletion deletes any word characters after the inserted text upon completion.

◆ AutoCompSetFillUps()

void wxStyledTextCtrl::AutoCompSetFillUps ( const wxString characterSet)

Define a set of characters that when typed will cause the autocompletion to choose the selected item.

◆ AutoCompSetIgnoreCase()

void wxStyledTextCtrl::AutoCompSetIgnoreCase ( bool  ignoreCase)

Set whether case is significant when performing auto-completion searches.

◆ AutoCompSetMaxHeight()

void wxStyledTextCtrl::AutoCompSetMaxHeight ( int  rowCount)

Set the maximum height, in rows, of auto-completion and user lists.

The default is 5 rows.

◆ AutoCompSetMaxWidth()

void wxStyledTextCtrl::AutoCompSetMaxWidth ( int  characterCount)

Set the maximum width, in characters, of auto-completion and user lists.

Set to 0 to autosize to fit longest item, which is the default.

◆ AutoCompSetMulti()

void wxStyledTextCtrl::AutoCompSetMulti ( int  multi)

Change the effect of autocompleting when there are multiple selections.

The input should be one of the wxSTC_MULTIAUTOC_* constants.

Since
3.1.0

◆ AutoCompSetOrder()

void wxStyledTextCtrl::AutoCompSetOrder ( int  order)

Set the way autocompletion lists are ordered.

The input should be one of the wxSTC_ORDER_* constants.

Since
3.1.0

◆ AutoCompSetSeparator()

void wxStyledTextCtrl::AutoCompSetSeparator ( int  separatorCharacter)

Change the separator character in the string setting up an auto-completion list.

Default is space but can be changed if items contain space.

◆ AutoCompSetTypeSeparator()

void wxStyledTextCtrl::AutoCompSetTypeSeparator ( int  separatorCharacter)

Change the type-separator character in the string setting up an auto-completion list.

Default is '?' but can be changed if items contain '?'.

◆ AutoCompShow()

void wxStyledTextCtrl::AutoCompShow ( int  lengthEntered,
const wxString itemList 
)

Display a auto-completion list.

The lengthEntered parameter indicates how many characters before the caret should be used to provide context.

◆ AutoCompStops()

void wxStyledTextCtrl::AutoCompStops ( const wxString characterSet)

Define a set of character that when typed cancel the auto-completion list.

◆ BackTab()

void wxStyledTextCtrl::BackTab ( )

Dedent the selected lines.

◆ BeginUndoAction()

void wxStyledTextCtrl::BeginUndoAction ( )

Start a sequence of actions that is undone and redone as a unit.

May be nested.

◆ BraceBadLight()

void wxStyledTextCtrl::BraceBadLight ( int  pos)

Highlight the character at a position indicating there is no matching brace.

◆ BraceBadLightIndicator()

void wxStyledTextCtrl::BraceBadLightIndicator ( bool  useSetting,
int  indicator 
)

Use specified indicator to highlight non matching brace instead of changing its style.

◆ BraceHighlight()

void wxStyledTextCtrl::BraceHighlight ( int  posA,
int  posB 
)

Highlight the characters at two positions.

◆ BraceHighlightIndicator()

void wxStyledTextCtrl::BraceHighlightIndicator ( bool  useSetting,
int  indicator 
)

Use specified indicator to highlight matching braces instead of changing their style.

◆ BraceMatch()

int wxStyledTextCtrl::BraceMatch ( int  pos,
int  maxReStyle = 0 
)

Find the position of a matching brace or wxSTC_INVALID_POSITION if no match.

The maxReStyle must be 0 for now. It may be defined in a future release.

◆ BraceMatchNext()

int wxStyledTextCtrl::BraceMatchNext ( int  pos,
int  startPos 
)

Similar to BraceMatch, but matching starts at the explicit start position.

◆ CallTipActive()

bool wxStyledTextCtrl::CallTipActive ( )

Is there an active call tip?

◆ CallTipCancel()

void wxStyledTextCtrl::CallTipCancel ( )

Remove the call tip from the screen.

◆ CallTipPosAtStart()

int wxStyledTextCtrl::CallTipPosAtStart ( )

Retrieve the position where the caret was before displaying the call tip.

Since
3.1.0

◆ CallTipSetBackground()

void wxStyledTextCtrl::CallTipSetBackground ( const wxColour back)

Set the background colour for the call tip.

◆ CallTipSetForeground()

void wxStyledTextCtrl::CallTipSetForeground ( const wxColour fore)

Set the foreground colour for the call tip.

◆ CallTipSetForegroundHighlight()

void wxStyledTextCtrl::CallTipSetForegroundHighlight ( const wxColour fore)

Set the foreground colour for the highlighted part of the call tip.

◆ CallTipSetHighlight()

void wxStyledTextCtrl::CallTipSetHighlight ( int  highlightStart,
int  highlightEnd 
)

Highlight a segment of the definition.

◆ CallTipSetPosAtStart()

void wxStyledTextCtrl::CallTipSetPosAtStart ( int  posStart)

Set the start position in order to change when backspacing removes the calltip.

◆ CallTipSetPosition()

void wxStyledTextCtrl::CallTipSetPosition ( bool  above)

Set position of calltip, above or below text.

◆ CallTipShow()

void wxStyledTextCtrl::CallTipShow ( int  pos,
const wxString definition 
)

Show a call tip containing a definition near position pos.

◆ CallTipUseStyle()

void wxStyledTextCtrl::CallTipUseStyle ( int  tabSize)

Enable use of wxSTC_STYLE_CALLTIP and set call tip tab size in pixels.

◆ Cancel()

void wxStyledTextCtrl::Cancel ( )

Cancel any modes such as call tip or auto-completion list display.

◆ CanPaste()

bool wxStyledTextCtrl::CanPaste ( ) const
virtual

Will a paste succeed?

Reimplemented from wxTextEntry.

◆ CanRedo()

bool wxStyledTextCtrl::CanRedo ( ) const
virtual

Are there any redoable actions in the undo history?

Reimplemented from wxTextEntry.

◆ CanUndo()

bool wxStyledTextCtrl::CanUndo ( ) const
virtual

Are there any undoable actions in the undo history?

Reimplemented from wxTextEntry.

◆ ChangeInsertion()

void wxStyledTextCtrl::ChangeInsertion ( int  length,
const wxString text 
)

Change the text that is being inserted in response to wxSTC_MOD_INSERTCHECK.

Since
3.1.0

◆ ChangeLexerState()

int wxStyledTextCtrl::ChangeLexerState ( int  start,
int  end 
)

Indicate that the internal state of a lexer has changed over a range and therefore there may be a need to redraw.

◆ CharLeft()

void wxStyledTextCtrl::CharLeft ( )

Move caret left one character.

◆ CharLeftExtend()

void wxStyledTextCtrl::CharLeftExtend ( )

Move caret left one character extending selection to new caret position.

◆ CharLeftRectExtend()

void wxStyledTextCtrl::CharLeftRectExtend ( )

Move caret left one character, extending rectangular selection to new caret position.

◆ CharPositionFromPoint()

int wxStyledTextCtrl::CharPositionFromPoint ( int  x,
int  y 
)

Find the position of a character from a point within the window.

◆ CharPositionFromPointClose()

int wxStyledTextCtrl::CharPositionFromPointClose ( int  x,
int  y 
)

Find the position of a character from a point within the window.

Return wxSTC_INVALID_POSITION if not close to text.

◆ CharRight()

void wxStyledTextCtrl::CharRight ( )

Move caret right one character.

◆ CharRightExtend()

void wxStyledTextCtrl::CharRightExtend ( )

Move caret right one character extending selection to new caret position.

◆ CharRightRectExtend()

void wxStyledTextCtrl::CharRightRectExtend ( )

Move caret right one character, extending rectangular selection to new caret position.

◆ ChooseCaretX()

void wxStyledTextCtrl::ChooseCaretX ( )

Set the last x chosen value to be the caret x position.

◆ Clear()

void wxStyledTextCtrl::Clear ( )
virtual

Clear the selection.

Reimplemented from wxTextEntry.

◆ ClearAll()

void wxStyledTextCtrl::ClearAll ( )

Delete all text in the document.

◆ ClearDocumentStyle()

void wxStyledTextCtrl::ClearDocumentStyle ( )

Set all style bytes to 0, remove all folding information.

◆ ClearRegisteredImages()

void wxStyledTextCtrl::ClearRegisteredImages ( )

Clear all the registered images.

◆ ClearRepresentation()

void wxStyledTextCtrl::ClearRepresentation ( const wxString encodedCharacter)

Remove a character representation.

Since
3.1.0

◆ ClearSelections()

void wxStyledTextCtrl::ClearSelections ( )

Clear selections to a single empty stream selection.

◆ ClearTabStops()

void wxStyledTextCtrl::ClearTabStops ( int  line)

Clear explicit tabstops on a line.

Since
3.1.0

◆ CmdKeyAssign()

void wxStyledTextCtrl::CmdKeyAssign ( int  key,
int  modifiers,
int  cmd 
)

When key+modifier combination keyDefinition is pressed perform sciCommand.

The second argument should be a bit list containing one or more of the wxSTC_KEYMOD_* constants and the third argument should be one of the wxSTC_CMD_* constants.

◆ CmdKeyClear()

void wxStyledTextCtrl::CmdKeyClear ( int  key,
int  modifiers 
)

When key+modifier combination keyDefinition is pressed do nothing.

The second argument should be a bit list containing one or more of the wxSTC_KEYMOD_* constants.

◆ CmdKeyClearAll()

void wxStyledTextCtrl::CmdKeyClearAll ( )

Drop all key mappings.

◆ CmdKeyExecute()

void wxStyledTextCtrl::CmdKeyExecute ( int  cmd)

Perform one of the operations defined by the wxSTC_CMD_* constants.

◆ Colourise()

void wxStyledTextCtrl::Colourise ( int  start,
int  end 
)

Colourise a segment of the document using the current lexing language.

◆ ContractedFoldNext()

int wxStyledTextCtrl::ContractedFoldNext ( int  lineStart)

Find the next line at or after lineStart that is a contracted fold header line.

Return -1 when no more lines.

◆ ConvertEOLs()

void wxStyledTextCtrl::ConvertEOLs ( int  eolMode)

Convert all line endings in the document to one mode.

◆ Copy()

void wxStyledTextCtrl::Copy ( )
virtual

Copy the selection to the clipboard.

Reimplemented from wxTextEntry.

◆ CopyAllowLine()

void wxStyledTextCtrl::CopyAllowLine ( )

Copy the selection, if selection empty copy the line with the caret.

◆ CopyRange()

void wxStyledTextCtrl::CopyRange ( int  start,
int  end 
)

Copy a range of text to the clipboard.

Positions are clipped into the document.

◆ CopyText()

void wxStyledTextCtrl::CopyText ( int  length,
const wxString text 
)

Copy argument text to the clipboard.

◆ CountCharacters()

int wxStyledTextCtrl::CountCharacters ( int  start,
int  end 
)

Count characters between two positions.

◆ CountCodeUnits()

int wxStyledTextCtrl::CountCodeUnits ( int  start,
int  end 
)

Count code units between two positions.

◆ Create()

bool wxStyledTextCtrl::Create ( wxWindow parent,
wxWindowID  id = wxID_ANY,
const wxPoint pos = wxDefaultPosition,
const wxSize size = wxDefaultSize,
long  style = 0,
const wxString name = wxSTCNameStr 
)

Create the UI elements for a STC that was created with the default ctor.

(For 2-phase create.)

◆ CreateDocument()

void* wxStyledTextCtrl::CreateDocument ( )

Create a new document object.

Starts with reference count of 1 and not selected into editor.

◆ CreateLoader()

void* wxStyledTextCtrl::CreateLoader ( int  bytes) const

Create an ILoader*.

◆ Cut()

void wxStyledTextCtrl::Cut ( )
virtual

Cut the selection to the clipboard.

Reimplemented from wxTextEntry.

◆ DeleteBack()

void wxStyledTextCtrl::DeleteBack ( )

Delete the selection or if no selection, the character before the caret.

◆ DeleteBackNotLine()

void wxStyledTextCtrl::DeleteBackNotLine ( )

Delete the selection or if no selection, the character before the caret.

Will not delete the character before at the start of a line.

◆ DeleteRange()

void wxStyledTextCtrl::DeleteRange ( int  start,
int  lengthDelete 
)

Delete a range of text in the document.

◆ DelLineLeft()

void wxStyledTextCtrl::DelLineLeft ( )

Delete back from the current position to the start of the line.

◆ DelLineRight()

void wxStyledTextCtrl::DelLineRight ( )

Delete forwards from the current position to the end of the line.

◆ DelWordLeft()

void wxStyledTextCtrl::DelWordLeft ( )

Delete the word to the left of the caret.

◆ DelWordRight()

void wxStyledTextCtrl::DelWordRight ( )

Delete the word to the right of the caret.

◆ DelWordRightEnd()

void wxStyledTextCtrl::DelWordRightEnd ( )

Delete the word to the right of the caret, but not the trailing non-word characters.

◆ DescribeKeyWordSets()

wxString wxStyledTextCtrl::DescribeKeyWordSets ( ) const

Retrieve a '\n' separated list of descriptions of the keyword sets understood by the current lexer.

◆ DescribeProperty()

wxString wxStyledTextCtrl::DescribeProperty ( const wxString name) const

Describe a property.

◆ DescriptionOfStyle()

wxString wxStyledTextCtrl::DescriptionOfStyle ( int  style) const

Retrieve a description of a style.

Result is NUL-terminated.

◆ DiscardEdits()

virtual void wxStyledTextCtrl::DiscardEdits ( )
virtual

Resets the internal modified flag as if the current changes had been saved.

◆ DistanceToSecondaryStyles()

int wxStyledTextCtrl::DistanceToSecondaryStyles ( ) const

Where styles are duplicated by a feature such as active/inactive code return the distance between the two types.

Since
3.1.0

◆ DocLineFromVisible()

int wxStyledTextCtrl::DocLineFromVisible ( int  displayLine)

Find the document line of a display line taking hidden lines into account.

◆ DocumentEnd()

void wxStyledTextCtrl::DocumentEnd ( )

Move caret to last position in document.

◆ DocumentEndExtend()

void wxStyledTextCtrl::DocumentEndExtend ( )

Move caret to last position in document extending selection to new caret position.

◆ DocumentStart()

void wxStyledTextCtrl::DocumentStart ( )

Move caret to first position in document.

◆ DocumentStartExtend()

void wxStyledTextCtrl::DocumentStartExtend ( )

Move caret to first position in document extending selection to new caret position.

◆ DoDragEnter()

wxDragResult wxStyledTextCtrl::DoDragEnter ( wxCoord  x,
wxCoord  y,
wxDragResult  defaultRes 
)

Allow for simulating a DnD DragEnter.

Since
3.1.0

◆ DoDragLeave()

void wxStyledTextCtrl::DoDragLeave ( )

Allow for simulating a DnD DragLeave.

Since
3.1.0

◆ DoDragOver()

wxDragResult wxStyledTextCtrl::DoDragOver ( wxCoord  x,
wxCoord  y,
wxDragResult  defaultRes 
)

Allow for simulating a DnD DragOver.

◆ DoDropText()

bool wxStyledTextCtrl::DoDropText ( long  x,
long  y,
const wxString data 
)

Allow for simulating a DnD DropText.

◆ DropSelectionN()

void wxStyledTextCtrl::DropSelectionN ( int  selection)

Drop one selection.

Since
3.1.0

◆ EditToggleOvertype()

void wxStyledTextCtrl::EditToggleOvertype ( )

Switch from insert to overtype mode or the reverse.

◆ EmptyUndoBuffer()

void wxStyledTextCtrl::EmptyUndoBuffer ( )

Delete the undo history.

◆ EndUndoAction()

void wxStyledTextCtrl::EndUndoAction ( )

End a sequence of actions that is undone and redone as a unit.

◆ EnsureCaretVisible()

void wxStyledTextCtrl::EnsureCaretVisible ( )

Ensure the caret is visible.

◆ EnsureVisible()

void wxStyledTextCtrl::EnsureVisible ( int  line)

Ensure a particular line is visible by expanding any header line hiding it.

◆ EnsureVisibleEnforcePolicy()

void wxStyledTextCtrl::EnsureVisibleEnforcePolicy ( int  line)

Ensure a particular line is visible by expanding any header line hiding it.

Use the currently set visibility policy to determine which range to display.

◆ EOLAnnotationClearAll()

void wxStyledTextCtrl::EOLAnnotationClearAll ( )

Clear the end of annotations from all lines.

◆ EOLAnnotationGetStyle()

int wxStyledTextCtrl::EOLAnnotationGetStyle ( int  line) const

Get the style number for the end of line annotations for a line.

◆ EOLAnnotationGetStyleOffset()

int wxStyledTextCtrl::EOLAnnotationGetStyleOffset ( ) const

Get the start of the range of style numbers used for end of line annotations.

◆ EOLAnnotationGetText()

wxString wxStyledTextCtrl::EOLAnnotationGetText ( int  line) const

Get the end of line annotation text for a line.

◆ EOLAnnotationGetVisible()

int wxStyledTextCtrl::EOLAnnotationGetVisible ( ) const

Get the visibility for the end of line annotations for a view.

◆ EOLAnnotationSetStyle()

void wxStyledTextCtrl::EOLAnnotationSetStyle ( int  line,
int  style 
)

Set the style number for the end of line annotations for a line.

◆ EOLAnnotationSetStyleOffset()

void wxStyledTextCtrl::EOLAnnotationSetStyleOffset ( int  style)

Get the start of the range of style numbers used for end of line annotations.

◆ EOLAnnotationSetText()

void wxStyledTextCtrl::EOLAnnotationSetText ( int  line,
const wxString text 
)

Set the end of line annotation text for a line.

◆ EOLAnnotationSetVisible()

void wxStyledTextCtrl::EOLAnnotationSetVisible ( int  visible)

Set the visibility for the end of line annotations for a view.

◆ ExpandChildren()

void wxStyledTextCtrl::ExpandChildren ( int  line,
int  level 
)

Expand a fold header and all children.

Use the level argument instead of the line's current level.

Since
3.1.0

◆ FindColumn()

int wxStyledTextCtrl::FindColumn ( int  line,
int  column 
)

Find the position of a column on a line taking into account tabs and multi-byte characters.

If beyond end of line, return line end position.

◆ FindText()

int wxStyledTextCtrl::FindText ( int  minPos,
int  maxPos,
const wxString text,
int  flags = 0,
int *  findEnd = nullptr 
)

Find some text in the document.

Parameters
minPosThe position (starting from zero) in the document at which to begin the search
maxPosThe last position (starting from zero) in the document to which the search will be restricted.
textThe text to search for.
flags(Optional) The search flags. This should be a bit list containing one or more of the wxSTC_FIND_* constants.
findEnd(Optional) This parameter can optionally be used to receive the end position (starting from zero) of the found text. This is primarily needed when searching using regular expressions. This parameter is available since wxWidgets 3.1.1.
Returns
The position (starting from zero) in the document at which the text was found or wxSTC_INVALID_POSITION if the search fails.
Remarks
A backwards search can be performed by setting minPos to be greater than maxPos.

◆ FoldAll()

void wxStyledTextCtrl::FoldAll ( int  action)

Expand or contract all fold headers.

The input should be one of the wxSTC_FOLDACTION_* constants.

Since
3.1.0

◆ FoldChildren()

void wxStyledTextCtrl::FoldChildren ( int  line,
int  action 
)

Expand or contract a fold header and its children.

The second argument should be one of the wxSTC_FOLDACTION_* constants.

Since
3.1.0

◆ FoldDisplayTextGetStyle()

int