annotate libgui/src/gui-preferences-sc.h @ 28131:27c99ff83b99 stable

change default shortcut for previous widget * gui-preferences-sc.h: update related symbolic constant (bug #57875)
author Torsten Lilge <ttl-octave@mailbox.org>
date Sat, 22 Feb 2020 14:50:05 +0100
parents 8dc5b36f1245
children d8089b13d4d7 0a5b15007766
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
27923
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
1 ////////////////////////////////////////////////////////////////////////
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
2 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
3 // Copyright (C) 2017-2020 The Octave Project Developers
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
4 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
5 // See the file COPYRIGHT.md in the top-level directory of this
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
6 // distribution or <https://octave.org/copyright/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
7 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
8 // This file is part of Octave.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
9 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
10 // Octave is free software: you can redistribute it and/or modify it
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
11 // under the terms of the GNU General Public License as published by
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
12 // the Free Software Foundation, either version 3 of the License, or
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
13 // (at your option) any later version.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
14 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
15 // Octave is distributed in the hope that it will be useful, but
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
16 // WITHOUT ANY WARRANTY; without even the implied warranty of
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
18 // GNU General Public License for more details.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
19 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
20 // You should have received a copy of the GNU General Public License
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
21 // along with Octave; see the file COPYING. If not, see
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
22 // <https://www.gnu.org/licenses/>.
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
23 //
bd51beb6205e update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents: 27919
diff changeset
24 ////////////////////////////////////////////////////////////////////////
27583
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
25
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
26 #if ! defined (octave_gui_preferences_sc_h)
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
27 #define octave_gui_preferences_sc_h 1
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
28
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
29 #include "gui-preferences.h"
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
30
27724
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
31 // Define shortcuts
27583
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
32
27724
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
33 // The shortcut's default values are given as QKeySequence for being able
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
34 // to use platform independent standard keys (QKeySequence::StandardKey).
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
35 // However, converting key sequences into QVariants does not seem to be
27929
265b386f8b20 maint: Use two spaces between sentences in code comments.
Rik <rik@octave.org>
parents: 27923
diff changeset
36 // revertible. In addition the related string (which is saved in the
27724
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
37 // preferences file) can not be determined during compile time since the
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
38 // result depends on the platform (at least in case of standard key sequences
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
39 // like, e.g., QKeySequence::Copy)
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
40 // Therefore, these prefs for key sequences require a separate constant
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
41 // definition and value method for the settings class.
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
42
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
43 #if defined (Q_OS_MAC)
27935
f1844e33f621 maint: Use Octave coding conventions in libgui/ directory.
Rik <rik@octave.org>
parents: 27929
diff changeset
44 // Use CMD key as an equivalent of Ctrl key on other platforms
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
45 const Qt::KeyboardModifier CTRL = Qt::MetaModifier;
27935
f1844e33f621 maint: Use Octave coding conventions in libgui/ directory.
Rik <rik@octave.org>
parents: 27929
diff changeset
46 // Some of octave default shortcuts on windows/linux are already defined
f1844e33f621 maint: Use Octave coding conventions in libgui/ directory.
Rik <rik@octave.org>
parents: 27929
diff changeset
47 // as system wide shortcuts on Mac Os X (almost all Function keys).
f1844e33f621 maint: Use Octave coding conventions in libgui/ directory.
Rik <rik@octave.org>
parents: 27929
diff changeset
48 // Prefix those with Option (Alt) modifier to avoid conflicts.
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
49 const int PRE = Qt::AltModifier;
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
50 #else
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
51 const Qt::KeyboardModifier CTRL = Qt::ControlModifier;
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
52 const int PRE = Qt::NoModifier;
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
53 #endif
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
54
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
55 const Qt::KeyboardModifiers CTRL_SHIFT = CTRL | Qt::ShiftModifier;
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
56 const Qt::KeyboardModifiers CTRL_ALT = CTRL | Qt::AltModifier;
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
57
27937
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
58 // Shortcuts not related to specific Menus
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
59
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
60 // Dock widgets
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
61 const QString sc_dock_widget ("dock_widget");
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
62 const sc_pref sc_dock_widget_dock (sc_dock_widget + ":dock", CTRL_ALT + Qt::Key_D);
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
63 const sc_pref sc_dock_widget_close (sc_dock_widget + ":close", CTRL_ALT + Qt::Key_C);
8dc5b36f1245 include new undock/dock actions into the shortcut manager
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27935
diff changeset
64
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
65 // Main window menu
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
66
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
67 // file
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
68 const QString sc_main_file ("main_file");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
69 const sc_pref sc_main_file_new_file (sc_main_file + ":new_file", QKeySequence::New);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
70 const sc_pref sc_main_file_new_function (sc_main_file + ":new_function", CTRL_SHIFT + Qt::Key_N);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
71 const sc_pref sc_main_file_new_figure (sc_main_file + ":new_figure", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
72 const sc_pref sc_main_file_open_file (sc_main_file + ":open_file", QKeySequence::Open);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
73 const sc_pref sc_main_file_load_workspace (sc_main_file + ":load_workspace", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
74 const sc_pref sc_main_file_save_workspace (sc_main_file + ":save_workspace", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
75 const sc_pref sc_main_file_exit (sc_main_file + ":exit", QKeySequence::Quit);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
76
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
77 // edit
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
78 const QString sc_main_edit ("main_edit");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
79 const sc_pref sc_main_edit_copy (sc_main_edit + ":copy", QKeySequence::Copy);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
80 const sc_pref sc_main_edit_paste (sc_main_edit + ":paste", QKeySequence::Paste);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
81 const sc_pref sc_main_edit_undo (sc_main_edit + ":undo", QKeySequence::Undo);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
82 const sc_pref sc_main_edit_select_all (sc_main_edit + ":select_all", QKeySequence::SelectAll);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
83 const sc_pref sc_main_edit_clear_clipboard (sc_main_edit + ":clear_clipboard", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
84 const sc_pref sc_main_edit_find_in_files (sc_main_edit + ":find_in_files", CTRL_SHIFT + Qt::Key_F);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
85 const sc_pref sc_main_edit_clear_command_window (sc_main_edit + ":clear_command_window", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
86 const sc_pref sc_main_edit_clear_history (sc_main_edit + ":clear_history", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
87 const sc_pref sc_main_edit_clear_workspace (sc_main_edit + ":clear_workspace", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
88 const sc_pref sc_main_edit_set_path (sc_main_edit + ":set_path", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
89 const sc_pref sc_main_edit_preferences (sc_main_edit + ":preferences", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
90
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
91 // debug
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
92 const QString sc_main_debug ("main_debug");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
93 const sc_pref sc_main_debug_step_over (sc_main_debug + ":step_over", PRE + Qt::Key_F10);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
94 const sc_pref sc_main_debug_step_into (sc_main_debug + ":step_into", PRE + Qt::Key_F11);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
95 const sc_pref sc_main_debug_step_out (sc_main_debug + ":step_out", PRE + Qt::ShiftModifier + Qt::Key_F11);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
96 const sc_pref sc_main_debug_continue (sc_main_debug + ":continue", PRE + Qt::Key_F5);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
97 const sc_pref sc_main_debug_quit (sc_main_debug + ":quit", PRE + Qt::ShiftModifier + Qt::Key_F5);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
98
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
99 // window
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
100 const QString sc_main_window ("main_window");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
101 const sc_pref sc_main_window_show_command (sc_main_window + ":show_command", PRE + CTRL_SHIFT + Qt::Key_0);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
102 const sc_pref sc_main_window_show_history (sc_main_window + ":show_history", PRE + CTRL_SHIFT + Qt::Key_1);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
103 const sc_pref sc_main_window_show_file_browser (sc_main_window + ":show_file_browser", PRE + CTRL_SHIFT + Qt::Key_2);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
104 const sc_pref sc_main_window_show_workspace (sc_main_window + ":show_workspace", PRE + CTRL_SHIFT + Qt::Key_3);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
105 const sc_pref sc_main_window_show_editor (sc_main_window + ":show_editor", PRE + CTRL_SHIFT + Qt::Key_4);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
106 const sc_pref sc_main_window_show_doc (sc_main_window + ":show_doc", PRE + CTRL_SHIFT + Qt::Key_5);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
107 const sc_pref sc_main_window_show_variable_editor (sc_main_window + ":show_variable_editor", PRE + CTRL_SHIFT + Qt::Key_6);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
108 const sc_pref sc_main_window_command (sc_main_window + ":command", PRE + CTRL + Qt::Key_0);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
109 const sc_pref sc_main_window_history (sc_main_window + ":history", PRE + CTRL + Qt::Key_1);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
110 const sc_pref sc_main_window_file_browser (sc_main_window + ":file_browser", PRE + CTRL + Qt::Key_2);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
111 const sc_pref sc_main_window_workspace (sc_main_window + ":workspace", PRE + CTRL + Qt::Key_3);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
112 const sc_pref sc_main_window_editor (sc_main_window + ":editor", PRE + CTRL + Qt::Key_4);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
113 const sc_pref sc_main_window_doc (sc_main_window + ":doc", PRE + CTRL + Qt::Key_5);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
114 const sc_pref sc_main_window_variable_editor (sc_main_window + ":variable_editor", PRE + CTRL + Qt::Key_6);
28131
27c99ff83b99 change default shortcut for previous widget
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27937
diff changeset
115 const sc_pref sc_main_window_previous_dock (sc_main_window + ":previous_widget", PRE + CTRL_ALT + Qt::Key_P);
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
116 const sc_pref sc_main_window_reset (sc_main_window + ":reset", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
117
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
118 // help
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
119 const QString sc_main_help ("main_help");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
120 const sc_pref sc_main_help_ondisk_doc (sc_main_help + ":ondisk_doc", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
121 const sc_pref sc_main_help_online_doc (sc_main_help + ":online_doc", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
122 const sc_pref sc_main_help_report_bug (sc_main_help + ":report_bug", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
123 const sc_pref sc_main_help_packages (sc_main_help + ":packages", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
124 const sc_pref sc_main_help_contribute (sc_main_help + ":contribute", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
125 const sc_pref sc_main_help_developer (sc_main_help + ":developer", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
126 const sc_pref sc_main_help_about (sc_main_help + ":about", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
127
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
128 // news
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
129 const QString sc_main_news ("main_news");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
130 const sc_pref sc_main_news_release_notes (sc_main_news + ":release_notes", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
131 const sc_pref sc_main_news_community_news (sc_main_news + ":community_news", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
132
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
133 // Tab handling
27929
265b386f8b20 maint: Use two spaces between sentences in code comments.
Rik <rik@octave.org>
parents: 27923
diff changeset
134 // The following shortcuts are moved into a separate tab. The key names
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
135 // are not change for preserving compatibility with older versions
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
136 const QString sc_edit_file ("editor_file");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
137 const QString sc_edit_file_cl (sc_edit_file + ":close");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
138 const sc_pref sc_edit_file_close (sc_edit_file_cl, QKeySequence::Close);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
139 const sc_pref sc_edit_file_close_all (sc_edit_file_cl + "_all", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
140 const sc_pref sc_edit_file_close_other (sc_edit_file_cl + "_other", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
141 const QString sc_edit_tabs ("editor_tabs");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
142 const sc_pref sc_edit_tabs_switch_left_tab (sc_edit_tabs + ":switch_left_tab", CTRL + Qt::Key_PageUp);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
143 const sc_pref sc_edit_tabs_switch_right_tab (sc_edit_tabs + ":switch_right_tab", CTRL + Qt::Key_PageDown);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
144 const sc_pref sc_edit_tabs_move_tab_left (sc_edit_tabs + ":move_tab_left", Qt::AltModifier + Qt::Key_PageUp);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
145 const sc_pref sc_edit_tabs_move_tab_right (sc_edit_tabs + ":move_tab_right", Qt::AltModifier + Qt::Key_PageDown);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
146
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
147 // Zooming
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
148 const QString sc_edit_zoom ("editor_zoom"); // only a group name in the pref dialog
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
149 const QString sc_edit_view ("editor_view");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
150 const QString sc_edit_view_zoom (sc_edit_view + ":zoom");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
151 const sc_pref sc_edit_view_zoom_in (sc_edit_view_zoom + "_in", QKeySequence::ZoomIn);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
152 const sc_pref sc_edit_view_zoom_out (sc_edit_view_zoom + "_out", QKeySequence::ZoomOut);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
153 #if defined (Q_OS_MAC)
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
154 const sc_pref sc_edit_view_zoom_normal (sc_edit_view_zoom + "_normal", CTRL + Qt::Key_Underscore);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
155 #else
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
156 const sc_pref sc_edit_view_zoom_normal (sc_edit_view_zoom + "_normal", CTRL + Qt::Key_Period);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
157 #endif
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
158
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
159 // Actions of the editor
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
160
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
161 // file
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
162 const sc_pref sc_edit_file_edit_function (sc_edit_file + ":edit_function", CTRL + Qt::Key_E);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
163 const sc_pref sc_edit_file_save (sc_edit_file + ":save", QKeySequence::Save);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
164 const sc_pref sc_edit_file_save_as (sc_edit_file + ":save_as", QKeySequence::SaveAs);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
165 const sc_pref sc_edit_file_print (sc_edit_file + ":print", QKeySequence::Print);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
166
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
167 // edit
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
168 const QString sc_edit_find ("editor_find"); // only a group name in the pref dialog
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
169 const QString sc_edit_edit ("editor_edit");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
170 const QString sc_edit_edit_find (sc_edit_edit + ":find");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
171 const sc_pref sc_edit_edit_redo (sc_edit_edit + ":redo", QKeySequence::Redo);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
172 const sc_pref sc_edit_edit_cut (sc_edit_edit + ":cut", QKeySequence::Cut);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
173 const sc_pref sc_edit_edit_find_replace (sc_edit_edit_find + "_replace", QKeySequence::Find);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
174 const sc_pref sc_edit_edit_find_next (sc_edit_edit_find + "_next", QKeySequence::FindNext);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
175 const sc_pref sc_edit_edit_find_previous (sc_edit_edit_find + "_previous", QKeySequence::FindPrevious);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
176 const sc_pref sc_edit_edit_delete_start_word (sc_edit_edit + ":delete_start_word", QKeySequence::DeleteStartOfWord);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
177 const sc_pref sc_edit_edit_delete_end_word (sc_edit_edit + ":delete_end_word", QKeySequence::DeleteEndOfWord);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
178 const sc_pref sc_edit_edit_delete_start_line (sc_edit_edit + ":delete_start_line", CTRL_SHIFT + Qt::Key_Backspace);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
179 const sc_pref sc_edit_edit_delete_end_line (sc_edit_edit + ":delete_end_line", CTRL_SHIFT + Qt::Key_Delete);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
180 const sc_pref sc_edit_edit_delete_line (sc_edit_edit + ":delete_line", CTRL_SHIFT + Qt::Key_L);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
181 const sc_pref sc_edit_edit_copy_line (sc_edit_edit + ":copy_line", CTRL_SHIFT + Qt::Key_C);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
182 const sc_pref sc_edit_edit_cut_line (sc_edit_edit + ":cut_line", CTRL_SHIFT + Qt::Key_X);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
183 const sc_pref sc_edit_edit_duplicate_selection (sc_edit_edit + ":duplicate_selection", CTRL + Qt::Key_D);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
184 const sc_pref sc_edit_edit_transpose_line (sc_edit_edit + ":transpose_line", CTRL + Qt::Key_T);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
185 const sc_pref sc_edit_edit_completion_list (sc_edit_edit + ":completion_list", CTRL + Qt::Key_Space);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
186
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
187 const sc_pref sc_edit_edit_comment_selection (sc_edit_edit + ":comment_selection", CTRL + Qt::Key_R);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
188 const sc_pref sc_edit_edit_uncomment_selection (sc_edit_edit + ":uncomment_selection", CTRL_SHIFT + Qt::Key_R);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
189 const sc_pref sc_edit_edit_comment_var_selection (sc_edit_edit + ":comment_var_selection", CTRL_ALT + Qt::Key_R);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
190 const sc_pref sc_edit_edit_upper_case (sc_edit_edit + ":upper_case", CTRL + Qt::Key_U);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
191 const sc_pref sc_edit_edit_lower_case (sc_edit_edit + ":lower_case", CTRL_ALT + Qt::Key_U);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
192
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
193 #if defined (Q_OS_MAC)
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
194 const sc_pref sc_edit_edit_indent_selection (sc_edit_edit + ":indent_selection", PRE + Qt::Key_Tab);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
195 const sc_pref sc_edit_edit_unindent_selection (sc_edit_edit + ":unindent_selection", PRE + Qt::ShiftModifier + Qt::Key_Tab);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
196 #else
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
197 const sc_pref sc_edit_edit_indent_selection (sc_edit_edit + ":indent_selection", CTRL + Qt::Key_Tab);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
198 const sc_pref sc_edit_edit_unindent_selection (sc_edit_edit + ":unindent_selection", CTRL_SHIFT + Qt::Key_Tab);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
199 #endif
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
200 const sc_pref sc_edit_edit_smart_indent_line_or_selection (sc_edit_edit + ":smart_indent_line_or_selection", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
201
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
202 const sc_pref sc_edit_edit_conv_eol_winows (sc_edit_edit + ":conv_eol_winows", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
203 const sc_pref sc_edit_edit_conv_eol_unix (sc_edit_edit + ":conv_eol_unix", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
204 const sc_pref sc_edit_edit_conv_eol_mac (sc_edit_edit + ":conv_eol_mac", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
205
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
206 const sc_pref sc_edit_edit_goto_line (sc_edit_edit + ":goto_line", CTRL + Qt::Key_L);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
207 const sc_pref sc_edit_edit_move_to_brace (sc_edit_edit + ":move_to_brace", CTRL + Qt::Key_M);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
208 const sc_pref sc_edit_edit_select_to_brace (sc_edit_edit + ":select_to_brace", CTRL_SHIFT + Qt::Key_M);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
209 const sc_pref sc_edit_edit_toggle_bookmark (sc_edit_edit + ":toggle_bookmark", PRE + Qt::Key_F7);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
210 const sc_pref sc_edit_edit_next_bookmark (sc_edit_edit + ":next_bookmark", PRE + Qt::Key_F2);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
211 const sc_pref sc_edit_edit_previous_bookmark (sc_edit_edit + ":previous_bookmark", PRE + Qt::SHIFT + Qt::Key_F2);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
212 const sc_pref sc_edit_edit_remove_bookmark (sc_edit_edit + ":remove_bookmark", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
213
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
214 const sc_pref sc_edit_edit_preferences (sc_edit_edit + ":preferences", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
215 const sc_pref sc_edit_edit_styles_preferences (sc_edit_edit + ":styles_preferences", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
216
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
217 // view
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
218 const sc_pref sc_edit_view_show_line_numbers (sc_edit_view + ":show_line_numbers", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
219 const sc_pref sc_edit_view_show_white_spaces (sc_edit_view + ":show_white_spaces", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
220 const sc_pref sc_edit_view_show_eol_chars (sc_edit_view + ":show_eol_chars", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
221 const sc_pref sc_edit_view_show_ind_guides (sc_edit_view + ":show_ind_guides", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
222 const sc_pref sc_edit_view_show_long_line (sc_edit_view + ":show_long_line", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
223 const sc_pref sc_edit_view_show_toolbar (sc_edit_view + ":show_toolbar", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
224 const sc_pref sc_edit_view_show_statusbar (sc_edit_view + ":show_statusbar", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
225 const sc_pref sc_edit_view_show_hscrollbar (sc_edit_view + ":show_hscrollbar", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
226 const sc_pref sc_edit_view_sort_tabs (sc_edit_view + ":sort_tabs", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
227
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
228 // debug
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
229 const QString sc_edit_debug ("editor_debug");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
230 const sc_pref sc_edit_debug_toggle_breakpoint (sc_edit_debug + ":toggle_breakpoint", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
231 const sc_pref sc_edit_debug_next_breakpoint (sc_edit_debug + ":next_breakpoint", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
232 const sc_pref sc_edit_debug_previous_breakpoint (sc_edit_debug + ":previous_breakpoint", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
233 const sc_pref sc_edit_debug_remove_breakpoints (sc_edit_debug + ":remove_breakpoints", QKeySequence::UnknownKey);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
234
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
235 // run
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
236 const QString sc_edit_run ("editor_run");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
237 const sc_pref sc_edit_run_run_file (sc_edit_run + ":run_file", PRE + Qt::Key_F5);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
238 const sc_pref sc_edit_run_run_selection (sc_edit_run + ":run_selection", PRE + Qt::Key_F9);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
239
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
240 // help
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
241 const QString sc_edit_help ("editor_help");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
242 const sc_pref sc_edit_help_help_keyword (sc_edit_help + ":help_keyword", QKeySequence::HelpContents);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
243 const sc_pref sc_edit_help_doc_keyword (sc_edit_help + ":doc_keyword", Qt::SHIFT + Qt::Key_F1);
27724
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
244
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
245
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
246 // Documentation browser
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
247 const QString sc_doc ("doc_browser");
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
248 const sc_pref sc_doc_go_home (sc_doc + ":go_home", Qt::AltModifier + Qt::Key_Home);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
249 const sc_pref sc_doc_go_back (sc_doc + ":go_back", QKeySequence::Back);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
250 const sc_pref sc_doc_go_next (sc_doc + ":go_next", QKeySequence::Forward);
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
251
27724
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
252
19e80f22aa47 provide structure and settings value method for shortcut key sequences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27583
diff changeset
253 // Other normal, shortcut related options
27583
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
254
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
255 const gui_pref
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
256 sc_main_ctrld ("shortcuts/main_ctrld", QVariant (false));
27818
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
257
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
258 const gui_pref
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
259 sc_prevent_rl_conflicts ("shortcuts/prevent_readline_conflicts", QVariant (true));
fa0582694fda replace literal strings by symbolic constants for shortcut preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents: 27724
diff changeset
260
27583
315c35e6037c use symbolic constants for command widget preferences
Torsten Lilge <ttl-octave@mailbox.org>
parents:
diff changeset
261 #endif