eric4.QScintilla.QsciScintillaCompat

Module implementing a compatability interface class to QsciScintilla.

Classes

QsciScintillaCompat Class implementing a compatability interface to QsciScintilla.

Functions

QSCINTILLA_VERSION Module function to return the QScintilla version.


QsciScintillaCompat

Class implementing a compatability interface to QsciScintilla.

This class implements all the functions, that were added to QsciScintilla incrementally. This class ensures compatibility to older versions of QsciScintilla.

Derived from

QsciScintilla

Methods

QsciScintillaCompat Constructor
clearAlternateKeys Protected method to clear the alternate key commands.
clearKeys Protected method to clear the key commands.
clearStyles Public method to set the styles according the selected Qt style.
currentPosition Public method to get the current position.
currentStyle Public method to get the style at the current position.
delete Public method to delete the character to the right of the cursor.
deleteBack Public method to delete the character to the left of the cursor.
deleteLineLeft Public method to delete the line to the left of the cursor.
deleteLineRight Public method to delete the line to the right of the cursor.
deleteWordLeft Public method to delete the word to the left of the cursor.
deleteWordRight Public method to delete the word to the right of the cursor.
editorCommand Public method to perform a simple editor command.
extendSelectionLeft Public method to extend the selection one character to the left.
extendSelectionRight Public method to extend the selection one character to the right.
extendSelectionToBOL Public method to extend the selection to the beginning of the line.
extendSelectionToEOL Public method to extend the selection to the end of the line.
extendSelectionWordLeft Public method to extend the selection one word to the left.
extendSelectionWordRight Public method to extend the selection one word to the right.
getZoom Public method used to retrieve the current zoom factor.
lineAt Public method to calculate the line at a position.
monospacedStyles Public method to set the current style to be monospaced.
moveCursorLeft Public method to move the cursor left.
moveCursorRight Public method to move the cursor right.
moveCursorToEOL Public method to move the cursor to the end of line.
moveCursorWordLeft Public method to move the cursor left one word.
moveCursorWordRight Public method to move the cursor right one word.
scrollVertical Public method to scroll the text area.
setLexer Public method to set the lexer.
styleAt Public method to get the style at a position in the text.
zoomIn Public method used to increase the zoom factor.
zoomOut Public method used to decrease the zoom factor.
zoomTo Public method used to zoom to a specific zoom factor.

QsciScintillaCompat (Constructor)

QsciScintillaCompat(parent = None)

Constructor

parent
parent widget (QWidget)
name
name of this instance (string or QString)
flags
window flags

QsciScintillaCompat.clearAlternateKeys

clearAlternateKeys()

Protected method to clear the alternate key commands.

QsciScintillaCompat.clearKeys

clearKeys()

Protected method to clear the key commands.

QsciScintillaCompat.clearStyles

clearStyles()

Public method to set the styles according the selected Qt style.

QsciScintillaCompat.currentPosition

currentPosition()

Public method to get the current position.

Returns:
absolute position of the cursor (integer)

QsciScintillaCompat.currentStyle

currentStyle()

Public method to get the style at the current position.

Returns:
style at the current position (integer)

QsciScintillaCompat.delete

delete()

Public method to delete the character to the right of the cursor.

QsciScintillaCompat.deleteBack

deleteBack()

Public method to delete the character to the left of the cursor.

QsciScintillaCompat.deleteLineLeft

deleteLineLeft()

Public method to delete the line to the left of the cursor.

QsciScintillaCompat.deleteLineRight

deleteLineRight()

Public method to delete the line to the right of the cursor.

QsciScintillaCompat.deleteWordLeft

deleteWordLeft()

Public method to delete the word to the left of the cursor.

QsciScintillaCompat.deleteWordRight

deleteWordRight()

Public method to delete the word to the right of the cursor.

QsciScintillaCompat.editorCommand

editorCommand(cmd)

Public method to perform a simple editor command.

cmd
the scintilla command to be performed

QsciScintillaCompat.extendSelectionLeft

extendSelectionLeft()

Public method to extend the selection one character to the left.

QsciScintillaCompat.extendSelectionRight

extendSelectionRight()

Public method to extend the selection one character to the right.

QsciScintillaCompat.extendSelectionToBOL

extendSelectionToBOL()

Public method to extend the selection to the beginning of the line.

QsciScintillaCompat.extendSelectionToEOL

extendSelectionToEOL()

Public method to extend the selection to the end of the line.

QsciScintillaCompat.extendSelectionWordLeft

extendSelectionWordLeft()

Public method to extend the selection one word to the left.

QsciScintillaCompat.extendSelectionWordRight

extendSelectionWordRight()

Public method to extend the selection one word to the right.

QsciScintillaCompat.getZoom

getZoom()

Public method used to retrieve the current zoom factor.

Returns:
zoom factor (int)

QsciScintillaCompat.lineAt

lineAt(pos)

Public method to calculate the line at a position.

This variant is able to calculate the line for positions in the margins and for empty lines.

pos
position to calculate the line for (QPoint)
Returns:
linenumber at position or -1, if there is no line at pos (integer, zero based)

QsciScintillaCompat.monospacedStyles

monospacedStyles(font)

Public method to set the current style to be monospaced.

font
font to be used (QFont)

QsciScintillaCompat.moveCursorLeft

moveCursorLeft()

Public method to move the cursor left.

QsciScintillaCompat.moveCursorRight

moveCursorRight()

Public method to move the cursor right.

QsciScintillaCompat.moveCursorToEOL

moveCursorToEOL()

Public method to move the cursor to the end of line.

QsciScintillaCompat.moveCursorWordLeft

moveCursorWordLeft()

Public method to move the cursor left one word.

QsciScintillaCompat.moveCursorWordRight

moveCursorWordRight()

Public method to move the cursor right one word.

QsciScintillaCompat.scrollVertical

scrollVertical(lines)

Public method to scroll the text area.

lines
number of lines to scroll (negative scrolls up, positive scrolls down) (integer)

QsciScintillaCompat.setLexer

setLexer(lex = None)

Public method to set the lexer.

lex
the lexer to be set or None to reset it.

QsciScintillaCompat.styleAt

styleAt(pos)

Public method to get the style at a position in the text.

pos
position in the text (integer)
Returns:
style at the requested position or 0 if the position is negative or past the end of the document (integer)

QsciScintillaCompat.zoomIn

zoomIn(zoom = 1)

Public method used to increase the zoom factor.

zoom
zoom factor increment

QsciScintillaCompat.zoomOut

zoomOut(zoom = 1)

Public method used to decrease the zoom factor.

zoom
zoom factor decrement

QsciScintillaCompat.zoomTo

zoomTo(zoom)

Public method used to zoom to a specific zoom factor.

zoom
zoom factor

Up


QSCINTILLA_VERSION

QSCINTILLA_VERSION()

Module function to return the QScintilla version.

If the installed QScintilla is a snapshot version, then assume it is of the latest release and return a version number of 0x99999.

Returns:
QScintilla version (integer)
Up