Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Document versioon added
  • Loading branch information
YoannQDQ authored and nyalldawson committed Jan 10, 2023
1 parent da260a7 commit eade013
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
Expand Up @@ -58,17 +58,23 @@ Loads a ``script`` file.
bool isCursorInsideString() const;
%Docstring
Check whether the current cursor position is inside a string or comment

.. versionadded:: 3.30
%End

QString characterBeforeCursor() const;
%Docstring
Returns the character before the cursor, or an empty string if cursor is set at start

.. versionadded:: 3.30
%End


QString characterAfterCursor() const;
%Docstring
Returns the character after the cursor, or an empty string if cursor is set at end

.. versionadded:: 3.30
%End


Expand Down
6 changes: 6 additions & 0 deletions src/gui/codeeditors/qgscodeeditorpython.h
Expand Up @@ -77,16 +77,22 @@ class GUI_EXPORT QgsCodeEditorPython : public QgsCodeEditor

/**
* Check whether the current cursor position is inside a string or comment
*
* \since QGIS 3.30
*/
bool isCursorInsideString() const;

/**
* Returns the character before the cursor, or an empty string if cursor is set at start
*
* \since QGIS 3.30
*/
QString characterBeforeCursor() const;

/**
* Returns the character after the cursor, or an empty string if the cursot is set at end
*
* \since QGIS 3.30
*/
QString characterAfterCursor() const;

Expand Down

0 comments on commit eade013

Please sign in to comment.