GNU Octave  8.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
terminal-dock-widget.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_terminal_dock_widget_h)
27 #define octave_terminal_dock_widget_h 1
28 
29 #include <QString>
30 
31 #include "octave-dock-widget.h"
32 
33 class QTerminal;
34 
36 
37 class command_widget;
38 class base_qobject;
39 
41 {
42  Q_OBJECT
43 
44 public:
45 
46  terminal_dock_widget (QWidget *parent, base_qobject& oct_qobj);
47 
48  ~terminal_dock_widget (void) = default;
49 
50  bool has_focus (void) const;
51 
52  void init_command_prompt ();
53 
54  // FIXME: The next two functions could be eliminated (or combined)
55  // if we had a common interface for the old and new terminal
56  // widgets.
57 
58  // Only valid if using the old terminal widget.
59  QTerminal * get_qterminal (void);
60 
61 #if defined (HAVE_QSCINTILLA)
62  // Only valid if using the new terminal widget.
64 #endif
65 
66 signals:
67 
69 
70  // Note: the following four signals are
71  // currently only used by the new experimental terminal widget.
72 
73  void update_prompt_signal (const QString&);
74 
75  void interpreter_output_signal (const QString&);
76 
77  void new_command_line_signal (const QString& = QString ());
78 
79  void execute_command_signal (const QString&);
80 
81 public slots:
82 
84 
85 private:
86 
88 
89  // FIXME!!! Maybe my_term should just be derived from QTerminal?
91 };
92 
94 
95 #endif
OCTAVE_END_NAMESPACE(octave)
Base class for Octave interfaces that use Qt.
void notice_settings(const gui_settings *settings)
terminal_dock_widget(QWidget *parent, base_qobject &oct_qobj)
command_widget * get_command_widget(void)
void new_command_line_signal(const QString &=QString())
~terminal_dock_widget(void)=default
QTerminal * get_qterminal(void)
void interpreter_output_signal(const QString &)
void update_prompt_signal(const QString &)
void settings_changed(const gui_settings *settings)
void execute_command_signal(const QString &)
OCTAVE_BEGIN_NAMESPACE(octave) static octave_value daspk_fcn