]> git.saurik.com Git - wxWidgets.git/blame - interface/fdrepdlg.h
don't style using Doxygen tags; use <span> tags and CSS instead
[wxWidgets.git] / interface / fdrepdlg.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: fdrepdlg.h
3// Purpose: documentation for wxFindDialogEvent class
4// Author: wxWidgets team
5// RCS-ID: $Id$
6// Licence: wxWindows license
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxFindDialogEvent
11 @wxheader{fdrepdlg.h}
7c913512 12
23324ae1 13 wxFindReplaceDialog events
7c913512 14
23324ae1
FM
15 @library{wxcore}
16 @category{events}
17*/
18class wxFindDialogEvent : public wxCommandEvent
19{
20public:
21 /**
22 Constuctor used by wxWidgets only.
23 */
24 wxFindDialogEvent(wxEventType commandType = wxEVT_@NULL,
25 int id = 0);
26
27 /**
28 Return the pointer to the dialog which generated this event.
29 */
30 wxFindReplaceDialog* GetDialog();
31
32 /**
33 Return the string to find (never empty).
34 */
35 wxString GetFindString();
36
37 /**
38 Get the currently selected flags: this is the combination of @c wxFR_DOWN,
39 @c wxFR_WHOLEWORD and @c wxFR_MATCHCASE flags.
40 */
41 int GetFlags();
42
43 /**
44 Return the string to replace the search string with (only for replace and
45 replace all events).
46 */
47 const wxString GetReplaceString();
48};
49
50
51/**
52 @class wxFindReplaceData
53 @wxheader{fdrepdlg.h}
7c913512
FM
54
55 wxFindReplaceData holds the data for
23324ae1
FM
56 wxFindReplaceDialog. It is used to initialize
57 the dialog with the default values and will keep the last values from the
7c913512 58 dialog when it is closed. It is also updated each time a
23324ae1
FM
59 wxFindDialogEvent is generated so instead of
60 using the wxFindDialogEvent methods you can also directly query this object.
7c913512 61
23324ae1
FM
62 Note that all @c SetXXX() methods may only be called before showing the
63 dialog and calling them has no effect later.
7c913512 64
23324ae1
FM
65 @library{wxcore}
66 @category{FIXME}
67*/
68class wxFindReplaceData : public wxObject
69{
70public:
71 /**
72 Constuctor initializes the flags to default value (0).
73 */
74 wxFindReplaceData(wxUint32 flags = 0);
75
76 /**
77 Get the string to find.
78 */
79 const wxString GetFindString();
80
81 /**
82 Get the combination of @c wxFindReplaceFlags values.
83 */
84 int GetFlags();
85
86 /**
87 Get the replacement string.
88 */
89 const wxString GetReplaceString();
90
91 /**
92 Set the string to find (used as initial value by the dialog).
93 */
94 void SetFindString(const wxString& str);
95
96 /**
97 Set the flags to use to initialize the controls of the dialog.
98 */
99 void SetFlags(wxUint32 flags);
100
101 /**
102 Set the replacement string (used as initial value by the dialog).
103 */
104 void SetReplaceString(const wxString& str);
105};
106
107
108/**
109 @class wxFindReplaceDialog
110 @wxheader{fdrepdlg.h}
7c913512 111
23324ae1
FM
112 wxFindReplaceDialog is a standard modeless dialog which is used to allow the
113 user to search for some text (and possibly replace it with something else).
114 The actual searching is supposed to be done in the owner window which is the
115 parent of this dialog. Note that it means that unlike for the other standard
116 dialogs this one @b must have a parent window. Also note that there is no
117 way to use this dialog in a modal way; it is always, by design and
118 implementation, modeless.
7c913512 119
23324ae1 120 Please see the dialogs sample for an example of using it.
7c913512 121
23324ae1
FM
122 @library{wxcore}
123 @category{cmndlg}
124*/
125class wxFindReplaceDialog : public wxDialog
126{
127public:
128 //@{
129 /**
7c913512 130 After using default constructor Create()
23324ae1
FM
131 must be called.
132
133 The @e parent and @e data parameters must be non-@NULL.
134 */
135 wxFindReplaceDialog();
7c913512
FM
136 wxFindReplaceDialog(wxWindow * parent,
137 wxFindReplaceData* data,
138 const wxString& title,
139 int style = 0);
23324ae1
FM
140 //@}
141
142 /**
143 Destructor.
144 */
145 ~wxFindReplaceDialog();
146
147 /**
148 Creates the dialog; use wxWindow::Show to show it on screen.
149
150 The @e parent and @e data parameters must be non-@NULL.
151 */
152 bool Create(wxWindow * parent, wxFindReplaceData* data,
153 const wxString& title, int style = 0);
154
155 /**
156 Get the wxFindReplaceData object used by this
157 dialog.
158 */
159 const wxFindReplaceData* GetData();
160};