wxStyledTextCtrl(3)
๐ wxStyledTextCtrl(3) ๐
okay so bestie, gather round, because this is the wxStyledTextCtrl page from the Erlang module definitions in the manual, and it's a whole journey. buckle up. ๐
โจ NAME โจ
wxStyledTextCtrl โ a wxWidgets implementation of the Scintilla source code editing component. she's an editor widget, she's iconic, she's the vibe. ๐
๐ธ DESCRIPTION ๐ธ
So like, on top of all the stuff you'd expect from a normal text editing component, Scintilla comes with features that are lowkey made for editing and debugging source code. we're talking support for syntax styling, error indicators, code completion and call tips. ๐
The selection margin can hold markers, like the ones debuggers use to show breakpoints and the current line. and the styling choices are wayyy more open than what a lot of editors give you โ proportional fonts? bold and italics? multiple foreground and background colours? multiple fonts? all of it. slay. ๐
wxStyledTextCtrl is a 1 to 1 mapping of the "raw" scintilla interface, and you can find that documentation over on the Scintilla website: http://www.scintilla.org/.
btw, for the documentation of all the event types you can use with wxStyledTextCtrl, go look at wxStyledTextEvent. that's where that lives. ๐ซถ
This class is derived, and can use functions, from:
wxControlwxWindowwxEvtHandler
wxWidgets docs: wxStyledTextCtrl
๐ฆ DATA TYPES ๐ฆ
wxStyledTextCtrl() :: wx:wx_object().
โญ FUNCTIONS โญ
๐ addText
addText(This, Text) -> ok
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
Add text to the document at the current position. that's it, that's the whole thing. โจ
๐ addTextRaw
addTextRaw(This, Text, [Option]) -> ok
when
This :: wxStyledTextCtrl(),
Text :: binary(),
Option :: {length, integer()}.
Add text to the document at the current position. (the raw one โ she takes a binary() and has that {length, integer()} option riding along. ๐)
๐ allocate
allocate(This, Bytes) -> ok
when This :: wxStyledTextCtrl(), Bytes :: integer().
Enlarge the document to a particular size of text bytes. giving her room to grow. ๐
๐ appendText
appendText(This, Text) -> ok
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
Append a string to the end of the document without changing the selection. the selection stays exactly where it was, no cap. ๐ฏ
๐ appendTextRaw
appendTextRaw(This, Text, [Option]) -> ok
when
This :: wxStyledTextCtrl(),
Text :: binary(),
Option :: {length, integer()}.
Append a string to the end of the document without changing the selection. raw flavour, binary() in, {length, integer()} optional. ๐
๐ autoCompActive
autoCompActive(This) -> boolean()
when This :: wxStyledTextCtrl().
Is there an auto-completion list visible? yes or no bestie, boolean(). ๐
๐ autoCompCancel
autoCompCancel(This) -> ok
when This :: wxStyledTextCtrl().
Remove the auto-completion list from the screen. bye bye. ๐ซก
๐ autoCompComplete
autoCompComplete(This) -> ok
when This :: wxStyledTextCtrl().
The user has selected an item, so: remove the list and insert the selection. done deal. ๐
๐ autoCompGetAutoHide
autoCompGetAutoHide(This) -> boolean()
when This :: wxStyledTextCtrl().
Retrieve whether or not autocompletion is hidden automatically when nothing matches.
๐ autoCompGetCancelAtStart
autoCompGetCancelAtStart(This) -> boolean()
when This :: wxStyledTextCtrl().
Retrieve whether auto-completion gets cancelled by backspacing before the start.
๐ autoCompGetChooseSingle
autoCompGetChooseSingle(This) -> boolean()
when This :: wxStyledTextCtrl().
Retrieve whether a single item auto-completion list automatically chooses the item.
๐ autoCompGetCurrent
autoCompGetCurrent(This) -> integer()
when This :: wxStyledTextCtrl().
Get the currently selected item position in the auto-completion list. it's an integer(). ๐ข
๐ autoCompGetDropRestOfWord
autoCompGetDropRestOfWord(This) -> boolean()
when This :: wxStyledTextCtrl().
Retrieve whether or not autocompletion deletes any word characters after the inserted text upon completion.
๐ autoCompGetIgnoreCase
autoCompGetIgnoreCase(This) -> boolean()
when This :: wxStyledTextCtrl().
Retrieve the state of the ignore case flag.
๐ autoCompGetMaxHeight
autoCompGetMaxHeight(This) -> integer()
when This :: wxStyledTextCtrl().
Set the maximum height, in rows, of auto-completion and user lists. (yes it says "Set" on the getter, that's just how she is, iykyk โ either way, integer() comes back. ๐ญ)
๐ autoCompGetMaxWidth
autoCompGetMaxWidth(This) -> integer()
when This :: wxStyledTextCtrl().
Get the maximum width, in characters, of auto-completion and user lists.
๐ autoCompGetSeparator
autoCompGetSeparator(This) -> integer()
when This :: wxStyledTextCtrl().
Retrieve the auto-completion list separator character. ๐ค
๐ autoCompGetTypeSeparator
autoCompGetTypeSeparator(This) -> integer()
when This :: wxStyledTextCtrl().
Retrieve the auto-completion list type-separator character. โจ
๐ autoCompPosStart
autoCompPosStart(This) -> integer()
when This :: wxStyledTextCtrl().
Retrieve the position of the caret when the auto-completion list was displayed. ๐
๐ autoCompSelect
autoCompSelect(This, Select) -> ok
when
This :: wxStyledTextCtrl(),
Select :: unicode:chardata().
Select the item in the auto-completion list that starts with a string. yes, starts with, that's the rule. ๐ฏ
๐ autoCompSetAutoHide
autoCompSetAutoHide(This, AutoHide) -> ok
when
This :: wxStyledTextCtrl(),
AutoHide :: boolean().
Set whether or not autocompletion is hidden automatically when nothing matches.
๐ autoCompSetCancelAtStart
autoCompSetCancelAtStart(This, Cancel) -> ok
when
This :: wxStyledTextCtrl(),
Cancel :: boolean().
Should the auto-completion list be cancelled if the user backspaces to a position before where the box was created?
๐ autoCompSetChooseSingle
autoCompSetChooseSingle(This, ChooseSingle) -> ok
when
This :: wxStyledTextCtrl(),
ChooseSingle :: boolean().
Should a single item auto-completion list automatically choose the item.
๐ autoCompSetDropRestOfWord
autoCompSetDropRestOfWord(This, DropRestOfWord) -> ok
when
This :: wxStyledTextCtrl(),
DropRestOfWord :: boolean().
Set whether or not autocompletion deletes any word characters after the inserted text upon completion.
๐ autoCompSetFillUps
autoCompSetFillUps(This, CharacterSet) -> ok
when
This :: wxStyledTextCtrl(),
CharacterSet :: unicode:chardata().
Define a set of characters that, when typed, will cause the autocompletion to choose the selected item. ๐ง
๐ autoCompSetIgnoreCase
autoCompSetIgnoreCase(This, IgnoreCase) -> ok
when
This :: wxStyledTextCtrl(),
IgnoreCase :: boolean().
Set whether case is significant when performing auto-completion searches.
๐ autoCompSetMaxHeight
autoCompSetMaxHeight(This, RowCount) -> ok
when
This :: wxStyledTextCtrl(),
RowCount :: integer().
Set the maximum height, in rows, of auto-completion and user lists.
The default is 5 rows. ๐๏ธ
๐ autoCompSetMaxWidth
autoCompSetMaxWidth(This, CharacterCount) -> ok
when
This :: wxStyledTextCtrl(),
CharacterCount :: integer().
Set the maximum width, in characters, of auto-completion and user lists.
Set to 0 to autosize to fit the longest item, which is the default. ๐
๐ autoCompSetSeparator
autoCompSetSeparator(This, SeparatorCharacter) -> ok
when
This :: wxStyledTextCtrl(),
SeparatorCharacter :: integer().
Change the separator character in the string setting up an auto-completion list.
Default is space, but it can be changed if items contain space. ๐ซถ
๐ autoCompSetTypeSeparator
autoCompSetTypeSeparator(This, SeparatorCharacter) -> ok
when
This :: wxStyledTextCtrl(),
SeparatorCharacter :: integer().
Change the type-separator character in the string setting up an auto-completion list.
Default is'?', but it can be changed if items contain'?'. โ
๐ autoCompShow
autoCompShow(This, LengthEntered, ItemList) -> ok
when
This :: wxStyledTextCtrl(),
LengthEntered :: integer(),
ItemList :: unicode:chardata().
Display an auto-completion list. โจ
The lengthEntered parameter indicates how many characters before the caret should be used to provide context.
๐ autoCompStops
autoCompStops(This, CharacterSet) -> ok
when
This :: wxStyledTextCtrl(),
CharacterSet :: unicode:chardata().
Define a set of characters that, when typed, cancel the auto-completion list. ๐
๐ backTab
backTab(This) -> ok
when This :: wxStyledTextCtrl().
Dedent the selected lines. un-indent, bestie, we're going back. โฌ ๏ธ
๐ beginUndoAction
beginUndoAction(This) -> ok
when This :: wxStyledTextCtrl().
Start a sequence of actions that gets undone and redone as a single unit.
May be nested. ๐ช
๐ braceBadLight
braceBadLight(This, Pos) -> ok
when This :: wxStyledTextCtrl(), Pos :: integer().
Highlight the character at a position, indicating there is no matching brace. ๐ญ that lonely unmatched brace.
๐ braceHighlight
braceHighlight(This, PosA, PosB) -> ok
when
This :: wxStyledTextCtrl(),
PosA :: integer(),
PosB :: integer().
Highlight the characters at two positions. the matched brace duo, both of them, glowing. ๐ฅ
๐ braceMatch
braceMatch(This, Pos) -> integer()
when This :: wxStyledTextCtrl(), Pos :: integer().
Find the position of a matching brace, or wxSTC_INVALID_POSITION if there's no match. ๐
๐ callTipActive
callTipActive(This) -> boolean()
when This :: wxStyledTextCtrl().
Is there an active call tip? boolean(), tell me everything. ๐
๐ callTipCancel
callTipCancel(This) -> ok
when This :: wxStyledTextCtrl().
Remove the call tip from the screen. poof. ๐จ
๐ callTipPosAtStart
callTipPosAtStart(This) -> integer()
when This :: wxStyledTextCtrl().
Retrieve the position where the caret was before displaying the call tip. ๐
Since: 3.1.0 โจ
callTipSetBackground
callTipSetBackground(This, Back) -> ok
when
This :: wxStyledTextCtrl(),
Back :: wx:wx_colour().
ok bestie, this sets the background colour for the call tip. ๐
callTipSetForeground
callTipSetForeground(This, Fore) -> ok
when
This :: wxStyledTextCtrl(),
Fore :: wx:wx_colour().
sets the foreground colour for the call tip. โจ
callTipSetForegroundHighlight
callTipSetForegroundHighlight(This, Fore) -> ok
when
This :: wxStyledTextCtrl(),
Fore :: wx:wx_colour().
sets the foreground colour for the highlighted part of the call tip. ๐
callTipSetHighlight
callTipSetHighlight(This, HighlightStart, HighlightEnd) -> ok
when
This :: wxStyledTextCtrl(),
HighlightStart :: integer(),
HighlightEnd :: integer().
highlight a segment of the definition. iconic for making call tips pop. ๐
callTipShow
callTipShow(This, Pos, Definition) -> ok
when
This :: wxStyledTextCtrl(),
Pos :: integer(),
Definition :: unicode:chardata().
show a call tip containing a definition near position pos. ๐ฅ
callTipUseStyle
callTipUseStyle(This, TabSize) -> ok
when
This :: wxStyledTextCtrl(),
TabSize :: integer().
enable use of wxSTC_STYLE_CALLTIP and set call tip tab size in pixels. ๐ฆ
canPaste
canPaste(This) -> boolean() when This :: wxStyledTextCtrl().
will a paste succeed? boolean vibes only. ๐ญ
canRedo
canRedo(This) -> boolean() when This :: wxStyledTextCtrl().
are there any redoable actions in the undo history? check it. ๐
canUndo
canUndo(This) -> boolean() when This :: wxStyledTextCtrl().
are there any undoable actions in the undo history? bestie check. โฉ๏ธ
cancel
cancel(This) -> ok when This :: wxStyledTextCtrl().
cancel any modes such as call tip or auto-completion list display. bye bye popups. ๐
charLeft
charLeft(This) -> ok when This :: wxStyledTextCtrl().
move caret left one character. scoot. โฌ ๏ธ
charLeftExtend
charLeftExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret left one character extending selection to new caret position. selection glow up. โจ
charLeftRectExtend
charLeftRectExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret left one character, extending rectangular selection to new caret position. ๐ช
charRight
charRight(This) -> ok when This :: wxStyledTextCtrl().
move caret right one character. scoot but right. โก๏ธ
charRightExtend
charRightExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret right one character extending selection to new caret position. selection moment. ๐
charRightRectExtend
charRightRectExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret right one character, extending rectangular selection to new caret position. ๐ช
chooseCaretX
chooseCaretX(This) -> ok when This :: wxStyledTextCtrl().
set the last x chosen value to be the caret x position. x marks the spot. ๐
clear
clear(This) -> ok when This :: wxStyledTextCtrl().
clear the selection. poof. ๐จ
clearAll
clearAll(This) -> ok when This :: wxStyledTextCtrl().
delete all text in the document. nuclear option bestie. ๐
clearDocumentStyle
clearDocumentStyle(This) -> ok when This :: wxStyledTextCtrl().
set all style bytes to 0, remove all folding information. reset the drip. ๐งน
clearRegisteredImages
clearRegisteredImages(This) -> ok when This :: wxStyledTextCtrl().
clear all the registered images. image purge. ๐ผ๏ธ
cmdKeyAssign
cmdKeyAssign(This, Key, Modifiers, Cmd) -> ok
when
This :: wxStyledTextCtrl(),
Key :: integer(),
Modifiers :: integer(),
Cmd :: integer().
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. keyboard shortcuts go brrr. โจ๏ธ
cmdKeyClear
cmdKeyClear(This, Key, Modifiers) -> ok
when
This :: wxStyledTextCtrl(),
Key :: integer(),
Modifiers :: integer().
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. unassign that key. ๐ซ
cmdKeyClearAll
cmdKeyClearAll(This) -> ok when This :: wxStyledTextCtrl().
drop all key mappings. clean slate. ๐งผ
cmdKeyExecute
cmdKeyExecute(This, Cmd) -> ok
when This :: wxStyledTextCtrl(), Cmd ::
integer().
perform one of the operations defined by the wxSTC_CMD_* constants. do the thing. โก
colourise
colourise(This, Start, End) -> ok
when
This :: wxStyledTextCtrl(),
Start :: integer(),
End :: integer().
colourise a segment of the document using the current lexing language. aesthetic. ๐
convertEOLs
convertEOLs(This, EolMode) -> ok
when
This :: wxStyledTextCtrl(),
EolMode :: integer().
convert all line endings in the document to one mode. unify those EOLs. ๐ซถ
copy
copy(This) -> ok when This :: wxStyledTextCtrl().
copy the selection to the clipboard. clipboard said slay. ๐
copyRange
copyRange(This, Start, End) -> ok
when
This :: wxStyledTextCtrl(),
Start :: integer(),
End :: integer().
copy a range of text to the clipboard.
positions are clipped into the document. boundaries handled. โ๏ธ
copyText
copyText(This, Length, Text) -> ok
when
This :: wxStyledTextCtrl(),
Length :: integer(),
Text :: unicode:chardata().
copy argument text to the clipboard. direct clipboard drop. ๐
create
create(This, Parent, [Option]) -> boolean()
when
This :: wxStyledTextCtrl(),
Parent :: wxWindow:wxWindow(),
Option ::
{id, integer()} |
{pos, {X :: integer(), Y :: integer()}} |
{size, {W :: integer(), H :: integer()}} |
{style, integer()}.
create the UI elements for a STC that was created with the default ctor.
(for 2-phase create.) phase 2 unlocked. ๐ ๏ธ
cut
cut(This) -> ok when This :: wxStyledTextCtrl().
cut the selection to the clipboard. snip snip. โ๏ธ
delLineLeft
delLineLeft(This) -> ok when This :: wxStyledTextCtrl().
delete back from the current position to the start of the line. left delete energy. โฌ ๏ธ
delLineRight
delLineRight(This) -> ok when This :: wxStyledTextCtrl().
delete forwards from the current position to the end of the line. right delete energy. โก๏ธ
delWordLeft
delWordLeft(This) -> ok when This :: wxStyledTextCtrl().
delete the word to the left of the caret. word gone left. ๐๏ธ
delWordRight
delWordRight(This) -> ok when This :: wxStyledTextCtrl().
delete the word to the right of the caret. word gone right. ๐๏ธ
deleteBack
deleteBack(This) -> ok when This :: wxStyledTextCtrl().
delete the selection or if no selection, the character before the caret. backspace behavior. โซ
deleteBackNotLine
deleteBackNotLine(This) -> ok when This :: wxStyledTextCtrl().
delete the selection or if no selection, the character before the caret.
will not delete the character before at the start of a line. boundary respected. ๐ง
destroy
destroy(This :: wxStyledTextCtrl()) -> ok.
destroys the object. bye bye. ๐
doDragOver
doDragOver(This, X, Y, DefaultRes) -> wx:wx_enum()
when
This :: wxStyledTextCtrl(),
X :: integer(),
Y :: integer(),
DefaultRes :: wx:wx_enum().
allow for simulating a DnD DragOver. fake drag go. ๐ฑ๏ธ
doDropText
doDropText(This, X, Y, Data) -> boolean()
when
This :: wxStyledTextCtrl(),
X :: integer(),
Y :: integer(),
Data :: unicode:chardata().
allow for simulating a DnD DropText. fake drop go. ๐ฅ
docLineFromVisible
docLineFromVisible(This, DisplayLine) -> integer()
when
This :: wxStyledTextCtrl(),
DisplayLine :: integer().
find the document line of a display line taking hidden lines into account. hidden line math. ๐งฎ
documentEnd
documentEnd(This) -> ok when This :: wxStyledTextCtrl().
move caret to last position in document. to the end. ๐
documentEndExtend
documentEndExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret to last position in document extending selection to new caret position. select to the end. ๐
documentStart
documentStart(This) -> ok when This :: wxStyledTextCtrl().
move caret to first position in document. to the start. ๐
documentStartExtend
documentStartExtend(This) -> ok when This :: wxStyledTextCtrl().
move caret to first position in document extending selection to new caret position. select to the start. ๐
editToggleOvertype
editToggleOvertype(This) -> ok when This :: wxStyledTextCtrl().
switch from insert to overtype mode or the reverse. mode flip. ๐
emptyUndoBuffer
emptyUndoBuffer(This) -> ok when This :: wxStyledTextCtrl().
delete the undo history. no takebacks. ๐๏ธ
endUndoAction
endUndoAction(This) -> ok when This :: wxStyledTextCtrl().
end a sequence of actions that is undone and redone as a unit. undo group closed. ๐
ensureCaretVisible
ensureCaretVisible(This) -> ok when This :: wxStyledTextCtrl().
ensure the caret is visible. come into view bestie. ๐
ensureVisible
ensureVisible(This, Line) -> ok
when
This :: wxStyledTextCtrl(), Line ::
integer().
ensure a particular line is visible by expanding any header line hiding it. reveal that line. ๐
ensureVisibleEnforcePolicy
ensureVisibleEnforcePolicy(This, Line) -> ok
when
This :: wxStyledTextCtrl(),
Line :: integer().
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. policy checked. ๐
findColumn
findColumn(This, Line, Column) -> integer()
when
This :: wxStyledTextCtrl(),
Line :: integer(),
Column :: integer().
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. column found. ๐งญ
findText(This, MinPos, MaxPos, Text, [Option]) -> integer()โ the search function, and she EATS ๐
when
This :: wxStyledTextCtrl(),
MinPos :: integer(),
MaxPos :: integer(),
Text :: unicode:chardata(),
Option :: {flags, integer()}.
Finds some text in the document, no cap ๐ MinPos is the position (starting from zero) in the document where the search begins. MaxPos is the last position (also starting from zero) in the document that the search is restricted to. Text is the text you're searching for. Option is optional and holds {flags, integer()} โ the search flags, which should be a bit list containing one or more of the wxSTC_FIND_WHOLEWORD / wxSTC_FIND_* constants.
It returns the position (starting from zero, bestie, always zero) in the document where the text was found, or wxSTC_INVALID_POSITION if the search fails ๐ญ.
Remark that is lowkey iconic: you can do a backwards search by settingMinPosto be greater thanMaxPos. periodt. ๐ฆ
formFeed(This) -> ok when This :: wxStyledTextCtrl().โ inserts a Form Feed character. that's it, that's the whole job ๐ธformatRange(This, DoDraw, StartPos, EndPos, Draw, Target, RenderRect, PageRect) -> integer()โ the printer girlie ๐จ๏ธ
when
This :: wxStyledTextCtrl(),
DoDraw :: boolean(),
StartPos :: integer(),
EndPos :: integer(),
Draw :: wxDC:wxDC(),
Target :: wxDC:wxDC(),
RenderRect ::
{X :: integer(),
Y :: integer(),
W :: integer(),
H :: integer()},
PageRect ::
{X :: integer(),
Y :: integer(),
W :: integer(),
H :: integer()}.
On Windows, this will draw the document into a display context such as a printer. only on Windows, so don't come for me if it's giving nothing elsewhere ๐
getAnchor(This) -> integer() when This :: wxStyledTextCtrl().โ returns the position of the opposite end of the selection to the caret. the other end of the vibe check ๐getBackSpaceUnIndents(This) -> boolean() when This :: wxStyledTextCtrl().โ does a backspace pressed when the caret is within indentation unindent? yes/no bestie โจ๏ธgetBufferedDraw(This) -> boolean() when This :: wxStyledTextCtrl().โ is drawing done first into a buffer, or straight to the screen? ๐getCaretForeground(This) -> wx:wx_colour4() when This :: wxStyledTextCtrl().โ get the foreground colour of the caret โจgetCaretLineBackAlpha(This) -> integer() when This :: wxStyledTextCtrl().โ get the background alpha of the caret line ๐getCaretLineBackground(This) -> wx:wx_colour4() when This :: wxStyledTextCtrl().โ get the colour of the background of the line containing the caret ๐จgetCaretLineVisible(This) -> boolean() when This :: wxStyledTextCtrl().โ is the background of the line containing the caret in a different colour? ๐getCaretPeriod(This) -> integer() when This :: wxStyledTextCtrl().โ get the time in milliseconds that the caret is on and off. blink blink, no cap โฑ๏ธgetCaretSticky(This) -> integer() when This :: wxStyledTextCtrl().โ can the caret preferred x position only be changed by explicit movement commands? the return value will be one of the?wxSTC_CARETSTICKY_*constants ๐ซถgetCaretWidth(This) -> integer() when This :: wxStyledTextCtrl().โ returns the width of the insert mode caret โ๏ธgetCharAt(This, Pos) -> integer() when This :: wxStyledTextCtrl(), Pos :: integer().โ returns the character byte at the position ๐คgetCodePage(This) -> integer() when This :: wxStyledTextCtrl().โ get the code page used to interpret the bytes of the document as characters ๐getColumn(This, Pos) -> integer() when This :: wxStyledTextCtrl(), Pos :: integer().โ retrieve the column number of a position, taking tab width into account ๐getControlCharSymbol(This) -> integer() when This :: wxStyledTextCtrl().โ get the way control characters are displayed ๐getCurLine(This) -> Resultโ retrieve the text of the line containing the caret, she's a whole tuple ๐ง
when
Result ::
{Res :: unicode:charlist(),
LinePos :: integer()},
This :: wxStyledTextCtrl().
linePos can optionally be passed in to receive the index of the caret on the line. cute, right? ๐
getCurLineRaw(This) -> Resultโ retrieve the text of the line containing the caret, but raw this time ๐
when
Result ::
{Res :: binary(), LinePos :: integer()},
This :: wxStyledTextCtrl().
Returns the index of the caret on the line.
getCurrentLine(This) -> integer() when This :: wxStyledTextCtrl().โ returns the line number of the line with the caret ๐ขgetCurrentPos(This) -> integer() when This :: wxStyledTextCtrl().โ returns the position of the caret ๐getEOLMode(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the current end of line mode, which is one ofwxSTC_EOL_CRLF,wxSTC_EOL_CR, orwxSTC_EOL_LF. pick your line-ending princess ๐getEdgeColour(This) -> wx:wx_colour4() when This :: wxStyledTextCtrl().โ retrieve the colour used in edge indication ๐ธgetEdgeColumn(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the column number which text should be kept within ๐งgetEdgeMode(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the edge highlight mode. the return value will be one of the?wxSTC_EDGE_*constants โจgetEndAtLastLine(This) -> boolean() when This :: wxStyledTextCtrl().โ retrieve whether the maximum scroll position has the last line at the bottom of the view ๐getEndStyled(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the position of the last correctly styled character ๐getFirstVisibleLine(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the display line at the top of the display ๐๏ธgetFoldExpanded(This, Line) -> boolean() when This :: wxStyledTextCtrl(), Line :: integer().โ is a header line expanded? ๐getFoldLevel(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the fold level of a line ๐ชgetFoldParent(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ find the parent line of a child line. family reunion fr fr ๐จโ๐ฉโ๐งgetHighlightGuide(This) -> integer() when This :: wxStyledTextCtrl().โ get the highlighted indentation guide column ๐ฏgetIndent(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve indentation size ๐getIndentationGuides(This) -> integer() when This :: wxStyledTextCtrl().โ are the indentation guides visible? the return value will be one of the?wxSTC_IV_*constants ๐getLastChild(This, Line, Level) -> integer() when This :: wxStyledTextCtrl(), Line :: integer(), Level :: integer().โ find the last child line of a header line ๐งฌgetLastKeydownProcessed(This) -> boolean() when This :: wxStyledTextCtrl().โ can be used to prevent theEVT_CHARhandler from adding the char ๐ซgetLayoutCache(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the degree of caching of layout information. the return value will be one of the?wxSTC_CACHE_*constants ๐๏ธgetLength(This) -> integer() when This :: wxStyledTextCtrl().โ returns the number of bytes in the document ๐getLexer(This) -> integer() when This :: wxStyledTextCtrl().โ retrieve the lexing language of the document. the return value will be one of the?wxSTC_LEX_*constants ๐ฃ๏ธgetLine(This, Line) -> unicode:charlist() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the contents of a line ๐getLineCount(This) -> integer() when This :: wxStyledTextCtrl().โ returns the number of lines in the document. there is always at least one, bestie, even when it's empty ๐ซถgetLineEndPosition(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ get the position after the last visible characters on a line ๐getLineIndentPosition(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the position before the first non indentation character on a line โฉ๏ธgetLineIndentation(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the number of columns that a line is indented ๐getLineRaw(This, Line) -> binary() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the contents of a line, raw edition ๐getLineState(This, Line) -> integer() when This :: wxStyledTextCtrl(), Line :: integer().โ retrieve the extra styling information for a line ๐getLineVisible(This, Line) -> boolean() when This :: wxStyledTextCtrl(), Line :: integer().โ is a line visible? ๐๏ธgetMarginLeft(This) -> integer() when This :: wxStyledTextCtrl().โ returns the size in pixels of the left margin ๐getMarginMask(This, Margin) -> integer()โ the deets keep rolling in the next breath, hold on ๐ซถ
when
This :: wxStyledTextCtrl(),
Margin :: integer().
Returns the marker mask of a margin, bestie. Simple as that. ๐
getMarginRight(This) -> integer() when This :: wxStyledTextCtrl().
getMarginRight(This)โ hands you the size in pixels of the right margin. ๐
getMarginSensitive(This, Margin) -> boolean()
when
This :: wxStyledTextCtrl(),
Margin :: integer().
getMarginSensitive(This, Margin)โ tells you if margin is sensitive to mouse clicks. is it that girl? click-able or nah? ๐ฑ๏ธ
getMarginType(This, Margin) -> integer()
when
This :: wxStyledTextCtrl(),
Margin :: integer().
getMarginType(This, Margin)โ what type of margin are we dealing with, hmm? the return value will be one of the?wxSTC_MARGIN_*constants. โจ
getMarginWidth(This, Margin) -> integer()
when
This :: wxStyledTextCtrl(),
Margin :: integer().
getMarginWidth(This, Margin)โ gives you the width of margin in pixels, no cap. ๐
getMaxLineState(This) -> integer() when This :: wxStyledTextCtrl().
getMaxLineState(This)โ retrieve the last line number that has line state. iykyk. ๐ง
getModEventMask(This) -> integer() when This :: wxStyledTextCtrl().
getModEventMask(This)โ which document modification events are actually getting sent to the container? ๐
The return value will be wxSTC_MODEVENTMASKALL if all changes generate events. Otherwise it's a bit list containing one or more of the ?wxSTC_MOD_* constants, the ?wxSTC_PERFORMED_* constants, and also wxSTC_STARTACTION, wxSTC_MULTILINEUNDOREDO, wxSTC_MULTISTEPUNDOREDO, and wxSTC_LASTSTEPINUNDOREDO. literally the whole squad. ๐
getModify(This) -> boolean() when This :: wxStyledTextCtrl().
getModify(This)โ is the document different from when it was last saved? the moment of truth fr fr ๐ญ
getMouseDownCaptures(This) -> boolean()
when This :: wxStyledTextCtrl().
getMouseDownCaptures(This)โ get whether the mouse gets captured. gotcha! ๐ญ
getMouseDwellTime(This) -> integer()
when This :: wxStyledTextCtrl().
getMouseDwellTime(This)โ how long does the mouse have to sit still before it generates a mouse dwell event? the patience test.
The return value is a time in milliseconds or wxSTC_TIME_FOREVER. โณ
getOvertype(This) -> boolean() when This :: wxStyledTextCtrl().
getOvertype(This)โ returnstrueif overtype mode is active, otherwisefalsegets returned. typing-over-your-own-words energy.
getPasteConvertEndings(This) -> boolean()
when This :: wxStyledTextCtrl().
getPasteConvertEndings(This)โ get the convert-on-paste setting. line endings doing a lil glow-up on paste. โจ
getPrintColourMode(This) -> integer()
when This :: wxStyledTextCtrl().
getPrintColourMode(This)โ returns the print colour mode. the return value will be one of the?wxSTC_PRINT_*constants. ๐จ๏ธ
getPrintMagnification(This) -> integer()
when This :: wxStyledTextCtrl().
getPrintMagnification(This)โ returns the print magnification. zoom zoom but for the printer. ๐
getPrintWrapMode(This) -> integer()
when This :: wxStyledTextCtrl().
getPrintWrapMode(This)โ is printing line wrapped? the return value will be one of the?wxSTC_WRAP_*constants. ๐
getProperty(This, Key) -> unicode:charlist()
when
This :: wxStyledTextCtrl(),
Key :: unicode:chardata().
getProperty(This, Key)โ retrieve a"property"value that was previously set withSetProperty. the receipts, bestie. ๐งพ
getReadOnly(This) -> boolean() when This :: wxStyledTextCtrl().
getReadOnly(This)โ in read-only mode? just look, don't touch. ๐
getSTCCursor(This) -> integer() when This :: wxStyledTextCtrl().
getSTCCursor(This)โ get the cursor type. the return value will be one of the?wxSTC_CURSOR*constants. ๐โจ
getSTCFocus(This) -> boolean() when This :: wxStyledTextCtrl().
getSTCFocus(This)โ get the internal focus flag. main character energy check. ๐
getScrollWidth(This) -> integer() when This :: wxStyledTextCtrl().
getScrollWidth(This)โ retrieve the document width assumed for scrolling. ๐
getSearchFlags(This) -> integer() when This :: wxStyledTextCtrl().
getSearchFlags(This)โ get the search flags used bySearchInTarget. the return value will be a bit list containing one or more of the?wxSTC_FIND_*constants. ๐
getSelAlpha(This) -> integer() when This :: wxStyledTextCtrl().
getSelAlpha(This)โ get the alpha of the selection. it's giving translucent. ๐ฆ
getSelectedText(This) -> unicode:charlist()
when This :: wxStyledTextCtrl().
getSelectedText(This)โ retrieve the selected text. the chosen ones. ๐ซถ
getSelectedTextRaw(This) -> binary()
when This :: wxStyledTextCtrl().
getSelectedTextRaw(This)โ retrieve the selected text. again! but raw this time, as a binary. ๐
getSelection(This) -> {From :: integer(), To :: integer()}
when This :: wxStyledTextCtrl().
getSelection(This)โ gets the current selection span. ๐
If the returned values are equal, there was no selection. and heads up bestie: please note that the indices returned may be used with the other wxTextCtrl methods, but they don't necessarily represent the correct indices into the string returned by wxComboBox:getValue/1 for multiline controls under Windows (at least,) so you should use wxTextCtrl:getStringSelection/1 to get the selected text. fr fr, heed the warning. โ ๏ธ
getSelectionEnd(This) -> integer() when This :: wxStyledTextCtrl().
getSelectionEnd(This)โ returns the position at the end of the selection. ๐ฏ
getSelectionMode(This) -> integer()
when This :: wxStyledTextCtrl().
getSelectionMode(This)โ get the mode of the current selection. the return value will be one of the?wxSTC_SEL_*constants. โจ
getSelectionStart(This) -> integer()
when This :: wxStyledTextCtrl().
getSelectionStart(This)โ returns the position at the start of the selection. ๐ฏ
getStatus(This) -> integer() when This :: wxStyledTextCtrl().
getStatus(This)โ get error status. the return value will be one of the?wxSTC_STATUS_*constants. ๐ (hopefully not an error tho)
getStyleAt(This, Pos) -> integer()
when This :: wxStyledTextCtrl(), Pos :: integer().
getStyleAt(This, Pos)โ returns the style byte at the position. ๐จ
getStyleBits(This) -> integer() when This :: wxStyledTextCtrl().
getStyleBits(This)โ retrieve the number of bits in style bytes used to hold the lexical state.
Deprecated: โ ๏ธ okay so this one's deprecated, don't build your whole personality around it bestie.
getStyleBitsNeeded(This) -> integer()
when This :: wxStyledTextCtrl().
getStyleBitsNeeded(This)โ retrieve the number of bits the current lexer needs for styling.
Deprecated: โ ๏ธ also deprecated. we moved on, and that's okay. ๐
getTabIndents(This) -> boolean() when This :: wxStyledTextCtrl().
getTabIndents(This)โ does a tab pressed when the caret is within indentation actually indent? ๐ค
getTabWidth(This) -> integer() when This :: wxStyledTextCtrl().
getTabWidth(This)โ retrieve the visible size of a tab. how thicc is that tab. ๐
getTargetEnd(This) -> integer() when This :: wxStyledTextCtrl().
getTargetEnd(This)โ get the position that ends the target. ๐
getTargetStart(This) -> integer() when This :: wxStyledTextCtrl().
getTargetStart(This)โ get the position that starts the target. ๐ฉ
getText(This) -> unicode:charlist()
when This :: wxStyledTextCtrl().
getText(This)โ retrieve all the text in the document. the whole thing. every word. ๐
getTextLength(This) -> integer() when This :: wxStyledTextCtrl().
getTextLength(This)โ retrieve the number of characters in the document. count 'em. ๐ข
getTextRange(This, StartPos, EndPos) -> unicode:charlist()
when
This :: wxStyledTextCtrl(),
StartPos :: integer(),
EndPos :: integer().
getTextRange(This, StartPos, EndPos)โ retrieve a range of text. the slice. ๐ฐ
getTextRangeRaw(This, StartPos, EndPos) -> binary()
when
This :: wxStyledTextCtrl(),
StartPos :: integer(),
EndPos :: integer().
getTextRangeRaw(This, StartPos, EndPos)โ retrieve a range of text. but raw, bestie, so it's a binary. ๐ฆ
getTextRaw(This) -> binary() when This :: wxStyledTextCtrl().
getTextRaw(This)โ retrieve all the text in the document, in raw binary form. ๐
getTwoPhaseDraw(This) -> boolean() when This :: wxStyledTextCtrl().
getTwoPhaseDraw(This)โ is drawing done in two phases with backgrounds drawn before foregrounds? the layering order check. ๐จ
getUndoCollection(This) -> boolean()
when This :: wxStyledTextCtrl().
getUndoCollection(This)โ is undo history being collected? are we keeping the receipts? ๐งพ
getUseAntiAliasing(This) -> boolean()
when This :: wxStyledTextCtrl().
getUseAntiAliasing(This)โ returns the currentUseAntiAliasingsetting. smooth like butter. ๐งโจ
getUseHorizontalScrollBar(This) -> boolean()
when This :: wxStyledTextCtrl().
getUseHorizontalScrollBar(This)โ is the horizontal scroll bar visible? ๐
getUseTabs(This) -> boolean() when This :: wxStyledTextCtrl().
getUseTabs(This)โ retrieve whether tabs will be used in indentation. tabs girlies rise. ๐
getUseVerticalScrollBar(This) -> boolean()
when This :: wxStyledTextCtrl().
getUseVerticalScrollBar(This)โ is the vertical scroll bar visible? ๐
getViewEOL(This) -> boolean() when This :: wxStyledTextCtrl().
getViewEOL(This)โ are the end of line characters visible? do we see the\n? ๐ธ
getViewWhiteSpace(This) -> integer()
when This :: wxStyledTextCtrl().
getViewWhiteSpace(This)โ are white space characters currently visible? returns one of thewxSTC_WS_*constants. ๐ซง
getWrapMode(This) -> integer() when This :: wxStyledTextCtrl().
getWrapMode(This)โ retrieve whether text is word wrapped. the return value will be one of the?wxSTC_WRAP_*constants. ๐
getWrapStartIndent(This) -> integer()
when This :: wxStyledTextCtrl().
getWrapStartIndent(This)โ retrieve the start indent for wrapped lines. ๐
getWrapVisualFlags(This) -> integer()
when This :: wxStyledTextCtrl().
getWrapVisualFlags(This)โ retrieve the display mode of visual flags for wrapped lines. the return value will be a bit list containing one or more of the?wxSTC_WRAPVISUALFLAG_*constants. ๐ฉ
getWrapVisualFlagsLocation(This) -> integer()
when This :: wxStyledTextCtrl().
getWrapVisualFlagsLocation(This)โ retrieve the location of visual flags for wrapped lines. the return value will be a bit list containing one or more of the?wxSTC_WRAPVISUALFLAGLOC_*constants. ๐
getXOffset(This) -> integer() when This :: wxStyledTextCtrl().
getXOffset(This)โ get thexOffset(ie, the horizontal scroll position). sliding to the side. โก๏ธ
getZoom(This) -> integer() when This :: wxStyledTextCtrl().
getZoom(This)โ retrieve the zoom level. how zoomed in are we feeling today. ๐
gotoLine(This, Line) -> ok
when This :: wxStyledTextCtrl(), Line :: integer().
gotoLine(This, Line)โ set the caret to the start of a line and make sure it's visible. teleport, but make it text. โจ
gotoPos(This, Caret) -> ok
when This :: wxStyledTextCtrl(), Caret :: integer().
gotoPos(This, Caret)โ set the caret to a position and ensure it's visible. ๐ฏ
hideLines(This, LineStart, LineEnd) -> ok
when
This :: wxStyledTextCtrl(),
LineStart :: integer(),
LineEnd :: integer().
hideLines(This, LineStart, LineEnd)โ make a range of lines invisible. poof, gone (but not deleted, bestie, just hidden). ๐
hideSelection(This, Hide) -> ok
when
This :: wxStyledTextCtrl(), Hide :: boolean().
hideSelection(This, Hide)โ draw the selection in normal style, or with the selection highlighted. do we show off the highlight or keep it lowkey. ๐
home(This) -> ok when This :: wxStyledTextCtrl().
home(This)โ takes you home. ๐home(This) -> okโ bestie, this one yeets the caret all the way back to the first position on the line ๐ ๐จhomeDisplay(This) -> okโ same energy but it goes to the first position on the display line instead (word-wrap girlies know the difference) โจhomeDisplayExtend(This) -> okโ jumps to the start of the display line and stretches the selection out to where the caret lands ๐ซถhomeExtend(This) -> okโ first position on the line, and the selection gets extended to the new caret spot too ๐homeRectExtend(This) -> okโ first position on the line, but now we're extending a rectangular selection. block-select icon behaviour, we love to see it ๐ฅhomeWrapExtend(This) -> okโ it's giving HomeExtend but with a plot twist: when word-wrap is on, it goes first to the start of the display line (HomeDisplayExtend), and then to the start of the document line (HomeExtend) ๐indicatorGetForegroundโ grab the foreground colour of an indicator ๐จ
indicatorGetForeground(This, Indicator) -> wx:wx_colour4()
when
This :: wxStyledTextCtrl(),
Indicator :: integer().
indicatorGetStyleโ pull the style of an indicator. the return value will be one of the?wxSTC_INDIC_*constants, no cap โจ
indicatorGetStyle(This, Indicator) -> integer()
when
This :: wxStyledTextCtrl(),
Indicator :: integer().
indicatorSetForeground(This, Indicator, Fore) -> okโ set the foreground colour of an indicator. glow-up time ๐๏ธindicatorSetStyleโ set an indicator to plain, squiggle or TT. the second argument should be one of the?wxSTC_INDIC_*constants ๐
indicatorSetStyle(This, Indicator, IndicatorStyle) -> ok
when
This :: wxStyledTextCtrl(),
Indicator :: integer(),
IndicatorStyle :: integer().
insertTextโ drop a string in at a position. get in there ๐ซถ
insertText(This, Pos, Text) -> ok
when
This :: wxStyledTextCtrl(),
Pos :: integer(),
Text :: unicode:chardata().
insertTextRawโ insert a string at a position, but the raw binary-flavoured version ๐ฆ
insertTextRaw(This, Pos, Text) -> ok
when
This :: wxStyledTextCtrl(),
Pos :: integer(),
Text :: binary().
lineCopy(This) -> okโ copy the whole line the caret is sitting on ๐lineCut(This) -> okโ โ๏ธ cut the line containing the caretlineDelete(This) -> okโ delete the line containing the caret. gone. reduced to atoms ๐lineDown(This) -> okโ move the caret down one line โฌ๏ธlineDownExtend(This) -> okโ caret down one line and the selection extends to the new caret position ๐ธlineDownRectExtend(This) -> okโ caret down one line, extending the rectangular selection to the new caret position ๐lineDuplicate(This) -> okโ duplicate the current line. twin moment ๐ฏlineEnd(This) -> okโ move the caret to the last position on the line ๐lineEndDisplay(This) -> okโ move the caret to the last position on the display line ๐lineEndDisplayExtend(This) -> okโ last position on the display line, with the selection extended to the new caret position ๐lineEndExtend(This) -> okโ last position on the line, extending the selection to the new caret position โญlineEndRectExtend(This) -> okโ last position on the line, extending a rectangular selection to the new caret position ๐lineEndWrap(This) -> okโ likeLineEndbut when word-wrap is enabled it goes first to the end of the display line (LineEndDisplay), then to the start of the document line (LineEnd). yes, start. that's what it says, bestie ๐lineEndWrapExtend(This) -> okโ same deal asLineEndExtend, but with word-wrap on it extends first to the end of the display line (LineEndDisplayExtend), then to the start of the document line (LineEndExtend) ๐ซงlineFromPositionโ figure out which line contains a position ๐
lineFromPosition(This, Pos) -> integer()
when
This :: wxStyledTextCtrl(),
Pos :: integer().
lineLengthโ how many characters are on a line, including end of line characters? yes, including them, don't come for me ๐
lineLength(This, Line) -> integer()
when This :: wxStyledTextCtrl(), Line :: integer().
lineScrollโ scroll horizontally and vertically in one go ๐
lineScroll(This, Columns, Lines) -> ok
when
This :: wxStyledTextCtrl(),
Columns :: integer(),
Lines :: integer().
lineScrollDown(This) -> okโ scroll the document down while keeping the caret visible. caret stays the main character ๐โฌ๏ธlineScrollUp(This) -> okโ scroll the document up, caret still visible, still iconic โฌ๏ธโจlineTranspose(This) -> okโ swap the current line with the previous one ๐lineUp(This) -> okโ move the caret up one line โฌ๏ธlineUpExtend(This) -> okโ caret up one line, selection extended to the new caret position ๐ซlineUpRectExtend(This) -> okโ caret up one line, extending the rectangular selection to the new caret position ๐งlinesJoin(This) -> okโ join the lines in the target. conga line ๐linesOnScreen(This) -> integer()โ retrieves the number of lines completely visible. fully on screen or it doesn't count ๐linesSplitโ split the lines in the target into lines that are less wide than pixelWidth where possible ๐ช
linesSplit(This, PixelWidth) -> ok
when
This :: wxStyledTextCtrl(),
PixelWidth :: integer().
loadFileโ load the contents of filename into the editor ๐
loadFile(This, Filename) -> boolean()
when
This :: wxStyledTextCtrl(),
Filename :: unicode:chardata().
lowerCase(This) -> okโ transform the selection to lower case. quiet, lowercase, demure ๐กmarkerAddโ add a marker to a line and get back an ID you can use to find or delete that marker ๐ท๏ธ
markerAdd(This, Line, MarkerNumber) -> integer()
when
This :: wxStyledTextCtrl(),
Line :: integer(),
MarkerNumber :: integer().
markerAddSet(This, Line, MarkerSet) -> okโ add a whole set of markers to a line. bundle deal ๐markerDefineโ set the symbol used for a particular marker number, and optionally the fore and background colours. the second argument should be one of the?wxSTC_MARK_*constants ๐จ
markerDefine(This, MarkerNumber, MarkerSymbol, [Option]) -> ok
when
This :: wxStyledTextCtrl(),
MarkerNumber :: integer(),
MarkerSymbol :: integer(),
Option ::
{foreground, wx:wx_colour()} |
{background, wx:wx_colour()}.
markerDefineBitmap(This, MarkerNumber, Bmp) -> okโ define a marker using awxBitmap๐ผ๏ธmarkerDelete(This, Line, MarkerNumber) -> okโ delete a marker from a line ๐๏ธmarkerDeleteAll(This, MarkerNumber) -> okโ nuke every marker with that particular number across all lines ๐ฅmarkerDeleteHandle(This, MarkerHandle) -> okโ delete a marker by its handle ๐ชmarkerGet(This, Line) -> integer()โ get a bit mask of every marker set on a line ๐ญmarkerLineFromHandleโ retrieve the line number where a particular marker is hanging out ๐
markerLineFromHandle(This, MarkerHandle) -> integer()
when
This :: wxStyledTextCtrl(),
MarkerHandle :: integer().
markerNextโ find the next line at or after lineStart that includes a marker in mask. returns-1when there are no more lines โก๏ธ
markerNext(This, LineStart, MarkerMask) -> integer()
when
This :: wxStyledTextCtrl(),
LineStart :: integer(),
MarkerMask :: integer().
markerPreviousโ find the previous line before lineStart that includes a marker in mask โฌ ๏ธ
markerPrevious(This, LineStart, MarkerMask) -> integer()
when
This :: wxStyledTextCtrl(),
LineStart :: integer(),
MarkerMask :: integer().
markerSetAlphaโ here's the signature this part of the page hands us ๐
markerSetAlpha(This, MarkerNumber, Alpha) -> ok
when
This :: wxStyledTextCtrl(),
MarkerNumber :: integer(),
Alpha :: integer().
Set the alpha used for a marker that is drawn in the text area, not the margin. iykyk, margins are their own little kingdom ๐
markerSetBackground(This, MarkerNumber, Back) -> ok
markerSetBackground(This, MarkerNumber, Back) -> ok
when
This :: wxStyledTextCtrl(),
MarkerNumber :: integer(),
Back :: wx:wx_colour().
Sets the background colour for one specific marker number. One number, one colour, no sharing bestie ๐ธ
markerSetForeground(This, MarkerNumber, Fore) -> ok
markerSetForeground(This, MarkerNumber, Fore) -> ok
when
This :: wxStyledTextCtrl(),
MarkerNumber :: integer(),
Fore :: wx:wx_colour().
And this is the foreground colour for that same marker number. Foreground and background are two different fits and both are iconic โจ
moveCaretInsideView(This) -> ok
moveCaretInsideView(This) -> ok when This :: wxStyledTextCtrl().
If the caret has wandered off the visible area, this drags it back inside the current view. No caret left behind, periodt ๐
new() -> wxStyledTextCtrl()
new() -> wxStyledTextCtrl().
The default ctor. Bare bones, no parent, no options, just vibes. ๐ฆ
new(Parent, [Option]) -> wxStyledTextCtrl()
new(Parent, [Option]) -> wxStyledTextCtrl()
when
Parent :: wxWindow:wxWindow(),
Option ::
{id, integer()} |
{pos, {X :: integer(), Y :: integer()}} |
{size, {W :: integer(), H :: integer()}} |
{style, integer()}.
The ctor with a parent and a lil list of options. You got {id, integer()}, {pos, {X :: integer(), Y :: integer()}}, {size, {W :: integer(), H :: integer()}}, and {style, integer()}. Pick your faves ๐
newLine(This) -> ok
newLine(This) -> ok when This :: wxStyledTextCtrl().
Drops in a new line. Whether that's a CRLF, CR or LF depends on the EOL mode โ it's giving "I match the room I'm in" ๐ง
pageDown(This) -> ok
pageDown(This) -> ok when This :: wxStyledTextCtrl().
Caret moves one page down. Simple, elegant, ate ๐
pageDownExtend(This) -> ok
pageDownExtend(This) -> ok when This :: wxStyledTextCtrl().
One page down and the selection stretches all the way to the new caret position. Selecting while you scroll, main character energy ๐
pageDownRectExtend(This) -> ok
pageDownRectExtend(This) -> ok when This :: wxStyledTextCtrl().
Same page-down move, except it extends a rectangular selection to the new caret position. Block select girlies rise ๐
pageUp(This) -> ok
pageUp(This) -> ok when This :: wxStyledTextCtrl().
Caret goes one page up. The reverse of the above, no notes ๐
pageUpExtend(This) -> ok
pageUpExtend(This) -> ok when This :: wxStyledTextCtrl().
One page up, selection extended to the new caret position. ๐
pageUpRectExtend(This) -> ok
pageUpRectExtend(This) -> ok when This :: wxStyledTextCtrl().
One page up, rectangular selection extended to the new caret position. Yes queen, block select upward too ๐ฆ
paraDownExtend(This) -> ok
paraDownExtend(This) -> ok when This :: wxStyledTextCtrl().
Extends the selection down one paragraph โ and paragraphs are delimited by empty lines, no cap ๐
paraUp(This) -> ok
paraUp(This) -> ok when This :: wxStyledTextCtrl().
Moves the caret up one paragraph, same deal: paragraphs are split by empty lines. Literally so clean โจ
paraUpExtend(This) -> ok
paraUpExtend(This) -> ok when This :: wxStyledTextCtrl().
Extends the selection up one paragraph, empty-line delimited as always. ๐ซถ
paste(This) -> ok
paste(This) -> ok when This :: wxStyledTextCtrl().
Pastes whatever's on the clipboard into the document โ and it replaces the selection, so watch out if you had something highlighted ๐
pointFromPosition(This, Pos) -> {X :: integer(), Y :: integer()}
pointFromPosition(This, Pos) -> {X :: integer(), Y :: integer()}
when
This :: wxStyledTextCtrl(),
Pos :: integer().
Give it a position, get back the point in the window where that position is actually displayed. Coordinates unlocked ๐
positionAfter(This, Pos) -> integer()
positionAfter(This, Pos) -> integer()
when This :: wxStyledTextCtrl(), Pos :: integer().
Hand it a valid document position and it returns the next position, taking the code page into account.
Heads up bestie: the maximum value it can return is the last position in the document. That's the ceiling, fr fr ๐
positionBefore(This, Pos) -> integer()
positionBefore(This, Pos) -> integer()
when
This :: wxStyledTextCtrl(), Pos :: integer().
Give it a valid document position, get the previous position, code page aware and everything.
And if you pass it 0? It returns 0. Sibling behaviour fr ๐
positionFromLine(This, Line) -> integer()
positionFromLine(This, Line) -> integer()
when
This :: wxStyledTextCtrl(),
Line :: integer().
Retrieves the position at the very start of a line. Line in, position out, slay ๐
positionFromPoint(This, Pt) -> integer()
positionFromPoint(This, Pt) -> integer()
when
This :: wxStyledTextCtrl(),
Pt :: {X :: integer(), Y :: integer()}.
Find the position from a point inside the window. Click-adjacent math, we love her โจ
positionFromPointClose(This, X, Y) -> integer()
positionFromPointClose(This, X, Y) -> integer()
when
This :: wxStyledTextCtrl(),
X :: integer(),
Y :: integer().
Same idea as above, but this one returns wxSTC_INVALID_POSITION if the point isn't actually close to text. Honest AND dramatic ๐
redo(This) -> ok
redo(This) -> ok when This :: wxStyledTextCtrl().
Redoes the next action on the undo history. The redo to your undo, iconic duo ๐
registerImage(This, Type, Bmp) -> ok
registerImage(This, Type, Bmp) -> ok
when
This :: wxStyledTextCtrl(),
Type :: integer(),
Bmp :: wxBitmap:wxBitmap().
Registers an image so it can be used in autocompletion lists. Little pictures in ya dropdown, obsessed ๐ธ
replaceSelection(This, Text) -> ok
replaceSelection(This, Text) -> ok
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
Swaps out the currently selected text for the text you pass in. Out with the old, in with the new ๐
replaceTarget(This, Text) -> integer()
replaceTarget(This, Text) -> integer()
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
Replaces the target text with the argument text.
Important detail: the text is counted, so it can contain NULs. And it returns the length of the replacement text ๐
saveFile(This, Filename) -> boolean()
saveFile(This, Filename) -> boolean()
when
This :: wxStyledTextCtrl(),
Filename :: unicode:chardata().
Writes the contents of the editor out to filename. Returns a boolean, so you'll know if it worked ๐ซถ
scrollToColumn(This, Column) -> ok
scrollToColumn(This, Column) -> ok
when
This :: wxStyledTextCtrl(),
Column :: integer().
Scrolls just enough to make the given column visible. No over-scrolling, she's precise ๐
scrollToLine(This, Line) -> ok
scrollToLine(This, Line) -> ok
when This :: wxStyledTextCtrl(), Line :: integer().
Scrolls enough to make the given line visible. Same energy, different axis ๐
searchAnchor(This) -> ok
searchAnchor(This) -> ok when This :: wxStyledTextCtrl().
Sets the current caret position as the search anchor. That's your home base for searching now ๐
searchInTarget(This, Text) -> integer()
searchInTarget(This, Text) -> integer()
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
Searches for a counted string inside the target, and if it finds it, sets the target to the found range.
Because it's counted, the text can contain NULs. Returns the length of the range, or -1 on failure โ and in that failure case, the target is not moved. Fair warning bestie โ ๏ธ
searchNext(This, SearchFlags, Text) -> integer()
searchNext(This, SearchFlags, Text) -> integer()
when
This :: wxStyledTextCtrl(),
SearchFlags :: integer(),
Text :: unicode:chardata().
Finds some text starting at the search anchor.
Careful: it does not ensure the selection is visible. So it might find it and you're still squinting at the screen ๐ญ
searchPrev(This, SearchFlags, Text) -> integer()
searchPrev(This, SearchFlags, Text) -> integer()
when
This :: wxStyledTextCtrl(),
SearchFlags :: integer(),
Text :: unicode:chardata().
Finds some text starting at the search anchor but moving backwards.
And same warning as its sibling: it does not ensure the selection is visible. ๐
selectAll(This) -> ok
selectAll(This) -> ok when This :: wxStyledTextCtrl().
Selects all the text in the document. Ctrl+A behaviour, we know her ๐
selectionDuplicate(This) -> ok
selectionDuplicate(This) -> ok when This :: wxStyledTextCtrl().
Duplicates the selection.
And if the selection is empty? It duplicates the line containing the caret instead. Cute little fallback behaviour ๐
selectionIsRectangle(This) -> boolean()
selectionIsRectangle(This) -> boolean()
when This :: wxStyledTextCtrl().
Is the selection rectangular? The alternative is the more common stream selection. So basically: block mode or normal mode, pick your fighter ๐
setAnchor(This, Anchor) -> ok
setAnchor(This, Anchor) -> ok
when This :: wxStyledTextCtrl(), Anchor :: integer().
Sets the selection anchor to a position. The anchor is the opposite end of the selection from the caret โ so caret on one side, anchor on the other, and everything between is selected โจ
setBackSpaceUnIndents(This, BsUnIndents) -> ok
setBackSpaceUnIndents(This, BsUnIndents) -> ok
when
This :: wxStyledTextCtrl(),
BsUnIndents :: boolean().
Sets whether hitting backspace while the caret is sitting inside the indentation un-indents. Smart backspace, she's got range ๐ง
setBufferedDraw(This, Buffered) -> ok
setBufferedDraw(This, Buffered) -> ok
when
This :: wxStyledTextCtrl(),
Buffered :: boolean().
If drawing is buffered, every line of text gets drawn into a bitmap buffer first before it hits the screen โ all to avoid flicker. Say no to flicker ๐ซโจ
setCaretForeground(This, Fore) -> ok
setCaretForeground(This, Fore) -> ok
when
This :: wxStyledTextCtrl(),
Fore :: wx:wx_colour().
Sets the foreground colour of the caret. Yes, your blinking little cursor can serve looks ๐
setCaretLineBackAlpha(This, Alpha) -> ok
setCaretLineBackAlpha(This, Alpha) -> ok
when
This :: wxStyledTextCtrl(),
Alpha :: integer().
Sets the background alpha of the caret line. Translucent highlighter moment ๐ธ
setCaretLineBackground(This, Back) -> ok
setCaretLineBackground(This, Back) -> ok
when
This :: wxStyledTextCtrl(),
Back :: wx:wx_colour().
Sets the colour of the background of the line the caret is currently on. Give that line a whole personality ๐
setCaretLineVisible(This, Show) -> ok
setCaretLineVisible(This, Show) -> ok
when
This :: wxStyledTextCtrl(),
Show :: boolean().
Turns on displaying the background of the caret's line in a different colour. Current line? Highlighted. Periodt ๐
setCaretPeriod(This, PeriodMilliseconds) -> ok
setCaretPeriod(This, PeriodMilliseconds) -> ok
when
This :: wxStyledTextCtrl(),
PeriodMilliseconds :: integer().
Sets the time, in milliseconds, that the caret is on and off. So yes, this is the blink speed, bestie ๐
And a very specific note: 0 means steady on โ i.e. no blinking at all. A frozen caret. Iconic choice ๐
setCaretSticky(This, UseCaretStickyBehaviour) -> ok
setCaretSticky(This, UseCaretStickyBehaviour) -> ok
when
This :: wxStyledTextCtrl(),
UseCaretStickyBehaviour :: integer().
Stops the caret's preferred x position from changing while the user types. Your vertical position stays put, no drifting ๐
The input should be one of the ?wxSTC_CARETSTICKY_* constants. Don't freestyle it ๐ซถ
setCaretWidth(This, PixelWidth) -> ok
setCaretWidth(This, PixelWidth) -> ok
when
This :: wxStyledTextCtrl(),
PixelWidth :: integer().
Sets the width of the insert mode caret, in pixels. Thick caret, thin caret, the choice is yours โจ
setCharsDefault
setCharsDefault(This) -> ok
when This :: wxStyledTextCtrl().
okay so this one is the big "never mind, forget it" button ๐ โ it resets the set of characters used for whitespace and for word characters right back to the defaults. If you've been out here customizing your whitespace vibes and now everything looks cursed? this is the glow-up reset. ๐ธ
setCodePage
setCodePage(This, CodePage) -> ok
when This :: wxStyledTextCtrl(),
CodePage :: integer().
Sets the code page used to interpret the bytes of the document as characters, bestie. It's the whole "are these bytes text or are these bytes chaos" question, decided by one integer. ๐ค
setControlCharSymbol
setControlCharSymbol(This, Symbol) -> ok
when This :: wxStyledTextCtrl(),
Symbol :: integer().
Change the way control characters are displayed, fr fr. If Symbol is < 32, keep the drawn way โ otherwise, use the given character. So low numbers = leave it, bigger numbers = we're drawing it ourselves now. โจ
setCurrentPos
setCurrentPos(This, Caret) -> ok
when This :: wxStyledTextCtrl(),
Caret :: integer().
Sets the position of the caret. That's it, that's the whole thing โ where the little blinking girlie lives. ๐
setEOLMode
setEOLMode(This, EolMode) -> ok
when This :: wxStyledTextCtrl(),
EolMode :: integer().
Set the current end of line mode. The input should be one of the ?wxSTC_EOL_* constants. (yes, bestie, this is the LF vs CRLF vs CR discourse and it will start fights in the group chat ๐ญ)
setEdgeColour
setEdgeColour(This, EdgeColour) -> ok
when This :: wxStyledTextCtrl(),
EdgeColour :: wx:wx_colour().
Change the colour used in edge indication. Purely a lewk โ this one's about aesthetics, not behaviour. ๐
setEdgeColumn
setEdgeColumn(This, Column) -> ok
when This :: wxStyledTextCtrl(),
Column :: integer().
Set the column number of the edge. If text goes past the edge then it is highlighted. The edge is watching, and it will call you out. ๐
setEdgeMode
setEdgeMode(This, EdgeMode) -> ok
when This :: wxStyledTextCtrl(),
EdgeMode :: integer().
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).
The input should be one of the ?wxSTC_EDGE_* constants. Line mode = a polite little ruler. Background mode = the style police. None = unbothered, moisturized, in her lane. ๐
setFoldExpanded
setFoldExpanded(This, Line, Expanded) -> ok
when This :: wxStyledTextCtrl(),
Line :: integer(),
Expanded :: boolean().
Show the children of a header line. Expanded is a boolean, so it's a straight yes/no: do we unfold the babies or do we keep them tucked away? ๐ฆ
setFoldFlags
setFoldFlags(This, Flags) -> ok
when This :: wxStyledTextCtrl(),
Flags :: integer().
Set some style options for folding. The second argument should be a bit list containing one or more of the ?wxSTC_FOLDFLAG_* constants. It's giving bitlist cocktails, honestly. โจ
setFoldLevel
setFoldLevel(This, Line, Level) -> ok
when This :: wxStyledTextCtrl(),
Line :: integer(),
Level :: integer().
Set the fold level of a line.
This encodes an integer level along with flags indicating whether the line is a header and whether it is effectively white space. So one integer, three secrets. ๐คซ
setFoldMarginColour
setFoldMarginColour(This, UseSetting, Back) -> ok
when This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Back :: wx:wx_colour().
Set one of the colours used as a chequerboard pattern in the fold margin. Yes bestie, a chequerboard pattern, the fold margin is fashion โจ
setFoldMarginHiColour
setFoldMarginHiColour(This, UseSetting, Fore) -> ok
when This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Fore :: wx:wx_colour().
Set the other colour used as a chequerboard pattern in the fold margin. Matching-set energy with the one above โ do not wear one without the other. ๐
setHScrollBar
setHScrollBar(This, Bar) -> ok
when This :: wxStyledTextCtrl(),
Bar :: wxScrollBar:wxScrollBar().
Set the horizontal scrollbar to use instead of the one that's built-in. You're swapping in your own scrollbar, main character style. ๐
setHighlightGuide
setHighlightGuide(This, Column) -> ok
when This :: wxStyledTextCtrl(),
Column :: integer().
Set the highlighted indentation guide column. 0 = no highlighted guide. Zero means nobody gets highlighted, she's off duty. ๐
setHotspotActiveBackground
setHotspotActiveBackground(This, UseSetting, Back) -> ok
when This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Back :: wx:wx_colour().
Set a back colour for active hotspots. Background lewk, acquired. ๐๏ธ
setHotspotActiveForeground
setHotspotActiveForeground(This, UseSetting, Fore) -> ok
when This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Fore :: wx:wx_colour().
Set a fore colour for active hotspots. Front-facing lewk, also acquired. ๐
setHotspotActiveUnderline
setHotspotActiveUnderline(This, Underline) -> ok
when This :: wxStyledTextCtrl(),
Underline :: boolean().
Enable / Disable underlining active hotspots. Underline on = extra emphasis, underline off = keeping it subtle. A boolean, no drama. ๐
setHotspotSingleLine
setHotspotSingleLine(This, SingleLine) -> ok
when This :: wxStyledTextCtrl(),
SingleLine :: boolean().
Limit hotspots to single line so hotspots on two lines don't merge. Yes โ this is the anti-fusion setting, keep your hotspots in their own lanes bestie ๐
setIndent
setIndent(This, IndentSize) -> ok
when This :: wxStyledTextCtrl(),
IndentSize :: integer().
Set the number of spaces used for one level of indentation. Pick your number and commit to it. (we all know what happens in the group chat when someone says "2 vs 4" ๐ญ)
setIndentationGuides
setIndentationGuides(This, IndentView) -> ok
when This :: wxStyledTextCtrl(),
IndentView :: integer().
Show or hide indentation guides. The input should be one of the ?wxSTC_IV_* constants. Little vertical lines that whisper "you are inside a block" ๐ธ
setKeyWords
setKeyWords(This, KeyWordSet, KeyWordSet, KeyWords) -> ok
cute so here's the real one, exactly as she is:
setKeyWords(This, KeyWordSet, KeyWords) -> ok
when This :: wxStyledTextCtrl(),
KeyWordSet :: integer(),
KeyWords :: unicode:chardata().
Set up the key words used by the lexer. Number the keyword set, hand over the words as chardata, and the lexer starts caring about them. ๐๏ธ
setLastKeydownProcessed
setLastKeydownProcessed(This, Val) -> ok
when This :: wxStyledTextCtrl(),
Val :: boolean().
Returns the line number of the line with the caret.
no because why does the doc for this literally say that ๐ that's what the docs say, word for word โ the name says "set" and the description says "returns", and we are simply reporting the lore as written. Val is a boolean. Do with that what you will, bestie.
setLayoutCache
setLayoutCache(This, CacheMode) -> ok
when This :: wxStyledTextCtrl(),
CacheMode :: integer().
Sets the degree of caching of layout information. The input should be one of the ?wxSTC_CACHE_* constants. Cache like your life depends on it, it's how you stay fast. ๐ฅ
setLexer
setLexer(This, Lexer) -> ok
when This :: wxStyledTextCtrl(), Lexer :: integer().
Set the lexing language of the document. The input should be one of the ?wxSTC_LEX_* constants. This is the "which language are we, actually" moment. ๐
setLexerLanguage
setLexerLanguage(This, Language) -> ok
when This :: wxStyledTextCtrl(),
Language :: unicode:chardata().
Set the lexing language of the document based on string name. Same vibe as setLexer but you're naming it with words instead of a constant โ chardata, bestie, not an integer. โจ
setLineIndentation
setLineIndentation(This, Line, Indentation) -> ok
when This :: wxStyledTextCtrl(),
Line :: integer(),
Indentation :: integer().
Change the indentation of a line to a number of columns. Note it's columns, not spaces, not tabs, columns. ๐
setLineState
setLineState(This, Line, State) -> ok
when This :: wxStyledTextCtrl(),
Line :: integer(),
State :: integer().
Used to hold extra styling information for each line. It's your own lil per-line stash โ the app decides what State means, the control just holds it for you. ๐
setMarginLeft
setMarginLeft(This, PixelWidth) -> ok
when This :: wxStyledTextCtrl(),
PixelWidth :: integer().
Sets the size in pixels of the left margin. Pixels, bestie, not characters. ๐
setMarginMask
setMarginMask(This, Margin, Mask) -> ok
when This :: wxStyledTextCtrl(),
Margin :: integer(),
Mask :: integer().
Set a mask that determines which markers are displayed in a margin. Mask says yes to the markers that get to appear and absolutely not to the rest. ๐
setMarginRight
setMarginRight(This, PixelWidth) -> ok
when This :: wxStyledTextCtrl(),
PixelWidth :: integer().
Sets the size in pixels of the right margin. Matching set with setMarginLeft, and yes, still pixels. ๐
setMarginSensitive
setMarginSensitive(This, Margin, Sensitive) -> ok
when This :: wxStyledTextCtrl(),
Margin :: integer(),
Sensitive :: boolean().
Make a margin sensitive or insensitive to mouse clicks. Sensitive is a boolean: clicks welcome, or clicks not welcome, no in-between. ๐ฑ๏ธ
setMarginType
setMarginType(This, Margin, MarginType) -> ok
when This :: wxStyledTextCtrl(),
Margin :: integer(),
MarginType :: integer().
Set a margin to be either numeric or symbolic. The second argument should be one of the ?wxSTC_MARGIN_* constants. Numbers girlie or symbols girlie, pick a side. ๐ข
setMarginWidth
setMarginWidth(This, Margin, PixelWidth) -> ok
when This :: wxStyledTextCtrl(),
Margin :: integer(),
PixelWidth :: integer().
Set the width of a margin to a width expressed in pixels. Yes, pixels again. We love a consistent unit. โจ
setMargins
setMargins(This, Left, Right) -> ok
when This :: wxStyledTextCtrl(),
Left :: integer(),
Right :: integer().
Set the left and right margin in the edit area, measured in pixels. The two-at-once version, for when you already know both numbers and don't want two calls. ๐ซถ
setModEventMask
setModEventMask(This, EventMask) -> ok
when This :: wxStyledTextCtrl(),
EventMask :: integer().
Set which document modification events are sent to the container. This is the "who gets notified when stuff changes" setting โ curate the invite list. ๐จ
also, the input should be a bit list containing one or more of the ?wxSTC_MOD_* constants, the ?wxSTC_PERFORMED_* constants, wxSTC_STARTACTION, wxSTC_MULTILINEUNDOREDO, wxSTC_MULTISTEPUNDOREDO, and wxSTC_LASTSTEPINUNDOREDO. The input can also be wxSTC_MODEVENTMASKALL to indicate that all changes should generate events. โจ bestie, that's the vibe.
setMouseDownCapturesโ slay, this one sets whether the mouse is captured when its button is pressed. ๐ฑ๏ธ
setMouseDownCaptures(This, Captures) -> ok
when
This :: wxStyledTextCtrl(),
Captures :: boolean().
setMouseDwellTimeโ this sets the time the mouse must sit still to generate a mouse dwell event. The input should be a time in milliseconds orwxSTC_TIME_FOREVER. โณ
setMouseDwellTime(This, PeriodMilliseconds) -> ok
when
This :: wxStyledTextCtrl(),
PeriodMilliseconds :: integer().
setPasteConvertEndingsโ enable or disable convert-on-paste for line endings. ๐ฉน
setPasteConvertEndings(This, Convert) -> ok
when
This :: wxStyledTextCtrl(),
Convert :: boolean().
setPrintColourModeโ modify colours when printing for clearer printed text. The input should be one of the?wxSTC_PRINT_*constants. ๐จ๏ธ
setPrintColourMode(This, Mode) -> ok
when
This :: wxStyledTextCtrl(),
Mode :: integer().
setPrintMagnificationโ sets the print magnification added to the point size of each style for printing. ๐
setPrintMagnification(This, Magnification) -> ok
when
This :: wxStyledTextCtrl(),
Magnification :: integer().
setPropertyโ set up a value that may be used by a lexer for some optional feature. ๐งฉ
setProperty(This, Key, Value) -> ok
when
This :: wxStyledTextCtrl(),
Key :: unicode:chardata(),
Value :: unicode:chardata().
setReadOnlyโ set to read only or read write. ๐
setReadOnly(This, ReadOnly) -> ok
when
This :: wxStyledTextCtrl(),
ReadOnly :: boolean().
setSTCCursorโ sets the cursor to one of thewxSTC_CURSOR*values. โจ
setSTCCursor(This, CursorType) -> ok
when
This :: wxStyledTextCtrl(),
CursorType :: integer().
setSTCFocusโ change internal focus flag. ๐ฏ
setSTCFocus(This, Focus) -> ok
when This :: wxStyledTextCtrl(), Focus ::
boolean().
setSavePointโ remember the current position in the undo history as the position at which the document was saved. ๐
setSavePoint(This) -> ok when This :: wxStyledTextCtrl().
setScrollWidthโ sets the document width assumed for scrolling. ๐
setScrollWidth(This, PixelWidth) -> ok
when
This :: wxStyledTextCtrl(),
PixelWidth :: integer().
setSearchFlagsโ set the search flags used bySearchInTarget. The input should be a bit list containing one or more of the?wxSTC_FIND_*constants. ๐
setSearchFlags(This, SearchFlags) -> ok
when
This :: wxStyledTextCtrl(),
SearchFlags :: integer().
setSelAlphaโ set the alpha of the selection. ๐ง
setSelAlpha(This, Alpha) -> ok
when This :: wxStyledTextCtrl(), Alpha ::
integer().
setSelBackgroundโ set the background colour of the main and additional selections and whether to use this setting. ๐จ
setSelBackground(This, UseSetting, Back) -> ok
when
This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Back :: wx:wx_colour().
setSelForegroundโ set the foreground colour of the main and additional selections and whether to use this setting. ๐๏ธ
setSelForeground(This, UseSetting, Fore) -> ok
when
This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Fore :: wx:wx_colour().
setSelectionโ selects the text starting at the first position up to (but not including) the character at the last position. If both parameters are equal to-1, all text in the control is selected. Notice that the insertion point will be moved toFromby this function. See:selectAll/1. โ๏ธ
setSelection(This, From, To) -> ok
when
This :: wxStyledTextCtrl(),
From :: integer(),
To :: integer().
setSelectionEndโ sets the position that ends the selection โ this becomes the caret. ๐
setSelectionEnd(This, Caret) -> ok
when
This :: wxStyledTextCtrl(),
Caret :: integer().
setSelectionModeโ set the selection mode to stream (wxSTC_SEL_STREAM), rectangular (wxSTC_SEL_RECTANGLE/wxSTC_SEL_THIN), or by lines (wxSTC_SEL_LINES). ๐ฆ
setSelectionMode(This, SelectionMode) -> ok
when
This :: wxStyledTextCtrl(),
SelectionMode :: integer().
setSelectionStartโ sets the position that starts the selection โ this becomes the anchor. โ
setSelectionStart(This, Anchor) -> ok
when
This :: wxStyledTextCtrl(),
Anchor :: integer().
setStatusโ change error status โ0= OK. The input should be one of the?wxSTC_STATUS_*constants. ๐ฆ
setStatus(This, Status) -> ok
when This :: wxStyledTextCtrl(), Status :: integer().
setStyleBytesโ set the styles for a segment of the document. ๐จ
setStyleBytes(This, Length) -> integer()
when
This :: wxStyledTextCtrl(),
Length :: integer().
setStylingโ change style from current styling position for length characters to a style and move the current styling position to after this newly styled segment. ๐
setStyling(This, Length, Style) -> ok
when
This :: wxStyledTextCtrl(),
Length :: integer(),
Style :: integer().
setTabIndentsโ sets whether a tab pressed when caret is within indentation indents. โฉ
setTabIndents(This, TabIndents) -> ok
when
This :: wxStyledTextCtrl(),
TabIndents :: boolean().
setTabWidthโ change the visible size of a tab to be a multiple of the width of a space character. ๐
setTabWidth(This, TabWidth) -> ok
when
This :: wxStyledTextCtrl(),
TabWidth :: integer().
setTargetEndโ sets the position that ends the target which is used for updating the document without affecting the scroll position. ๐ฏ
setTargetEnd(This, End) -> ok
when This :: wxStyledTextCtrl(), End :: integer().
setTargetStartโ sets the position that starts the target which is used for updating the document without affecting the scroll position. ๐ฏ
setTargetStart(This, Start) -> ok
when
This :: wxStyledTextCtrl(),
Start :: integer().
setTextโ replace the contents of the document with the argument text. ๐
setText(This, Text) -> ok
when
This :: wxStyledTextCtrl(),
Text :: unicode:chardata().
setTextRawโ replace the contents of the document with the argument text. ๐
setTextRaw(This, Text) -> ok
when This :: wxStyledTextCtrl(), Text :: binary().
setTwoPhaseDrawโ in twoPhaseDraw mode, drawing is performed in two phases: first the background, then the foreground. This avoids chopping off characters that overlap the next run. ๐ญ
setTwoPhaseDraw(This, TwoPhase) -> ok
when
This :: wxStyledTextCtrl(),
TwoPhase :: boolean().
setUndoCollectionโ choose between collecting actions into the undo history and discarding them. โช
setUndoCollection(This, CollectUndo) -> ok
when
This :: wxStyledTextCtrl(),
CollectUndo :: boolean().
setUseHorizontalScrollBarโ show or hide the horizontal scroll bar. โ๏ธ
setUseHorizontalScrollBar(This, Visible) -> ok
when
This :: wxStyledTextCtrl(),
Visible :: boolean().
setUseTabsโ indentation will only use space characters ifuseTabsisfalse, otherwise it will use a combination of tabs and spaces. โ
setUseTabs(This, UseTabs) -> ok
when
This :: wxStyledTextCtrl(), UseTabs ::
boolean().
setUseVerticalScrollBarโ show or hide the vertical scroll bar. โ๏ธ
setUseVerticalScrollBar(This, Visible) -> ok
when
This :: wxStyledTextCtrl(),
Visible :: boolean().
setVScrollBarโ set the vertical scrollbar to use instead of the one that's built-in. ๐๏ธ
setVScrollBar(This, Bar) -> ok
when
This :: wxStyledTextCtrl(),
Bar :: wxScrollBar:wxScrollBar().
setViewEOLโ make the end of line characters visible or invisible. ๐
setViewEOL(This, Visible) -> ok
when
This :: wxStyledTextCtrl(), Visible ::
boolean().
setViewWhiteSpaceโ make white space characters invisible, always visible, or visible outside indentation. The input should be one of the?wxSTC_WS_*constants. โฃ
setViewWhiteSpace(This, ViewWS) -> ok
when
This :: wxStyledTextCtrl(),
ViewWS :: integer().
setVisiblePolicy
setVisiblePolicy(This, VisiblePolicy, VisibleSlop) -> ok
when
This :: wxStyledTextCtrl(),
VisiblePolicy :: integer(),
VisibleSlop :: integer().
okay so this one decides how the display area gets determined when a particular line is about to be moved to by Find, FindNext, GotoLine, etc. ๐ That first argument should be a bit list containing one or more of the ?wxSTC_VISIBLE_* constants. slay.
setWhitespaceBackground
setWhitespaceBackground(This, UseSetting, Back) -> ok
when
This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Back :: wx:wx_colour().
Sets the background colour of all whitespace, and whether to actually use this setting. โจ
setWhitespaceChars
setWhitespaceChars(This, Characters) -> ok
when
This :: wxStyledTextCtrl(),
Characters :: unicode:chardata().
Sets the set of characters that make up whitespace for when you're moving or selecting by word. lowkey important: this should be called after SetWordChars. ๐
setWhitespaceForeground
setWhitespaceForeground(This, UseSetting, Fore) -> ok
when
This :: wxStyledTextCtrl(),
UseSetting :: boolean(),
Fore :: wx:wx_colour().
Sets the foreground colour of all whitespace, and whether to use this setting. ๐ฆ
setWordChars
setWordChars(This, Characters) -> ok
when
This :: wxStyledTextCtrl(),
Characters :: unicode:chardata().
Sets the set of characters making up words for when you're moving or selecting by word. Heads up bestie โ it first sets defaults, just like SetCharsDefault. ๐ธ
setWrapMode
setWrapMode(This, WrapMode) -> ok
when
This :: wxStyledTextCtrl(),
WrapMode :: integer().
Sets whether text is word wrapped or not. The input should be one of the ?wxSTC_WRAP_* constants. ๐
setWrapStartIndent
setWrapStartIndent(This, Indent) -> ok
when
This :: wxStyledTextCtrl(),
Indent :: integer().
Sets the start indent for wrapped lines. ๐ซถ
setWrapVisualFlags
setWrapVisualFlags(This, WrapVisualFlags) -> ok
when
This :: wxStyledTextCtrl(),
WrapVisualFlags :: integer().
Sets the display mode of the visual flags for wrapped lines. The input should be a bit list containing one or more of the ?wxSTC_WRAPVISUALFLAG_* constants. ๐ญ
setWrapVisualFlagsLocation
setWrapVisualFlagsLocation(This, WrapVisualFlagsLocation) -> ok
when
This :: wxStyledTextCtrl(),
WrapVisualFlagsLocation :: integer().
Sets where those visual flags for wrapped lines actually show up. The input should be a bit list containing one or more of the ?wxSTC_WRAPVISUALFLAGLOC_* constants. ๐ฅ
setXCaretPolicy
setXCaretPolicy(This, CaretPolicy, CaretSlop) -> ok
when
This :: wxStyledTextCtrl(),
CaretPolicy :: integer(),
CaretSlop :: integer().
Sets how the caret stays visible when it's going sideways. The exclusion zone is given in pixels. The first argument should be a bit list containing one or more of the ?wxSTC_CARET_* constants. ๐
setYCaretPolicy
setYCaretPolicy(This, CaretPolicy, CaretSlop) -> ok
when
This :: wxStyledTextCtrl(),
CaretPolicy :: integer(),
CaretSlop :: integer().
Sets how the line the caret is on stays visible. This time the exclusion zone is given in lines. The first argument should be a bit list containing one or more of the ?wxSTC_CARET_* constants. ๐
setZoom
setZoom(This, ZoomInPoints) -> ok
when
This :: wxStyledTextCtrl(),
ZoomInPoints :: integer().
Sets the zoom level. This number of points gets added to the size of all the fonts โ positive to magnify, negative to reduce. โญ
showLines
showLines(This, LineStart, LineEnd) -> ok
when
This :: wxStyledTextCtrl(),
LineStart :: integer(),
LineEnd :: integer().
Makes a range of lines visible. boom. there it is. ๐
startRecord
startRecord(This) -> ok
when
This :: wxStyledTextCtrl().
Starts notifying the container of all key presses and commands. ๐
startStyling
startStyling(This, Start) -> ok
when
This :: wxStyledTextCtrl(),
Start :: integer().
Sets the current styling position to Start. ๐
stopRecord
stopRecord(This) -> ok
when
This :: wxStyledTextCtrl().
Stops notifying the container of all key presses and commands. ๐ง
stutteredPageDown
stutteredPageDown(This) -> ok
when
This :: wxStyledTextCtrl().
Moves the caret to the bottom of the page โ or one page down if it's already sitting at the bottom of the page. ๐
stutteredPageDownExtend
stutteredPageDownExtend(This) -> ok
when
This :: wxStyledTextCtrl().
Moves the caret to the bottom of the page โ or one page down if it's already there โ extending the selection to the new caret position. ๐
stutteredPageUp
stutteredPageUp(This) -> ok
when
This :: wxStyledTextCtrl().
Moves the caret to the top of the page โ or one page up if it's already at the top of the page. โจ
stutteredPageUpExtend
stutteredPageUpExtend(This) -> ok
when
This :: wxStyledTextCtrl().
Moves the caret to the top of the page โ or one page up if it's already there โ extending the selection to the new caret position. ๐
styleClearAll
styleClearAll(This) -> ok
when
This :: wxStyledTextCtrl().
Clears all the styles and makes everything equivalent to the global default style. it's giving factory reset โจ
styleResetDefault
styleResetDefault(This) -> ok
when
This :: wxStyledTextCtrl().
Resets the default style back to its state at startup. ๐ฆ
styleSetBackground
styleSetBackground(This, Style, Back) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Back :: wx:wx_colour().
Sets the background colour of a style. ๐ธ
styleSetBold
styleSetBold(This, Style, Bold) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Bold :: boolean().
Sets a style to be bold or not. ๐
styleSetCase
styleSetCase(This, Style, CaseVisible) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
CaseVisible :: integer().
Sets a style to be mixed case, or forces upper or lower case. The second argument should be one of the ?wxSTC_CASE_* constants. ๐ซถ
styleSetCharacterSet
styleSetCharacterSet(This, Style, CharacterSet) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
CharacterSet :: integer().
Sets the character set of the font in a style. It converts the Scintilla character set values to a wxFontEncoding. ๐ญ
styleSetEOLFilled
styleSetEOLFilled(This, Style, EolFilled) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
EolFilled :: boolean().
Sets a style to have its end of line filled โ or not. ๐ฅ
styleSetFaceName
styleSetFaceName(This, Style, FontName) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
FontName :: unicode:chardata().
Sets the font of a style. ๐
styleSetFont
styleSetFont(This, StyleNum, Font) -> ok
when
This :: wxStyledTextCtrl(),
StyleNum :: integer(),
Font :: wxFont:wxFont().
Sets style size, face, bold, italic, and underline attributes from a wxFont's attributes. one call, all the glow-up. ๐
styleSetFontAttr
styleSetFontAttr(This, StyleNum, Size, FaceName, Bold, Italic, Underline,
[Option]) -> ok
when
This :: wxStyledTextCtrl(),
StyleNum :: integer(),
Size :: integer(),
FaceName :: unicode:chardata(),
Bold :: boolean(),
Italic :: boolean(),
Underline :: boolean(),
Option :: {encoding, wx:wx_enum()}.
Sets all the font style attributes at once. โญ
styleSetFontEncoding
styleSetFontEncoding(This, Style, Encoding) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Encoding :: wx:wx_enum().
Sets the font encoding to be used by a style. ๐
styleSetForeground
styleSetForeground(This, Style, Fore) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Fore :: wx:wx_colour().
Sets the foreground colour of a style. ๐
styleSetHotSpot
styleSetHotSpot(This, Style, Hotspot) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Hotspot :: boolean().
Sets a style to be a hotspot, or not. ๐
styleSetItalic
styleSetItalic(This, Style, Italic) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Italic :: boolean().
Sets a style to be italic, or not. ๐ง
styleSetSize
styleSetSize(This, Style, SizePoints) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
SizePoints :: integer().
Set the size of characters of a style. โจ (That was the tail end of the previous one โ she's still iconic, no cap.)
styleSetSpecโ Extract style settings from a spec-string that's built from one or more of the following comma-separated elements:
styleSetSpec(This, StyleNum, Spec) -> ok
when
This :: wxStyledTextCtrl(),
StyleNum :: integer(),
Spec :: unicode:chardata().
boldโ turns on bolditalicโ turns on italicsfore:[name or #RRGGBB]โ sets the foreground colourback:[name or #RRGGBB]โ sets the background colourface:[facename]โ sets the font face name to usesize:[num]โ sets the font size in pointseolโ turns on eol fillingunderlineโ turns on underlining
styleSetUnderlineโ Set a style to be underlined or not.
styleSetUnderline(This, Style, Underline) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Underline :: boolean().
styleSetVisibleโ Set a style to be visible or not.
styleSetVisible(This, Style, Visible) -> ok
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Visible :: boolean().
tabโ If selection is empty or all on one line, replace the selection with a tab character. If more than one line selected, indent the lines.
tab(This) -> ok when This :: wxStyledTextCtrl().
targetFromSelectionโ Make the target range start and end be the same as the selection range start and end.
targetFromSelection(This) -> ok when This :: wxStyledTextCtrl().
textHeightโ Retrieve the height of a particular line of text in pixels.
textHeight(This, Line) -> integer()
when This :: wxStyledTextCtrl(), Line :: integer().
textWidthโ Measure the pixel width of some text in a particular style. Does not handle tab or control characters.
textWidth(This, Style, Text) -> integer()
when
This :: wxStyledTextCtrl(),
Style :: integer(),
Text :: unicode:chardata().
toggleCaretStickyโ Switch between sticky and non-sticky: meant to be bound to a key.
toggleCaretSticky(This) -> ok when This :: wxStyledTextCtrl().
toggleFoldโ Switch a header line between expanded and contracted.
toggleFold(This, Line) -> ok
when This :: wxStyledTextCtrl(), Line :: integer().
undoโ Undo one action in the undo history.
undo(This) -> ok when This :: wxStyledTextCtrl().
upperCaseโ Transform the selection to upper case.
upperCase(This) -> ok when This :: wxStyledTextCtrl().
usePopUpโ Set whether a pop up menu is displayed automatically when the user presses the wrong mouse button on certain areas. The input should be one of the?wxSTC_POPUP_*constants.
usePopUp(This, PopUpMode) -> ok
when
This :: wxStyledTextCtrl(), PopUpMode ::
integer().
Remark: WhenwxContextMenuEventis used to create a custom popup menu, this function should be called withwxSTC_POPUP_NEVER. Otherwise the default menu will be shown instead of the custom one.
userListShowโ Display a list of strings and send notification when user chooses one.
userListShow(This, ListType, ItemList) -> ok
when
This :: wxStyledTextCtrl(),
ListType :: integer(),
ItemList :: unicode:chardata().
vCHomeโ Move caret to before first visible character on line. If already there move to first character on line.
vCHome(This) -> ok when This :: wxStyledTextCtrl().
vCHomeExtendโ LikeVCHomebut extending selection to new caret position.
vCHomeExtend(This) -> ok when This :: wxStyledTextCtrl().
vCHomeRectExtendโ Move caret to before first visible character on line. If already there move to first character on line. In either case, extend rectangular selection to new caret position.
vCHomeRectExtend(This) -> ok when This :: wxStyledTextCtrl().
vCHomeWrapโ LikeVCHomebut when word-wrap is enabled goes first to start of display lineVCHomeDisplay, then behaves likeVCHome.
vCHomeWrap(This) -> ok when This :: wxStyledTextCtrl().
vCHomeWrapExtendโ LikeVCHomeExtendbut when word-wrap is enabled extends first to start of display lineVCHomeDisplayExtend, then behaves likeVCHomeExtend.
vCHomeWrapExtend(This) -> ok when This :: wxStyledTextCtrl().
visibleFromDocLineโ Find the display line of a document line taking hidden lines into account.
visibleFromDocLine(This, DocLine) -> integer()
when
This :: wxStyledTextCtrl(),
DocLine :: integer().
wordEndPositionโ Get position of end of word.
wordEndPosition(This, Pos, OnlyWordCharacters) -> integer()
when
This :: wxStyledTextCtrl(),
Pos :: integer(),
OnlyWordCharacters :: boolean().
wordLeftโ Move caret left one word.
wordLeft(This) -> ok when This :: wxStyledTextCtrl().
wordLeftEndโ Move caret left one word, position cursor at end of word.
wordLeftEnd(This) -> ok when This :: wxStyledTextCtrl().
wordLeftEndExtendโ Move caret left one word, position cursor at end of word, extending selection to new caret position.
wordLeftEndExtend(This) -> ok when This :: wxStyledTextCtrl().
wordLeftExtendโ Move caret left one word extending selection to new caret position.
wordLeftExtend(This) -> ok when This :: wxStyledTextCtrl().
wordPartLeftโ Move to the previous change in capitalisation.
wordPartLeft(This) -> ok when This :: wxStyledTextCtrl().
wordPartLeftExtendโ Move to the previous change in capitalisation extending selection to new caret position.
wordPartLeftExtend(This) -> ok when This :: wxStyledTextCtrl().
wordPartRightโ Move to the change next in capitalisation.
wordPartRight(This) -> ok when This :: wxStyledTextCtrl().
wordPartRightExtendโ Move to the next change in capitalisation extending selection to new caret position.
wordPartRightExtend(This) -> ok when This :: wxStyledTextCtrl().
wordRightโ Move caret right one word.
wordRight(This) -> ok when This :: wxStyledTextCtrl().
wordRightEndโ Move caret right one word, position cursor at end of word.
wordRightEnd(This) -> ok when This :: wxStyledTextCtrl().
wordRightEndExtendโ Move caret right one word, position cursor at end of word, extending selection to new caret position.
wordRightEndExtend(This) -> ok when This :: wxStyledTextCtrl().
wordRightExtendโ Move caret right one word extending selection to new caret position.
wordRightExtend(This) -> ok when This :: wxStyledTextCtrl().
wordStartPositionโ Get position of start of word.
wordStartPosition(This, Pos, OnlyWordCharacters) -> integer()
when
This :: wxStyledTextCtrl(),
Pos :: integer(),
OnlyWordCharacters :: boolean().
wrapCountโ The number of display lines needed to wrap a document line.
wrapCount(This, DocLine) -> integer()
when This :: wxStyledTextCtrl(), DocLine ::
integer().
zoomInโ Magnify the displayed text by increasing the sizes by 1 point.
zoomIn(This) -> ok when This :: wxStyledTextCtrl().
zoomOutโ Make the displayed text smaller by decreasing the sizes by 1 point.
zoomOut(This) -> ok when This :: wxStyledTextCtrl().
This page was brought to you by Ericsson AB, wx 2.6, and the wxStyledTextCtrl(3) man page. The footer's date slot is lowkey empty, but the vibe is timeless. ๐โจ๐ฆ
๐ฆ where this page comes from
- ubuntu stonking: erlang-doc 1:29.0.6+dfsg-1 ยท Apache-2.0
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms