comparison libgui/src/command-widget.h @ 31697:dd904ce6f53f

use interpreter event to display documentation in terminal and editor widgets * QTerminal.h, QTerminal.cc (QTerminal::doc_on_expression): Use interpreter_event to display doc browser instead of calling base_qobject::show_documentation_window. (QTerminal::interpreter_event): New signals. * command-widget.h, command-widget.cc (console::interpreter_event): New signals. (command_widget::command_widget): Forward console interpreter_event signals to command_widget interpreter_event signals. * octave-qscintilla.cc (octave_qscintilla::contextmenu_help_doc): Use interpreter_event to display doc browser instead of calling base_qobject::show_documentation_window. * octave-qobject.cc (base_qobject::terminal_widget): Also call connect_interpreter_events for QTerminal. * terminal-dock-widget.h, terminal-dock-widget.cc (terminal_dock_widget::interpreter_event): New signals. (terminal_dock_widget::terminal_dock_widget): Forward QTerminal interpreter_event signals to terminal_dock_widget interpreter_event signals.
author John W. Eaton <jwe@octave.org>
date Fri, 30 Dec 2022 23:13:00 -0500
parents deb553ac2c54
children 276a992d0c08
comparison
equal deleted inserted replaced
31696:8fed04d0607c 31697:dd904ce6f53f
49 49
50 public: 50 public:
51 51
52 console (command_widget *p, base_qobject& oct_qobj); 52 console (command_widget *p, base_qobject& oct_qobj);
53 53
54 signals:
55
56 void interpreter_event (const fcn_callback& fcn);
57 void interpreter_event (const meth_callback& meth);
58
54 public slots: 59 public slots:
55 60
56 void cursor_position_changed (int line, int col); 61 void cursor_position_changed (int line, int col);
57 62
58 void text_changed (void); 63 void text_changed (void);
101 106
102 void interpreter_pause (void); 107 void interpreter_pause (void);
103 void interpreter_resume (void); 108 void interpreter_resume (void);
104 void interpreter_stop (void); 109 void interpreter_stop (void);
105 110
111 void new_command_line_signal (const QString& command = QString ());
112
106 void interpreter_event (const fcn_callback& fcn); 113 void interpreter_event (const fcn_callback& fcn);
107 void interpreter_event (const meth_callback& meth); 114 void interpreter_event (const meth_callback& meth);
108
109 void new_command_line_signal (const QString& command = QString ());
110 115
111 public slots: 116 public slots:
112 117
113 void process_input_line (const QString& input_line); 118 void process_input_line (const QString& input_line);
114 119