summaryrefslogtreecommitdiffstats
path: root/SQLiteStudio3/guiSQLiteStudio/sqleditor.h
diff options
context:
space:
mode:
authorLibravatarUnit 193 <unit193@ubuntu.com>2016-06-13 18:42:42 -0400
committerLibravatarUnit 193 <unit193@ubuntu.com>2016-06-13 18:42:42 -0400
commit5d9314f134ddd3dc4c853e398ac90ba247fb2e4f (patch)
tree5c457fc188036988d7abd29a3eb09931e406510f /SQLiteStudio3/guiSQLiteStudio/sqleditor.h
parent8e640722c62692818ab840d50b3758f89a41a54e (diff)
Imported Upstream version 3.1.0upstream/3.1.0
Diffstat (limited to 'SQLiteStudio3/guiSQLiteStudio/sqleditor.h')
-rw-r--r--SQLiteStudio3/guiSQLiteStudio/sqleditor.h6
1 files changed, 5 insertions, 1 deletions
diff --git a/SQLiteStudio3/guiSQLiteStudio/sqleditor.h b/SQLiteStudio3/guiSQLiteStudio/sqleditor.h
index 28fbb39..1c98682 100644
--- a/SQLiteStudio3/guiSQLiteStudio/sqleditor.h
+++ b/SQLiteStudio3/guiSQLiteStudio/sqleditor.h
@@ -40,6 +40,7 @@ CFG_KEY_LIST(SqlEditor, QObject::tr("SQL editor input field"),
CFG_KEY_ENTRY(MOVE_BLOCK_UP, Qt::ALT + Qt::Key_Up, QObject::tr("Move selected block of text one line up"))
CFG_KEY_ENTRY(COPY_BLOCK_DOWN, Qt::ALT + Qt::CTRL + Qt::Key_Down, QObject::tr("Copy selected block of text and paste it a line below"))
CFG_KEY_ENTRY(COPY_BLOCK_UP, Qt::ALT + Qt::CTRL + Qt::Key_Up, QObject::tr("Copy selected block of text and paste it a line above"))
+ CFG_KEY_ENTRY(TOGGLE_COMMENT, Qt::CTRL + Qt::Key_Slash, QObject::tr("Toggle comment"))
)
class GUI_API_EXPORT SqlEditor : public QPlainTextEdit, public ExtActionContainer
@@ -70,7 +71,8 @@ class GUI_API_EXPORT SqlEditor : public QPlainTextEdit, public ExtActionContaine
FIND,
FIND_NEXT,
FIND_PREV,
- REPLACE
+ REPLACE,
+ TOGGLE_COMMENT
};
enum ToolBar
@@ -190,6 +192,7 @@ class GUI_API_EXPORT SqlEditor : public QPlainTextEdit, public ExtActionContaine
void handleValidObjectCursor(const QPoint& point);
bool handleValidObjectContextMenu(const QPoint& pos);
void saveToFile(const QString& fileName);
+ void toggleLineCommentForLine(const QTextBlock& block);
SqliteSyntaxHighlighter* highlighter = nullptr;
QMenu* contextMenu = nullptr;
@@ -280,6 +283,7 @@ class GUI_API_EXPORT SqlEditor : public QPlainTextEdit, public ExtActionContaine
void reachedEnd();
void changeFont(const QVariant& font);
void configModified();
+ void toggleComment();
signals:
void errorsChecked(bool haveErrors);