GNU Octave  8.1.0
A high-level interpreted language, primarily intended for numerical computations, mostly compatible with Matlab
shortcut_manager Class Reference

#include "shortcut-manager.h"

Inheritance diagram for shortcut_manager:
Collaboration diagram for shortcut_manager:

Classes

class  shortcut_t
 

Public Types

enum  { OSC_IMPORT = 0 , OSC_EXPORT = 1 , OSC_DEFAULT = 2 }
 

Public Member Functions

 shortcut_manager (base_qobject &oct_qobj)
 
 shortcut_manager (const shortcut_manager &)=delete
 
 ~shortcut_manager (void)=default
 
void fill_treewidget (QTreeWidget *tree_view)
 
bool import_export (int action)
 
void init_data (void)
 
shortcut_manageroperator= (const shortcut_manager &)=delete
 
void set_shortcut (QAction *action, const sc_pref &scpref, bool enable=true)
 
void shortcut (QShortcut *sc, const sc_pref &scpref)
 
void write_shortcuts (gui_settings *settings, bool closing)
 

Protected Slots

void handle_double_clicked (QTreeWidgetItem *, int)
 
void shortcut_dialog_finished (int)
 
void shortcut_dialog_set_default ()
 

Private Member Functions

void import_shortcuts (gui_settings *settings)
 
void init (const QString &, const sc_pref &scpref)
 
bool overwrite_all_shortcuts (void)
 
void shortcut_dialog (int)
 

Private Attributes

QHash< QString, int > m_action_hash
 
QDialogm_dialog
 
enter_shortcutm_edit_actual
 
int m_handled_index
 
QHash< int, QTreeWidgetItem * > m_index_item_hash
 
QHash< QTreeWidgetItem *, int > m_item_index_hash
 
QLabelm_label_default
 
QHash< QString, QTreeWidgetItem * > m_level_hash
 
base_qobjectm_octave_qobj
 
QList< shortcut_tm_sc
 
QHash< QString, int > m_shortcut_hash
 

Detailed Description

Definition at line 66 of file shortcut-manager.h.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
OSC_IMPORT 
OSC_EXPORT 
OSC_DEFAULT 

Definition at line 72 of file shortcut-manager.h.

Constructor & Destructor Documentation

◆ shortcut_manager() [1/2]

shortcut_manager::shortcut_manager ( base_qobject oct_qobj)

Definition at line 111 of file shortcut-manager.cc.

◆ shortcut_manager() [2/2]

shortcut_manager::shortcut_manager ( const shortcut_manager )
delete

◆ ~shortcut_manager()

shortcut_manager::~shortcut_manager ( void  )
default

Member Function Documentation

◆ fill_treewidget()

◆ handle_double_clicked

void shortcut_manager::handle_double_clicked ( QTreeWidgetItem *  item,
int  col 
)
protectedslot

Definition at line 568 of file shortcut-manager.cc.

References m_item_index_hash, and shortcut_dialog().

Referenced by fill_treewidget().

◆ import_export()

◆ import_shortcuts()

void shortcut_manager::import_shortcuts ( gui_settings settings)
private

◆ init()

◆ init_data()

void shortcut_manager::init_data ( void  )

Definition at line 122 of file shortcut-manager.cc.

References base_qobject::get_resource_manager(), resource_manager::get_settings(), init(), gui_pref::key, m_octave_qobj, sc_doc_bookmark(), sc_doc_go_back(), sc_doc_go_home(), sc_doc_go_next(), sc_dock_widget_close(), sc_dock_widget_dock(), sc_edit_debug_next_breakpoint(), sc_edit_debug_previous_breakpoint(), sc_edit_debug_remove_breakpoints(), sc_edit_debug_toggle_breakpoint(), sc_edit_edit_comment_selection(), sc_edit_edit_comment_var_selection(), sc_edit_edit_completion_list(), sc_edit_edit_conv_eol_mac(), sc_edit_edit_conv_eol_unix(), sc_edit_edit_conv_eol_winows(), sc_edit_edit_copy_line(), sc_edit_edit_cut(), sc_edit_edit_cut_line(), sc_edit_edit_delete_end_line(), sc_edit_edit_delete_end_word(), sc_edit_edit_delete_line(), sc_edit_edit_delete_start_line(), sc_edit_edit_delete_start_word(), sc_edit_edit_duplicate_selection(), sc_edit_edit_find_next(), sc_edit_edit_find_previous(), sc_edit_edit_find_replace(), sc_edit_edit_goto_line(), sc_edit_edit_indent_selection(), sc_edit_edit_lower_case(), sc_edit_edit_move_to_brace(), sc_edit_edit_next_bookmark(), sc_edit_edit_preferences(), sc_edit_edit_previous_bookmark(), sc_edit_edit_redo(), sc_edit_edit_remove_bookmark(), sc_edit_edit_select_to_brace(), sc_edit_edit_smart_indent_line_or_selection(), sc_edit_edit_styles_preferences(), sc_edit_edit_toggle_bookmark(), sc_edit_edit_transpose_line(), sc_edit_edit_uncomment_selection(), sc_edit_edit_unindent_selection(), sc_edit_edit_upper_case(), sc_edit_file_close(), sc_edit_file_close_all(), sc_edit_file_close_other(), sc_edit_file_edit_function(), sc_edit_file_print(), sc_edit_file_save(), sc_edit_file_save_as(), sc_edit_help_doc_keyword(), sc_edit_help_help_keyword(), sc_edit_run_run_file(), sc_edit_run_run_selection(), sc_edit_tabs_move_tab_left(), sc_edit_tabs_move_tab_right(), sc_edit_tabs_switch_left_tab(), sc_edit_tabs_switch_right_tab(), sc_edit_view_show_eol_chars(), sc_edit_view_show_hscrollbar(), sc_edit_view_show_ind_guides(), sc_edit_view_show_line_numbers(), sc_edit_view_show_long_line(), sc_edit_view_show_statusbar(), sc_edit_view_show_toolbar(), sc_edit_view_show_white_spaces(), sc_edit_view_sort_tabs(), sc_edit_view_zoom_in(), sc_edit_view_zoom_normal(), sc_edit_view_zoom_out(), sc_main_ctrld(), sc_main_debug_continue(), sc_main_debug_quit(), sc_main_debug_step_into(), sc_main_debug_step_out(), sc_main_debug_step_over(), sc_main_edit_clear_clipboard(), sc_main_edit_clear_command_window(), sc_main_edit_clear_history(), sc_main_edit_clear_workspace(), sc_main_edit_copy(), sc_main_edit_find_in_files(), sc_main_edit_paste(), sc_main_edit_preferences(), sc_main_edit_select_all(), sc_main_edit_set_path(), sc_main_edit_undo(), sc_main_file_exit(), sc_main_file_load_workspace(), sc_main_file_new_figure(), sc_main_file_new_file(), sc_main_file_new_function(), sc_main_file_open_file(), sc_main_file_save_workspace(), sc_main_help_about(), sc_main_help_contribute(), sc_main_help_developer(), sc_main_help_ondisk_doc(), sc_main_help_online_doc(), sc_main_help_packages(), sc_main_help_report_bug(), sc_main_news_community_news(), sc_main_news_release_notes(), sc_main_tools_resume_profiler(), sc_main_tools_show_profiler(), sc_main_tools_start_profiler(), sc_main_window_command(), sc_main_window_doc(), sc_main_window_editor(), sc_main_window_file_browser(), sc_main_window_history(), sc_main_window_previous_dock(), sc_main_window_reset(), sc_main_window_show_command(), sc_main_window_show_doc(), sc_main_window_show_editor(), sc_main_window_show_file_browser(), sc_main_window_show_history(), sc_main_window_show_variable_editor(), sc_main_window_show_workspace(), sc_main_window_variable_editor(), and sc_main_window_workspace().

Referenced by base_qobject::base_qobject(), and main_window::main_window().

◆ operator=()

shortcut_manager& shortcut_manager::operator= ( const shortcut_manager )
delete

◆ overwrite_all_shortcuts()

bool shortcut_manager::overwrite_all_shortcuts ( void  )
private

Definition at line 772 of file shortcut-manager.cc.

References import_export(), and OSC_EXPORT.

Referenced by import_export().

◆ set_shortcut()

◆ shortcut()

void shortcut_manager::shortcut ( QShortcut *  sc,
const sc_pref scpref 
)

◆ shortcut_dialog()

◆ shortcut_dialog_finished

void shortcut_manager::shortcut_dialog_finished ( int  result)
protectedslot

◆ shortcut_dialog_set_default

void shortcut_manager::shortcut_dialog_set_default ( void  )
protectedslot

Definition at line 622 of file shortcut-manager.cc.

References m_edit_actual, and m_label_default.

Referenced by shortcut_dialog().

◆ write_shortcuts()

void shortcut_manager::write_shortcuts ( gui_settings settings,
bool  closing 
)

Member Data Documentation

◆ m_action_hash

QHash<QString, int> shortcut_manager::m_action_hash
private

Definition at line 162 of file shortcut-manager.h.

Referenced by init(), set_shortcut(), and shortcut().

◆ m_dialog

QDialog* shortcut_manager::m_dialog
private

Definition at line 167 of file shortcut-manager.h.

Referenced by fill_treewidget(), shortcut_dialog(), and write_shortcuts().

◆ m_edit_actual

enter_shortcut* shortcut_manager::m_edit_actual
private

◆ m_handled_index

int shortcut_manager::m_handled_index
private

Definition at line 170 of file shortcut-manager.h.

Referenced by shortcut_dialog(), and shortcut_dialog_finished().

◆ m_index_item_hash

QHash<int, QTreeWidgetItem *> shortcut_manager::m_index_item_hash
private

Definition at line 164 of file shortcut-manager.h.

Referenced by fill_treewidget(), import_shortcuts(), and shortcut_dialog_finished().

◆ m_item_index_hash

QHash<QTreeWidgetItem *, int> shortcut_manager::m_item_index_hash
private

Definition at line 165 of file shortcut-manager.h.

Referenced by fill_treewidget(), and handle_double_clicked().

◆ m_label_default

QLabel* shortcut_manager::m_label_default
private

Definition at line 169 of file shortcut-manager.h.

Referenced by shortcut_dialog(), and shortcut_dialog_set_default().

◆ m_level_hash

QHash<QString, QTreeWidgetItem *> shortcut_manager::m_level_hash
private

Definition at line 163 of file shortcut-manager.h.

Referenced by fill_treewidget().

◆ m_octave_qobj

base_qobject& shortcut_manager::m_octave_qobj
private

Definition at line 158 of file shortcut-manager.h.

Referenced by import_export(), init(), init_data(), set_shortcut(), and shortcut().

◆ m_sc

◆ m_shortcut_hash

QHash<QString, int> shortcut_manager::m_shortcut_hash
private

Definition at line 161 of file shortcut-manager.h.

Referenced by init(), and shortcut_dialog_finished().


The documentation for this class was generated from the following files: