#include "find-dialog.h"
Public Slots | |
void | find_next (void) |
void | find_prev (void) |
void | update_edit_area (octave_qscintilla *) |
Slot for updating the edit area when the active tab has changed. More... | |
Public Member Functions | |
find_dialog (base_qobject &oct_qobj, octave_dock_widget *ed, QWidget *p) | |
void | init_search_text (void) |
Init the search text with the selected text in the editor tab. More... | |
void | restore_settings (QPoint def_pos) |
Restore position and the search options from the given settings where def_pos is the default position suitable for the current editor position. More... | |
void | set_visible (bool visible) |
Set dialog visible or not and storing the new visibility state. More... | |
Private Slots | |
void | find (bool forward=true) |
void | handle_backward_search_changed (int) |
void | handle_sel_search_changed (int) |
void | handle_selection_changed (bool has_selected) |
void | replace (void) |
void | replace_all (void) |
Private Member Functions | |
void | closeEvent (QCloseEvent *e) |
Reimplemented close event. More... | |
void | do_replace (void) |
void | handle_replace_text_changed (void) |
void | handle_search_text_changed (void) |
void | mru_update (QComboBox *mru) |
Update mru lists with new entry. More... | |
void | no_matches_message (void) |
void | reject () |
Reimplemented slot: close instead of hiding. More... | |
void | save_settings () |
Save position and the search options in the given settings. More... | |
Private Attributes | |
QCheckBox * | _backward_check_box |
QDialogButtonBox * | _button_box |
QCheckBox * | _case_check_box |
octave_qscintilla * | _edit_area |
QWidget * | _extension |
QPushButton * | _find_next_button |
QPushButton * | _find_prev_button |
bool | _find_result_available |
QCheckBox * | _from_start_check_box |
QPushButton * | _more_button |
QCheckBox * | _regex_check_box |
bool | _rep_active |
int | _rep_all |
QPushButton * | _replace_all_button |
QPushButton * | _replace_button |
QLabel * | _replace_label |
QComboBox * | _replace_line_edit |
QLabel * | _search_label |
QComboBox * | _search_line_edit |
QCheckBox * | _search_selection_check_box |
QCheckBox * | _whole_words_check_box |
QCheckBox * | _wrap_check_box |
octave_dock_widget * | m_editor |
bool | m_in_sel |
QPoint | m_last_position |
const int | m_mru_length = 10 |
base_qobject & | m_octave_qobj |
int | m_sel_beg |
int | m_sel_end |
Definition at line 85 of file find-dialog.h.
octave::find_dialog::find_dialog | ( | base_qobject & | oct_qobj, |
octave_dock_widget * | ed, | ||
QWidget * | p | ||
) |
Definition at line 91 of file find-dialog.cc.
References _backward_check_box, _button_box, _case_check_box, _extension, _find_next_button, _find_prev_button, _find_result_available, _from_start_check_box, _more_button, _regex_check_box, _rep_active, _rep_all, _replace_all_button, _replace_button, _replace_label, _replace_line_edit, _search_label, _search_line_edit, _search_selection_check_box, _whole_words_check_box, _wrap_check_box, find_next(), find_prev(), handle_backward_search_changed(), handle_sel_search_changed(), m_mru_length, replace(), replace_all(), and update_edit_area().
|
private |
Reimplemented close event.
Definition at line 670 of file find-dialog.cc.
References save_settings().
|
private |
Definition at line 590 of file find-dialog.cc.
References _edit_area, _rep_active, _replace_line_edit, _search_line_edit, m_in_sel, and m_sel_end.
Referenced by replace(), and replace_all().
|
privateslot |
Definition at line 437 of file find-dialog.cc.
References _case_check_box, _edit_area, _find_result_available, _from_start_check_box, _regex_check_box, _rep_all, _search_line_edit, _search_selection_check_box, _whole_words_check_box, _wrap_check_box, octave::octave_qscintilla::clear_selection_markers(), handle_search_text_changed(), m_in_sel, m_sel_beg, m_sel_end, no_matches_message(), and octave::octave_qscintilla::show_selection_markers().
Referenced by find_next(), and find_prev().
|
slot |
Definition at line 427 of file find-dialog.cc.
References _backward_check_box, and find().
Referenced by find_dialog(), replace(), and replace_all().
|
slot |
Definition at line 432 of file find-dialog.cc.
References _backward_check_box, and find().
Referenced by find_dialog().
|
privateslot |
Definition at line 320 of file find-dialog.cc.
References _from_start_check_box.
Referenced by find_dialog().
|
private |
Definition at line 342 of file find-dialog.cc.
References _replace_line_edit, and mru_update().
Referenced by replace(), and replace_all().
|
private |
Definition at line 329 of file find-dialog.cc.
References _find_result_available, _search_line_edit, _search_selection_check_box, and mru_update().
Referenced by find().
|
privateslot |
Definition at line 378 of file find-dialog.cc.
References _find_result_available, and _from_start_check_box.
Referenced by find_dialog().
|
privateslot |
Definition at line 384 of file find-dialog.cc.
References _find_result_available, _rep_active, and _search_selection_check_box.
Referenced by update_edit_area().
void octave::find_dialog::init_search_text | ( | void | ) |
Init the search text with the selected text in the editor tab.
Definition at line 394 of file find-dialog.cc.
References _edit_area, _find_next_button, and _search_line_edit.
|
private |
Update mru lists with new entry.
Definition at line 352 of file find-dialog.cc.
References m_mru_length.
Referenced by handle_replace_text_changed(), handle_search_text_changed(), and save_settings().
|
private |
Definition at line 658 of file find-dialog.cc.
Referenced by find().
|
private |
Reimplemented slot: close instead of hiding.
Definition at line 665 of file find-dialog.cc.
|
privateslot |
Definition at line 609 of file find-dialog.cc.
References _edit_area, _find_result_available, do_replace(), find_next(), and handle_replace_text_changed().
Referenced by find_dialog().
|
privateslot |
Definition at line 623 of file find-dialog.cc.
References _edit_area, _find_result_available, _rep_all, _search_selection_check_box, do_replace(), find_next(), and handle_replace_text_changed().
Referenced by find_dialog().
void octave::find_dialog::restore_settings | ( | QPoint | def_pos | ) |
Restore position and the search options from the given settings where def_pos is the default position suitable for the current editor position.
Definition at line 268 of file find-dialog.cc.
References _backward_check_box, _case_check_box, _extension, _from_start_check_box, _regex_check_box, _replace_line_edit, _search_line_edit, _search_selection_check_box, _whole_words_check_box, _wrap_check_box, gui_pref::def, ed_fdlg_opts(), ed_fdlg_pos(), ed_fdlg_replace(), ed_fdlg_search(), FIND_DLG_BACK, FIND_DLG_CASE, FIND_DLG_MORE, FIND_DLG_REGX, FIND_DLG_SEL, FIND_DLG_START, FIND_DLG_WORDS, FIND_DLG_WRAP, octave::base_qobject::get_resource_manager(), octave::resource_manager::get_settings(), gui_pref::key, m_last_position, m_mru_length, m_octave_qobj, and octave::gui_settings::value().
|
private |
Save position and the search options in the given settings.
Definition at line 220 of file find-dialog.cc.
References _backward_check_box, _case_check_box, _extension, _from_start_check_box, _regex_check_box, _replace_line_edit, _search_line_edit, _search_selection_check_box, _whole_words_check_box, _wrap_check_box, ed_fdlg_opts(), ed_fdlg_pos(), ed_fdlg_replace(), ed_fdlg_search(), FIND_DLG_BACK, FIND_DLG_CASE, FIND_DLG_MORE, FIND_DLG_REGX, FIND_DLG_SEL, FIND_DLG_START, FIND_DLG_WORDS, FIND_DLG_WRAP, octave::base_qobject::get_resource_manager(), octave::resource_manager::get_settings(), gui_pref::key, m_last_position, m_octave_qobj, and mru_update().
Referenced by closeEvent().
void octave::find_dialog::set_visible | ( | bool | visible | ) |
Set dialog visible or not and storing the new visibility state.
Definition at line 678 of file find-dialog.cc.
References m_last_position.
|
slot |
Slot for updating the edit area when the active tab has changed.
Definition at line 210 of file find-dialog.cc.
References _edit_area, _search_selection_check_box, and handle_selection_changed().
Referenced by find_dialog().
|
private |
Definition at line 157 of file find-dialog.h.
Referenced by find_dialog(), find_next(), find_prev(), restore_settings(), and save_settings().
|
private |
Definition at line 158 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 151 of file find-dialog.h.
Referenced by find_dialog(), find(), restore_settings(), and save_settings().
|
private |
Definition at line 165 of file find-dialog.h.
Referenced by do_replace(), find(), init_search_text(), replace(), replace_all(), and update_edit_area().
|
private |
Definition at line 164 of file find-dialog.h.
Referenced by find_dialog(), restore_settings(), and save_settings().
|
private |
Definition at line 159 of file find-dialog.h.
Referenced by find_dialog(), and init_search_text().
|
private |
Definition at line 160 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 166 of file find-dialog.h.
Referenced by find_dialog(), find(), handle_search_text_changed(), handle_sel_search_changed(), handle_selection_changed(), replace(), and replace_all().
|
private |
Definition at line 152 of file find-dialog.h.
Referenced by find_dialog(), find(), handle_backward_search_changed(), handle_sel_search_changed(), restore_settings(), and save_settings().
|
private |
Definition at line 163 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 155 of file find-dialog.h.
Referenced by find_dialog(), find(), restore_settings(), and save_settings().
|
private |
Definition at line 168 of file find-dialog.h.
Referenced by find_dialog(), do_replace(), and handle_selection_changed().
|
private |
Definition at line 167 of file find-dialog.h.
Referenced by find_dialog(), find(), and replace_all().
|
private |
Definition at line 162 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 161 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 149 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 150 of file find-dialog.h.
Referenced by find_dialog(), do_replace(), handle_replace_text_changed(), restore_settings(), and save_settings().
|
private |
Definition at line 147 of file find-dialog.h.
Referenced by find_dialog().
|
private |
Definition at line 148 of file find-dialog.h.
Referenced by find_dialog(), do_replace(), find(), handle_search_text_changed(), init_search_text(), restore_settings(), and save_settings().
|
private |
Definition at line 156 of file find-dialog.h.
Referenced by find_dialog(), find(), handle_search_text_changed(), handle_selection_changed(), replace_all(), restore_settings(), save_settings(), and update_edit_area().
|
private |
Definition at line 154 of file find-dialog.h.
Referenced by find_dialog(), find(), restore_settings(), and save_settings().
|
private |
Definition at line 153 of file find-dialog.h.
Referenced by find_dialog(), find(), restore_settings(), and save_settings().
|
private |
Definition at line 145 of file find-dialog.h.
|
private |
Definition at line 170 of file find-dialog.h.
Referenced by do_replace(), and find().
|
private |
Definition at line 174 of file find-dialog.h.
Referenced by restore_settings(), save_settings(), and set_visible().
|
private |
Definition at line 176 of file find-dialog.h.
Referenced by find_dialog(), mru_update(), and restore_settings().
|
private |
Definition at line 125 of file find-dialog.h.
Referenced by restore_settings(), and save_settings().
|
private |
Definition at line 171 of file find-dialog.h.
Referenced by find().
|
private |
Definition at line 172 of file find-dialog.h.
Referenced by do_replace(), and find().