GNU Octave
4.0.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
|
#include "octave-link.h"
Public Types | |
typedef std::list< std::pair < std::string, std::string > > | filter_list |
Public Member Functions | |
virtual | ~octave_link (void) |
Static Public Member Functions | |
static void | append_history (const std::string &hist_entry) |
static void | change_directory (const std::string &dir) |
static void | clear_history (void) |
static void | clear_workspace (void) |
static bool | confirm_shutdown (void) |
static void | connect_link (octave_link *) |
static bool | copy_image_to_clipboard (const std::string &file) |
static int | debug_cd_or_addpath_error (const std::string &file, const std::string &dir, bool addpath_option) |
static void | discard_events (void) |
static bool | edit_file (const std::string &file) |
static bool | enabled (void) |
static void | enter_debugger_event (const std::string &file, int line) |
static void | entered_readline_hook (void) |
static void | execute_command_in_terminal (const std::string &command) |
static void | execute_in_debugger_event (const std::string &file, int line) |
static bool | exit (int status) |
static void | exit_debugger_event (void) |
static std::list< std::string > | file_dialog (const filter_list &filter, const std::string &title, const std::string &filename, const std::string &dirname, const std::string &multimode) |
static void | finished_readline_hook (void) |
static void | generate_events (void) |
static std::list< std::string > | input_dialog (const std::list< std::string > &prompt, const std::string &title, const std::list< float > &nr, const std::list< float > &nc, const std::list< std::string > &defaults) |
static std::pair< std::list < int >, int > | list_dialog (const std::list< std::string > &list, const std::string &mode, int width, int height, const std::list< int > &initial_value, const std::string &name, const std::list< std::string > &prompt, const std::string &ok_string, const std::string &cancel_string) |
static int | message_dialog (const std::string &dlg, const std::string &msg, const std::string &title) |
template<class T > | |
static void | post_event (T *obj, void(T::*method)(void)) |
template<class T , class A > | |
static void | post_event (T *obj, void(T::*method)(A), A arg) |
template<class T , class A > | |
static void | post_event (T *obj, void(T::*method)(const A &), const A &arg) |
static void | post_input_event (void) |
static void | pre_input_event (void) |
static void | process_events (bool disable=false) |
static bool | prompt_new_edit_file (const std::string &file) |
static std::string | question_dialog (const std::string &msg, const std::string &title, const std::string &btn1, const std::string &btn2, const std::string &btn3, const std::string &btndef) |
static void | set_default_prompts (std::string &ps1, std::string &ps2, std::string &ps4) |
static void | set_history (const string_vector &hist) |
static void | set_workspace (void) |
static void | set_workspace (bool top_level, const std::list< workspace_element > &ws) |
static bool | show_doc (const std::string &file) |
static bool | show_preferences () |
static void | update_breakpoint (bool insert, const std::string &file, int line) |
Protected Member Functions | |
octave_link (void) | |
virtual void | do_append_history (const std::string &hist_entry)=0 |
virtual void | do_change_directory (const std::string &dir)=0 |
virtual void | do_clear_history (void)=0 |
virtual void | do_clear_workspace (void)=0 |
virtual bool | do_confirm_shutdown (void)=0 |
virtual bool | do_copy_image_to_clipboard (const std::string &file)=0 |
virtual int | do_debug_cd_or_addpath_error (const std::string &file, const std::string &dir, bool addpath_option)=0 |
void | do_discard_events (void) |
virtual bool | do_edit_file (const std::string &file)=0 |
virtual void | do_enter_debugger_event (const std::string &file, int line)=0 |
void | do_entered_readline_hook (void) |
virtual void | do_execute_command_in_terminal (const std::string &command)=0 |
virtual void | do_execute_in_debugger_event (const std::string &file, int line)=0 |
virtual bool | do_exit (int status)=0 |
virtual void | do_exit_debugger_event (void)=0 |
virtual std::list< std::string > | do_file_dialog (const filter_list &filter, const std::string &title, const std::string &filename, const std::string &dirname, const std::string &multimode)=0 |
void | do_finished_readline_hook (void) |
void | do_generate_events (void) |
virtual std::list< std::string > | do_input_dialog (const std::list< std::string > &prompt, const std::string &title, const std::list< float > &nr, const std::list< float > &nc, const std::list< std::string > &defaults)=0 |
virtual std::pair< std::list < int >, int > | do_list_dialog (const std::list< std::string > &list, const std::string &mode, int width, int height, const std::list< int > &initial_value, const std::string &name, const std::list< std::string > &prompt, const std::string &ok_string, const std::string &cancel_string)=0 |
virtual int | do_message_dialog (const std::string &dlg, const std::string &msg, const std::string &title)=0 |
template<class T > | |
void | do_post_event (T *obj, void(T::*method)(void)) |
template<class T , class A > | |
void | do_post_event (T *obj, void(T::*method)(A), A arg) |
template<class T , class A > | |
void | do_post_event (T *obj, void(T::*method)(const A &), const A &arg) |
virtual void | do_post_input_event (void)=0 |
virtual void | do_pre_input_event (void)=0 |
void | do_process_events (void) |
virtual bool | do_prompt_new_edit_file (const std::string &file)=0 |
virtual std::string | do_question_dialog (const std::string &msg, const std::string &title, const std::string &btn1, const std::string &btn2, const std::string &btn3, const std::string &btndef)=0 |
virtual void | do_set_default_prompts (std::string &ps1, std::string &ps2, std::string &ps4)=0 |
virtual void | do_set_history (const string_vector &hist)=0 |
virtual void | do_set_workspace (bool top_level, bool debug, const std::list< workspace_element > &ws)=0 |
virtual void | do_show_doc (const std::string &file)=0 |
virtual void | do_show_preferences (void)=0 |
virtual void | do_update_breakpoint (bool insert, const std::string &file, int line)=0 |
Protected Attributes | |
bool | debugging |
octave_mutex * | event_queue_mutex |
event_queue | gui_event_queue |
bool | link_enabled |
Private Member Functions | |
octave_link (const octave_link &) | |
octave_link & | operator= (const octave_link &) |
Static Private Member Functions | |
static bool | instance_ok (void) |
Static Private Attributes | |
static octave_link * | instance = 0 |
Definition at line 44 of file octave-link.h.
typedef std::list<std::pair<std::string, std::string> > octave_link::filter_list |
Definition at line 198 of file octave-link.h.
|
protected |
Definition at line 51 of file octave-link.cc.
References command_editor::add_event_hook(), and octave_readline_hook().
|
inlinevirtual |
Definition at line 54 of file octave-link.h.
|
private |
|
inlinestatic |
Definition at line 255 of file octave-link.h.
Referenced by edit_history_add_hist(), octave_base_reader::octave_gets(), and octave_history_write_timestamp().
|
inlinestatic |
Definition at line 221 of file octave-link.h.
Referenced by octave_change_to_directory().
|
inlinestatic |
Definition at line 261 of file octave-link.h.
Referenced by do_history().
|
inlinestatic |
Definition at line 243 of file octave-link.h.
Referenced by Fclear().
|
inlinestatic |
Definition at line 82 of file octave-link.h.
Referenced by Fquit().
|
static |
Definition at line 73 of file octave-link.cc.
References error(), and instance.
Referenced by main_window::construct_octave_qt_link().
|
inlinestatic |
Definition at line 136 of file octave-link.h.
Referenced by QtHandles::Figure::copy_figure_callback().
|
inlinestatic |
Definition at line 212 of file octave-link.h.
Referenced by octave_qt_link::file_in_path().
|
inlinestatic |
Definition at line 76 of file octave-link.h.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protected |
Definition at line 97 of file octave-link.cc.
References action_container::discard(), event_queue_mutex, gui_event_queue, octave_mutex::lock(), and octave_mutex::unlock().
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
inlineprotected |
Definition at line 396 of file octave-link.h.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
inlineprotected |
Definition at line 397 of file octave-link.h.
|
protected |
Definition at line 82 of file octave-link.cc.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
inlineprotected |
Definition at line 379 of file octave-link.h.
References action_container::add_method().
|
inlineprotected |
Definition at line 385 of file octave-link.h.
References action_container::add_method().
|
inlineprotected |
Definition at line 391 of file octave-link.h.
References action_container::add_method().
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protected |
Definition at line 87 of file octave-link.cc.
References event_queue_mutex, gui_event_queue, octave_mutex::lock(), action_container::run(), and octave_mutex::unlock().
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
Referenced by set_workspace().
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
protectedpure virtual |
Implemented in octave_qt_link.
|
inlinestatic |
Definition at line 142 of file octave-link.h.
Referenced by F__octave_link_edit_file__().
|
inlinestatic |
Definition at line 321 of file octave-link.h.
Referenced by F__octave_link_enabled__(), and set_workspace().
|
inlinestatic |
Definition at line 279 of file octave-link.h.
Referenced by get_debug_input().
|
inlinestatic |
Definition at line 123 of file octave-link.h.
Referenced by octave_readline_hook().
|
inlinestatic |
Definition at line 228 of file octave-link.h.
|
inlinestatic |
Definition at line 289 of file octave-link.h.
Referenced by execute_in_debugger_handler().
Definition at line 92 of file octave-link.h.
Referenced by clean_up_and_exit().
|
inlinestatic |
Definition at line 295 of file octave-link.h.
Referenced by octave_base_reader::octave_gets().
|
inlinestatic |
Definition at line 201 of file octave-link.h.
Referenced by F__octave_link_file_dialog__().
|
inlinestatic |
Definition at line 129 of file octave-link.h.
Referenced by octave_readline_hook().
|
inlinestatic |
Definition at line 56 of file octave-link.h.
Referenced by octave_readline_hook().
|
inlinestatic |
Definition at line 187 of file octave-link.h.
Referenced by F__octave_link_input_dialog__().
|
inlinestaticprivate |
Definition at line 361 of file octave-link.h.
|
inlinestatic |
Definition at line 170 of file octave-link.h.
Referenced by F__octave_link_list_dialog__().
|
inlinestatic |
Definition at line 154 of file octave-link.h.
Referenced by F__octave_link_message_dialog__().
|
private |
|
inlinestatic |
Definition at line 103 of file octave-link.h.
Referenced by QtHandles::Canvas::canvasMouseReleaseEvent(), main_window::construct(), QtHandles::Figure::editCopy(), main_window::execute_command_callback(), main_window::execute_debug_callback(), QtHandles::Figure::fileSaveFigure(), main_window::handle_clear_command_window_request(), main_window::handle_clear_history_request(), main_window::handle_clear_workspace_request(), main_window::handle_load_workspace_request(), main_window::handle_new_figure_request(), main_window::handle_rename_variable_request(), main_window::handle_save_workspace_request(), main_window::handle_undo_request(), main_window::queue_command(), main_window::queue_debug(), main_window::run_file_in_terminal(), main_window::set_current_working_directory(), and main_window::set_screen_size().
|
inlinestatic |
Definition at line 110 of file octave-link.h.
|
inlinestatic |
Definition at line 117 of file octave-link.h.
|
inlinestatic |
Definition at line 273 of file octave-link.h.
Referenced by octave_base_reader::octave_gets().
|
inlinestatic |
Definition at line 267 of file octave-link.h.
Referenced by octave_base_reader::octave_gets().
|
inlinestatic |
Definition at line 65 of file octave-link.h.
Referenced by do_octave_atexit(), and octave_readline_hook().
|
inlinestatic |
Definition at line 148 of file octave-link.h.
Referenced by F__octave_link_edit_file__().
|
inlinestatic |
Definition at line 161 of file octave-link.h.
Referenced by F__octave_link_question_dialog__().
|
inlinestatic |
Definition at line 314 of file octave-link.h.
Referenced by set_default_prompts().
|
inlinestatic |
Definition at line 249 of file octave-link.h.
Referenced by do_history(), and initialize_history().
|
static |
Definition at line 59 of file octave-link.cc.
References symbol_table::current_scope(), debugging, do_set_workspace(), enabled(), instance, symbol_table::top_scope(), and symbol_table::workspace_info().
Referenced by Fclear(), get_debug_input(), main_window::load_workspace_callback(), octave_base_reader::octave_gets(), and main_window::rename_variable_callback().
|
inlinestatic |
Definition at line 236 of file octave-link.h.
|
inlinestatic |
Definition at line 339 of file octave-link.h.
Referenced by F__octave_link_show_doc__().
|
inlinestatic |
Definition at line 327 of file octave-link.h.
Referenced by F__octave_link_show_preferences__().
|
inlinestatic |
Definition at line 306 of file octave-link.h.
Referenced by tree_statement_list::add_breakpoint(), bp_table::do_remove_breakpoint_1(), and tree_statement_list::remove_all_breakpoints().
|
protected |
Definition at line 371 of file octave-link.h.
Referenced by set_workspace().
|
protected |
Definition at line 366 of file octave-link.h.
Referenced by do_discard_events(), and do_process_events().
|
protected |
Definition at line 369 of file octave-link.h.
Referenced by do_discard_events(), and do_process_events().
|
staticprivate |
Definition at line 353 of file octave-link.h.
Referenced by connect_link(), and set_workspace().
|
protected |
Definition at line 372 of file octave-link.h.