#include <qextscintilla.h>
Inherits QextScintillaBase.
QextScintilla implements methods, signals and slots similar to those found in other Qt editor classes. It also provides a higher level interface to features specific to Scintilla such as syntax styling, call tips, auto-indenting and auto-completion than that provided by QextScintillaBase.
The API is modelled on QTextEdit - a method of the same name should behave in the same way.
|
|
This enum defines the different sources for auto-completion lists.
|
|
This enum defines the different brace matching modes. The character pairs {}, [] and () are treated as braces. The Python lexer will also match a : with the end of the corresponding indented block. |
|
This enum defines the different end-of-line modes.
|
|
This enum defines the different styles for the folding margin.
|
|
This enum defines the different pre-defined marker symbols.
|
|
This enum defines the different whitespace visibility modes. When whitespace is visible spaces are displayed as small centred dots and tabs are displayed as light arrows pointing to the right. |
|
This enum defines the different line wrap modes.
|
|
Construct an empty QextScintilla with parent parent, name name, and widget flags f. |
|
Destroys the QextScintilla instance.
|
|
Returns TRUE if auto-completion lists are case sensitive.
|
|
Returns TRUE if the rest of the word to the right of the current cursor is removed when an item from an auto-completion list is selected.
|
|
Returns TRUE if the only item in an auto-completion list with a single entry is automatically used and the list not displayed.
|
|
Returns the current source for the auto-completion list when it is being displayed automatically as the user types.
|
|
Returns the current threshold for the automatic display of the auto-completion list as the user types.
|
|
Returns TRUE if auto-indentation is enabled.
|
|
Returns TRUE if the backspace key unindents a line instead of deleting a character. The default is FALSE.
|
|
Mark the beginning of a sequence of actions that can be undone by a single call to undo().
|
|
Returns the brace matching mode.
|
|
Returns the maximum number of call tips that are displayed.
|
|
Clear all registered images.
|
|
All the lines of the text have their end-of-lines converted to mode mode.
|
|
Returns the attached document.
|
|
Mark the end of a sequence of actions that can be undone by a single call to undo().
|
|
Returns the end-of-line mode.
|
|
Returns the visibility of end-of-lines.
|
|
Find the next occurrence of the string expr and return TRUE if expr was found, otherwise returns FALSE. If expr is found it becomes the current selection. If re is TRUE then expr is interpreted as a regular expression rather than a simple string. If cs is TRUE then the search is case sensitive. If wo is TRUE then the search looks for whole word matches only, otherwise it searches for any matching text. If wrap is TRUE then the search wraps around the end of the text. If forward is TRUE (the default) then the search is forward from the starting position to the end of the text, otherwise it is backwards to the beginning of the text. If either line or index are negative (the default) then the search begins from the current cursor position. Otherwise the search begins at position index of line line.
|
|
Find the next occurence of the string found using findFirst().
|
|
Returns the current folding style.
|
|
Sets *line and *index to the line and index of the cursor.
|
|
If there is a selection, *lineFrom is set to the line number in which the selection begins and *lineTo is set to the line number in which the selection ends. (They could be the same.) *indexFrom is set to the index at which the selection begins within *lineFrom, and *indexTo is set to the index at which the selection ends within *lineTo. If there is no selection, *lineFrom, *indexFrom, *lineTo and *indexTo are all set to -1.
|
|
Returns TRUE if some text is selected.
|
|
Returns the number of characters that line line is indented by.
|
|
Returns TRUE if the display of indentation guides is enabled.
|
|
Returns TRUE if indentations are created using tabs and spaces, rather than just spaces. The default is TRUE.
|
|
Returns the indentation width in characters. The default is 0 which means that the value returned by tabWidth() is actually used.
|
|
Returns TRUE if the text has been modified.
|
|
Returns TRUE if the text edit is read-only.
|
|
Returns TRUE if there is something that can be redone.
|
|
Returns TRUE if there is something that can be undone.
|
|
Returns TRUE if text is interpreted as being UTF8 encoded. The default is to interpret the text as Latin1 encoded.
|
|
Returns the line which is at position pos or -1 if there is no line at that position. |
|
Returns the length of line line or -1 if there is no such line.
|
|
Returns the number of lines of text.
|
|
Returns the length of the text edit's text.
|
|
Returns TRUE if line numbers are enabled for margin margin.
|
|
Returns the marker mask of margin margin.
|
|
Returns TRUE if margin margin is sensitive to mouse clicks.
|
|
Returns the width in pixels of margin margin.
|
|
Define a marker using the symbol sym with the marker number mnr. If mnr is -1 then the marker number is automatically allocated. The marker number is returned or -1 if the marker number was already allocated or too many markers have been defined. Markers are small geometric symbols and character used, for example, to indicate the current line or, in debuggers, to indicate breakpoints. If a margin has a width of 0 then its markers are not drawn, but their background colours affect the background colour of the corresponding line of text. There may be up to 32 markers defined and each line of text has a set of these markers associated with it. Markers are drawn according to their numerical identifier. Markers try to move with their text by tracking where the start of their line moves to. For example, when a line is deleted its markers are added to previous line's markers. Each marker is identified by a marker number. Each instance of a marker is identified by a marker handle. |
|
Define a marker using the character ch with the marker number mnr. If mnr is -1 then the marker number is automatically allocated. The marker number is returned or -1 if the marker number was already allocated or too many markers have been defined. |
|
Define a marker using a copy of the pixmap pm with the marker number mnr. If mnr is -1 then the marker number is automatically allocated. The marker number is returned or -1 if the marker number was already allocated or too many markers have been defined. |
|
Add a marker number mnr to line number linenr. A handle for the marker is returned which can be used to track the marker's position, or -1 if the mnr was invalid.
|
|
Returns the 32 bit mask of marker numbers at line number linenr.
|
|
Delete all markers with the marker number mnr in the line linenr. If mnr is -1 then delete all markers from line linenr.
|
|
Delete the all markers with the marker number mnr. If mnr is -1 then delete all markers.
|
|
Delete the the marker instance with the marker handle mhandle.
|
|
Return the line number that contains the marker instance with the marker handle mhandle. |
|
Return the number of the next line to contain at least one marker from a 32 bit mask of markers. linenr is the line number to start the search from. mask is the mask of markers to search for.
|
|
Return the number of the previous line to contain at least one marker from a 32 bit mask of markers. linenr is the line number to start the search from. mask is the mask of markers to search for.
|
|
Recolours the document between the start and end positions. start defaults to the start of the document and end defaults to the end of the document. |
|
Register an image pm with ID id. Registered images can be displayed in auto-completion lists.
|
|
Replace the current selection, set by a previous call to findFirst() or findNext(), with replaceStr.
|
|
Reset the fold margin colours to their defaults.
|
|
The fold margin may be drawn as a one pixel sized checkerboard pattern of two colours, fore and back.
|
|
Sets the APIs used for auto-completion to apis. If apis is 0 then any existing APIs are removed.
|
|
A fill-up character is one that, when entered while an auto-completion list is being displayed, causes the currently selected item from the list to be added to the text followed by the fill-up character. fillups is the set of fill-up characters. The default is that no fill-up characters are set. |
|
Sets the APIs used for call tips to apis. If apis is 0 then then call tips are disabled.
|
|
Set the background colour of call tips to col. The default is white. |
|
Set the foreground colour of call tips to col. The default is mid-gray. |
|
Set the highlighted colour of call tip text to col. The default is dark blue. |
|
Set the maximum number of call tips that are displayed to nr. If the maximum number is 0 then all applicable call tips are displayed. If the maximum number is -1 then one call tip will be displayed with up and down arrows that allow the use to scroll through the full list. The default is -1.
|
|
Attach the document document, replacing the currently attached document.
|
|
Set the background colour of marker mnr to col. If mnr is -1 then the colour of all markers is set. The default is white.
|
|
Set the foreground colour of marker mnr to col. If mnr is -1 then the colour of all markers is set. The default is black.
|
|
Set the background colour used to display matched braces to col. The default is white.
|
|
Set the foreground colour used to display matched braces to col. The default is red.
|
|
Set the background colour used to display unmatched braces to col. The default is white.
|
|
Set the foreground colour used to display unmatched braces to col. The default is blue.
|
|
Returns the selected text or an empty string if there is no currently selected text.
|
|
The standard command set is returned.
|
|
Returns TRUE if the tab key indents a line instead of inserting a tab character. The default is TRUE.
|
|
Returns the tab width in characters. The default is 8.
|
|
Returns the text edit's text.
|
|
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Returns the text of line line.
|
|
Returns the visibility of whitespace.
|
|
Appends the text text to the end of the text edit. Note that the undo/redo history is cleared by this function. |
|
Display an auto-completion list based on any installed APIs and the characters immediately to the left of the cursor. If there are no significant characters to the left of the cursor, then the list is still displayed.
|
|
Display an auto-completion list based on the current contents of the document and the characters immediately to the left of the cursor. If there are no significant characters to the left of the cursor, then the list is not displayed.
|
|
Display a call tip based on the the characters immediately to the left of the cursor. |
|
Deletes all the text in the text edit.
|
|
Copies any selected text to the clipboard.
|
|
Copies any selected text to the clipboard and then deletes the text.
|
|
Ensures that the cursor is visible.
|
|
Ensures that the line number line is visible.
|
|
If any lines are currently folded then they are all unfolded. Otherwise all lines are folded. This has the same effect as clicking in the fold margin with the shift and control keys pressed. |
|
If the line line is folded then it is unfolded. Otherwise it is folded. This has the same effect as clicking in the fold margin. |
|
Increases the indentation of line line by an indentation width.
|
|
Insert the text text in the line line at the position index. |
|
If the cursor is either side of a brace character then move it to the position of the corresponding brace. |
|
Pastes any text from the clipboard into the text edit at the current cursor position.
|
|
Redo the last change or sequence of changes.
|
|
Removes any selected text.
|
|
If select is TRUE (the default) then all the text is selected. If select is FALSE then any currently selected text is deselected. |
|
If the cursor is either side of a brace character then move it to the position of the corresponding brace and select the text between the braces. |
|
If cs is TRUE then auto-completion lists are case sensitive. The default is TRUE.
|
|
If replace is TRUE then when an item from an auto-completion list is selected, the rest of the word to the right of the current cursor is removed. The default is FALSE.
|
|
If single is TRUE then when there is only a single entry in an auto-completion list it is automatically used and the list is not displayed. This only has an effect when auto-completion is explicitly requested (using autoCompleteFromAPIs() and autoCompleteFromDocument()) and has no effect when auto-completion is triggered as the user types. The default is FALSE.
|
|
Sets the source for the auto-completion list when it is being displayed automatically as the user types to source. The default is AcsDocument.
|
|
Sets the threshold for the automatic display of the auto-completion list as the user types to thresh. The threshold is the number of characters that the user must type before the list is displayed. If the threshold is less than or equal to 0 then the list is disabled. The default is -1.
|
|
If autoindent is TRUE then auto-indentation is enabled. The default is FALSE.
|
|
Sets the brace matching mode to bm. The default is NoBraceMatching.
|
|
If deindent is TRUE then the backspace key will unindent a line rather then delete a character.
|
|
Sets the foreground colour of the caret to col.
|
|
Sets the background colour of the line containing the caret to col.
|
|
Enables or disables, according to enable, the background color of the line containing the caret.
|
|
Sets the width of the caret to width pixels. A width of 0 makes the caret invisible. |
|
Sets the cursor to the line line at the position index.
|
|
Sets the end-of-line mode to mode. The default is the platform's natural mode.
|
|
If visible is TRUE then end-of-lines are made visible. The default is that they are invisible.
|
|
Sets the folding style for margin 2 to fold. The default is NoFoldStyle (ie. folding is disabled).
|
|
Sets the indentation of line to indentation characters.
|
|
Enables or disables, according to enable, this display of indentation guides.
|
|
Set the background colour of indentation guides to col.
|
|
Set the foreground colour of indentation guides to col.
|
|
If tabs is TRUE then indentations are created using tabs and spaces, rather than just spaces.
|
|
Sets the indentation width to width characters. If width is 0 then the value returned by tabWidth() is used.
|
|
Sets the specific language lexer used to style text to lex. If lex is 0 then syntax styling is disabled. |
|
Set the background colour of all margins to col. The default is a gray.
|
|
Set the font used in all margins to f.
|
|
Set the foreground colour of all margins to col. The default is black.
|
|
Enables or disables, according to lnrs, the display of line numbers in margin margin.
|
|
Sets the marker mask of margin margin to mask. Only those markers whose bit is set in the mask are displayed in the margin.
|
|
Enables or disables, according to sens, the sensitivity of margin margin to mouse clicks. If the user clicks in a sensitive margin the marginClicked() signal is emitted.
|
|
Sets the width of margin margin to width pixels. If the width of a margin is 0 then it is not displayed.
|
|
Sets the width of margin margin so that it is wide enough to display s in the current margin font.
|
|
Sets the modified state of the text edit to m. Note that it is only possible to clear the modified state (where m is FALSE). Attempts to set the modified state (where m is TRUE) are ignored.
|
|
Sets the read-only state of the text edit to ro.
|
|
Sets the selection which starts at position indexFrom in line lineFrom and ends at position indexTo in line lineTo. The cursor is moved to the end of the selection.
|
|
Sets the background colour of selected text to col.
|
|
Sets the foreground colour of selected text to col.
|
|
If indent is TRUE then the tab key will indent a line rather then insert a tab character.
|
|
Sets the tab width to width characters.
|
|
Replaces all of the current text with text. Note that the undo/redo history is cleared by this function.
|
|
Sets the current text encoding. If cp is TRUE then UTF8 is used, otherwise Latin1 is used.
|
|
Sets the visibility of whitespace to mode mode. The default is that whitespace is invisible.
|
|
Undo the last change or sequence of changes. Scintilla has multiple level undo and redo. It will continue to record undoable actions until memory runs out. Sequences of typing or deleting are compressed into single actions to make it easier to undo and redo at a sensible level of detail. Sequences of actions can be combined into actions that are undone as a unit. These sequences occur between calls to beginUndoAction() and endUndoAction(). These sequences can be nested and only the top level sequences are undone as units.
|
|
Decreases the indentation of line line by an indentation width.
|
|
Zooms in on the text by by making the base font size range points larger and recalculating all font sizes.
|
|
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Zooms in on the text by by making the base font size one point larger and recalculating all font sizes. |
|
Zooms out on the text by by making the base font size range points smaller and recalculating all font sizes.
|
|
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts. Zooms out on the text by by making the base font size one point larger and recalculating all font sizes. |
|
Zooms the text by making the base font size size points and recalculating all font sizes.
|
|
This signal is emitted whenever the cursor position changes. line contains the line number and pos contains the character position within the line. |
|
This signal is emitted whenever text is selected or de-selected. yes is TRUE if text has been selected and FALSE if text has been deselected. If yes is TRUE then copy() can be used to copy the selection to the clipboard. If yes is FALSE then copy() does nothing.
|
|
This signal is emitted whenever the user clicks on a sensitive margin. margin is the margin. line is the number of the line where the user clicked. state is the state of the modifier keys (ShiftButton, ControlButton and AltButton) when the user clicked.
|
|
This signal is emitted whenever the user attempts to modify read-only text.
|
|
This signal is emitted whenever the modification state of the text changes. m is TRUE if the text has been modified.
|
|
This signal is emitted whenever the selection changes.
|
|
This signal is emitted whenever the text in the text edit changes.
|