Mercurial > hg > octave-nkf
diff libgui/src/m-editor/file-editor-tab.h @ 16731:01d523d5f796
add help for word at mouse or text cursor to the editors context menu
* octave-qscintilla.h: new class derived from qsciscintilla to get acces to the
editors context menu
* octave-qscxintilla.cc(contextMenuEvent): create standard context menu
and add entry for calling help on current word at cursor
(contextmenu_help): handler for the new menu entry
* libgui/src/module.mk: add new files octave_qscintilla.cc/.h
* file-editor-tab.cc(constructor): _edit_area is of class octave_qscintilla,
connect the signal of this class for command execution
(execute_command_in_terminal): slot for signal connected in contructor
* file-editor-tab.h: new slot for executing a command in terminal, _edit_area
is of new class octave_qscintilla
author | Torsten <ttl@justmail.de> |
---|---|
date | Fri, 07 Jun 2013 23:13:48 +0200 |
parents | 0f6f14e3ac6a |
children | 811019b9ef57 |
line wrap: on
line diff
--- a/libgui/src/m-editor/file-editor-tab.h +++ b/libgui/src/m-editor/file-editor-tab.h @@ -28,10 +28,10 @@ #include <QFileSystemWatcher> #include <QSettings> #include <QFileInfo> -#include <Qsci/qsciscintilla.h> #include <Qsci/qsciapis.h> #include "find-dialog.h" +#include "octave-qscintilla.h" class file_editor; @@ -103,6 +103,8 @@ void file_has_changed (const QString& fileName); + void execute_command_in_terminal (const QString& command); + signals: void file_name_changed (const QString& fileName, const QString& toolTip); @@ -113,6 +115,7 @@ void editor_check_conflict_save (const QString& saveFileName, bool remove_on_success); void run_file_signal (const QFileInfo& info); + void execute_command_in_terminal_signal (const QString&); protected: @@ -183,7 +186,7 @@ void remove_all_breakpoints_callback (const bp_info& info); void center_current_line (); - QsciScintilla *_edit_area; + octave_qscintilla *_edit_area; QString _file_name; QString _file_name_short;