GNU Octave  8.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
settings-dialog.h
Go to the documentation of this file.
1 ////////////////////////////////////////////////////////////////////////
2 //
3 // Copyright (C) 2011-2023 The Octave Project Developers
4 //
5 // See the file COPYRIGHT.md in the top-level directory of this
6 // distribution or <https://octave.org/copyright/>.
7 //
8 // This file is part of Octave.
9 //
10 // Octave is free software: you can redistribute it and/or modify it
11 // under the terms of the GNU General Public License as published by
12 // the Free Software Foundation, either version 3 of the License, or
13 // (at your option) any later version.
14 //
15 // Octave is distributed in the hope that it will be useful, but
16 // WITHOUT ANY WARRANTY; without even the implied warranty of
17 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 // GNU General Public License for more details.
19 //
20 // You should have received a copy of the GNU General Public License
21 // along with Octave; see the file COPYING. If not, see
22 // <https://www.gnu.org/licenses/>.
23 //
24 ////////////////////////////////////////////////////////////////////////
25 
26 #if ! defined (octave_settings_dialog_h)
27 #define octave_settings_dialog_h 1
28 
29 #include <QCheckBox>
30 #include <QDialog>
31 #include <QLineEdit>
32 #include <QRadioButton>
33 
34 #include "color-picker.h"
35 #include "gui-preferences-ed.h"
36 #include "gui-settings.h"
37 #include "ui-settings-dialog.h"
38 
39 class QsciLexer;
40 
42 
43 class base_qobject;
44 
45 // Ui::settings_dialog is a generated class.
46 
47 class settings_dialog : public QDialog, private Ui::settings_dialog
48 {
49  Q_OBJECT public:
50 
51  explicit settings_dialog (QWidget *parent, base_qobject& octave_qobj,
52  const QString& desired_tab = QString ());
53 
54  ~settings_dialog (void) = default;
55 
56  void show_tab (const QString&);
57 
58 signals:
59 
60  void apply_new_settings (void);
61 
62 private slots:
63 
64  void get_octave_dir (void);
65  void get_file_browser_dir (void);
66  void get_dir (QLineEdit *, const QString&);
67  void set_disabled_pref_file_browser_dir (bool disable);
68  void proxy_items_update (void);
69 
70  // slots updating colors depending on theme
71  void update_terminal_colors (int def = 0);
72  void update_workspace_colors (int def = 0);
73  void update_varedit_colors (int def = 0);
74  void update_editor_lexers (int def = 0);
75 
76  // slots for dialog's buttons
77  void button_clicked (QAbstractButton *button);
78 
79  // slots for import/export-buttons of shortcut sets
80  void import_shortcut_set (void);
81  void export_shortcut_set (void);
82  void default_shortcut_set (void);
83 
84 private:
85 
86 #if defined (HAVE_QSCINTILLA)
87  void update_lexer (QsciLexer *lexer, gui_settings *settings, int mode, int def = 0);
90 #endif
91 
92  void write_changed_settings (bool closing);
93 
96 
99 
102 
104 
109 
112 
113  QCheckBox *m_ws_enable_colors;
115 };
116 
118 
119 #endif
OCTAVE_END_NAMESPACE(octave)
Base class for Octave interfaces that use Qt.
Definition: lex.h:766
void update_terminal_colors(int def=0)
QCheckBox * m_ws_hide_tool_tips
color_picker * m_widget_title_fg_color
void show_tab(const QString &)
void read_workspace_colors(gui_settings *settings)
void write_workspace_colors(gui_settings *settings)
base_qobject & m_octave_qobj
void update_lexer(QsciLexer *lexer, gui_settings *settings, int mode, int def=0)
void apply_new_settings(void)
QCheckBox * m_rb_uncomment_strings[ed_comment_strings_count]
void default_shortcut_set(void)
color_picker * m_widget_title_fg_color_active
void update_editor_lexers(int def=0)
void get_octave_dir(void)
void import_shortcut_set(void)
void get_file_browser_dir(void)
void read_varedit_colors(gui_settings *settings)
void write_changed_settings(bool closing)
void button_clicked(QAbstractButton *button)
color_picker * m_widget_title_bg_color_active
void write_varedit_colors(gui_settings *settings)
void read_terminal_colors(gui_settings *settings)
settings_dialog(QWidget *parent, base_qobject &octave_qobj, const QString &desired_tab=QString())
QCheckBox * m_ws_enable_colors
~settings_dialog(void)=default
void export_shortcut_set(void)
void write_terminal_colors(gui_settings *settings)
void proxy_items_update(void)
void set_disabled_pref_file_browser_dir(bool disable)
void get_lexer_settings(QsciLexer *lexer, gui_settings *settings)
color_picker * m_widget_title_bg_color
QRadioButton * m_rb_comment_strings[ed_comment_strings_count]
void get_dir(QLineEdit *, const QString &)
void update_varedit_colors(int def=0)
void write_lexer_settings(QsciLexer *lexer, gui_settings *settings)
void update_workspace_colors(int def=0)
OCTAVE_BEGIN_NAMESPACE(octave) static octave_value daspk_fcn
const int ed_comment_strings_count