Mercurial > octave
annotate libgui/src/m-editor/find-dialog.h @ 31647:431f80aba37a
maint: Merge stable to default.
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Tue, 06 Dec 2022 15:37:43 -0500 |
parents | ca7d58406f82 c6d54dd31a7e |
children | deb553ac2c54 |
rev | line source |
---|---|
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
1 // Find dialog derived from an example from Qt Toolkit (license below (**)) |
16520
086b5e81245b
find-dialog: find previous button and initial position next to the editor
Torsten <ttl@justmail.de>
parents:
16511
diff
changeset
|
2 |
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
3 //////////////////////////////////////////////////////////////////////// |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
4 // |
30564
796f54d4ddbf
update Octave Project Developers copyright for the new year
John W. Eaton <jwe@octave.org>
parents:
30398
diff
changeset
|
5 // Copyright (C) 2009-2022 The Octave Project Developers |
27923
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
6 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
7 // See the file COPYRIGHT.md in the top-level directory of this |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
8 // or <https://octave.org/copyright/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
9 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
10 // All rights reserved. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
11 // Contact: Nokia Corporation (qt-info@nokia.com) |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
12 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
13 // This file is part of Octave. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
14 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
15 // Octave is free software: you can redistribute it and/or modify it |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
16 // under the terms of the GNU General Public License as published by |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
17 // the Free Software Foundation, either version 3 of the License, or |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
18 // (at your option) any later version. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
19 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
20 // Octave is distributed in the hope that it will be useful, but |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
21 // WITHOUT ANY WARRANTY; without even the implied warranty of |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
22 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
23 // GNU General Public License for more details. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
24 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
25 // You should have received a copy of the GNU General Public License |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
26 // along with Octave; see the file COPYING. If not, see |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
27 // <https://www.gnu.org/licenses/>. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
28 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
29 // ** This file is part of the examples of the Qt Toolkit. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
30 // ** |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
31 // ** $QT_BEGIN_LICENSE:LGPL$ |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
32 // ** Commercial Usage |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
33 // ** Licensees holding valid Qt Commercial licenses may use this file in |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
34 // ** accordance with the Qt Commercial License Agreement provided with the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
35 // ** Software or, alternatively, in accordance with the terms contained in |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
36 // ** a written agreement between you and Nokia. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
37 // ** |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
38 // ** GNU Lesser General Public License Usage |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
39 // ** Alternatively, this file may be used under the terms of the GNU Lesser |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
40 // ** General Public License version 2.1 as published by the Free Software |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
41 // ** Foundation and appearing in the file LICENSE.LGPL included in the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
42 // ** packaging of this file. Please review the following information to |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
43 // ** ensure the GNU Lesser General Public License version 2.1 requirements |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
44 // ** will be met: https://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
45 // ** |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
46 // ** In addition, as a special exception, Nokia gives you certain additional |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
47 // ** rights. These rights are described in the Nokia Qt LGPL Exception |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
48 // ** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
49 // ** |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
50 // ** GNU General Public License Usage |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
51 // ** Alternatively, this file may be used under the terms of the GNU |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
52 // ** General Public License version 3.0 as published by the Free Software |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
53 // ** Foundation and appearing in the file LICENSE.GPL included in the |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
54 // ** packaging of this file. Please review the following information to |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
55 // ** ensure the GNU General Public License version 3.0 requirements will be |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
56 // ** met: https://www.gnu.org/copyleft/gpl.html. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
57 // ** |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
58 // ** If you have questions regarding the use of this file, please contact |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
59 // ** Nokia at qt-info@nokia.com. |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
60 // ** $QT_END_LICENSE$ |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
61 // |
bd51beb6205e
update formatting of copyright notices
John W. Eaton <jwe@octave.org>
parents:
27919
diff
changeset
|
62 //////////////////////////////////////////////////////////////////////// |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
63 |
21203
710e700cdd7f
maint: Clean up naming and indentation of #ifdef blocks in libgui
Rik <rik@octave.org>
parents:
20946
diff
changeset
|
64 #if ! defined (octave_find_dialog_h) |
710e700cdd7f
maint: Clean up naming and indentation of #ifdef blocks in libgui
Rik <rik@octave.org>
parents:
20946
diff
changeset
|
65 #define octave_find_dialog_h 1 |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
66 |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
67 #include <QDialog> |
27837
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
68 #include <QComboBox> |
27455
e92bab9a7f26
fix editors search and replace in selection (bug #56405)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
69 |
e92bab9a7f26
fix editors search and replace in selection (bug #56405)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
70 #include "octave-qscintilla.h" |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
71 #include "octave-dock-widget.h" |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
72 |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
73 class QCheckBox; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
74 class QDialogButtonBox; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
75 class QGroupBox; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
76 class QLabel; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
77 class QLineEdit; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
78 class QPushButton; |
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
79 |
31646
c6d54dd31a7e
maint: Use macros to begin/end C++ namespaces.
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
80 OCTAVE_BEGIN_NAMESPACE(octave) |
c6d54dd31a7e
maint: Use macros to begin/end C++ namespaces.
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
81 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
82 class file_editor; |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
83 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
84 class find_dialog : public QDialog |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
85 { |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
86 Q_OBJECT |
27089
9326c2258e60
fix visibility of find dialog when editor is docked/undocked (bug #5)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
87 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
88 public: |
27089
9326c2258e60
fix visibility of find dialog when editor is docked/undocked (bug #5)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
89 |
31639
ca7d58406f82
eliminate unnecessary uses of octave_qobject in GUI classes
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
90 find_dialog (octave_dock_widget *ed, QWidget *p); |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
91 |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
92 //! Set dialog visible or not and storing the new visibility state |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
93 void set_visible (bool visible); |
27089
9326c2258e60
fix visibility of find dialog when editor is docked/undocked (bug #5)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
94 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
95 //! Init the search text with the selected text in the editor tab |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
96 void init_search_text (void); |
27089
9326c2258e60
fix visibility of find dialog when editor is docked/undocked (bug #5)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
97 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
98 //! Restore position and the search options from the given settings |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
99 //! where def_pos is the default position suitable for the current |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
100 //! editor position |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
101 void restore_settings (QPoint def_pos); |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
102 |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
103 public slots: |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
104 |
27791
eb64fd6209c2
fix find next/previous buttons of find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27787
diff
changeset
|
105 void find_next (void); |
eb64fd6209c2
fix find next/previous buttons of find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27787
diff
changeset
|
106 void find_prev (void); |
eb64fd6209c2
fix find next/previous buttons of find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27787
diff
changeset
|
107 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
108 //! Slot for updating the edit area when the active tab has changed |
30398
d4d83344d653
maint: style check C++ files in src/ and libgui/ ahead of 7.1 release.
Rik <rik@octave.org>
parents:
30057
diff
changeset
|
109 void update_edit_area (octave_qscintilla *); |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
110 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
111 private slots: |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
112 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
113 void handle_sel_search_changed (int); |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
114 void handle_selection_changed (bool has_selected); |
20276
396e9cd6cd98
Avoid using HAVE_ macros in header file.
John W. Eaton <jwe@octave.org>
parents:
19697
diff
changeset
|
115 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
116 void handle_backward_search_changed (int); |
18854
0a66861d8069
implementation of search in selection in gui editor (bbug #41196)
Torsten <ttl@justmail.de>
parents:
18184
diff
changeset
|
117 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
118 void find (bool forward = true); |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
119 void replace (void); |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
120 void replace_all (void); |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
121 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
122 private: |
18854
0a66861d8069
implementation of search in selection in gui editor (bbug #41196)
Torsten <ttl@justmail.de>
parents:
18184
diff
changeset
|
123 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
124 //! Save position and the search options in the given settings |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
125 void save_settings (); |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
126 |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
127 //! Reimplemented slot: close instead of hiding |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
128 void reject (); |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
129 |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
130 //! Reimplemented close event |
30398
d4d83344d653
maint: style check C++ files in src/ and libgui/ ahead of 7.1 release.
Rik <rik@octave.org>
parents:
30057
diff
changeset
|
131 void closeEvent (QCloseEvent *e); |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
132 |
27837
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
133 //! Update mru lists with new entry |
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
134 void mru_update (QComboBox *mru); |
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
135 |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
136 void no_matches_message (void); |
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
137 void do_replace (void); |
18854
0a66861d8069
implementation of search in selection in gui editor (bbug #41196)
Torsten <ttl@justmail.de>
parents:
18184
diff
changeset
|
138 |
27837
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
139 void handle_search_text_changed (void); |
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
140 void handle_replace_text_changed (void); |
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
141 |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
142 octave_dock_widget *m_editor; |
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
143 |
30057
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
144 QLabel *m_search_label; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
145 QComboBox *m_search_line_edit; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
146 QLabel *m_replace_label; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
147 QComboBox *m_replace_line_edit; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
148 QCheckBox *m_case_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
149 QCheckBox *m_from_start_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
150 QCheckBox *m_wrap_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
151 QCheckBox *m_whole_words_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
152 QCheckBox *m_regex_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
153 QCheckBox *m_search_selection_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
154 QCheckBox *m_backward_check_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
155 QDialogButtonBox *m_button_box; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
156 QPushButton *m_find_next_button; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
157 QPushButton *m_find_prev_button; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
158 QPushButton *m_replace_button; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
159 QPushButton *m_replace_all_button; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
160 QPushButton *m_more_button; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
161 QWidget *m_extension; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
162 octave_qscintilla *m_edit_area; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
163 bool m_find_result_available; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
164 int m_rep_all; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
165 bool m_rep_active; |
27455
e92bab9a7f26
fix editors search and replace in selection (bug #56405)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
26376
diff
changeset
|
166 |
30057
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
167 bool m_in_sel; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
168 int m_sel_beg; |
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
169 int m_sel_end; |
27787
5169ed0ff0f0
only one find dialog for all editor tabs (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27461
diff
changeset
|
170 |
30057
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
171 QPoint m_last_position; |
27837
6bbff502f89d
add mru lists for search/replace texts in editor find dialog (bug #57238)
Torsten Lilge <ttl-octave@mailbox.org>
parents:
27791
diff
changeset
|
172 |
30057
c72ddd9fb513
maint: use "m_" prefix for member variables in class find_dialog
Torsten Lilge <ttl-octave@mailbox.org>
parents:
29358
diff
changeset
|
173 const int m_mru_length = 10; |
24716
2b3e0b570e77
move GUI file editor classes inside octave namespace
John W. Eaton <jwe@octave.org>
parents:
24534
diff
changeset
|
174 }; |
31646
c6d54dd31a7e
maint: Use macros to begin/end C++ namespaces.
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
175 |
c6d54dd31a7e
maint: Use macros to begin/end C++ namespaces.
John W. Eaton <jwe@octave.org>
parents:
30564
diff
changeset
|
176 OCTAVE_END_NAMESPACE(octave) |
15177
d52bac6b9813
find-dialog.{h,cc}: Get rid of DOS newlines
Jordi Gutiérrez Hermoso <jordigh@octave.org>
parents:
15105
diff
changeset
|
177 |
20945
9d9270e2f98f
eliminate comments after preprocessor conditionals
John W. Eaton <jwe@octave.org>
parents:
20276
diff
changeset
|
178 #endif |