wxMaxima
Loading...
Searching...
No Matches
FindReplaceDialog.h
Go to the documentation of this file.
1// -*- mode: c++; c-file-style: "linux"; c-basic-offset: 2; indent-tabs-mode: nil -*-
2//
3// Copyright (C) 2004-2015 Andrej Vodopivec <andrej.vodopivec@gmail.com>
4// (C) 2012-2013 Doug Ilijev <doug.ilijev@gmail.com>
5// (C) 2015 Gunter Königsmann <wxMaxima@physikbuch.de>
6//
7// This program is free software; you can redistribute it and/or modify
8// it under the terms of the GNU General Public License as published by
9// the Free Software Foundation; either version 2 of the License, or
10// (at your option) any later version.
11//
12// This program is distributed in the hope that it will be useful,
13// but WITHOUT ANY WARRANTY; without even the implied warranty of
14// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15// GNU General Public License for more details.
16//
17//
18// You should have received a copy of the GNU General Public License
19// along with this program; if not, write to the Free Software
20// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21//
22// SPDX-License-Identifier: GPL-2.0+
23
30#ifndef FINDREPLACEDIALOG_H
31#define FINDREPLACEDIALOG_H
32
33#include "precomp.h"
34#include <wx/dialog.h>
35#include <wx/event.h>
36#include <wx/radiobut.h>
37#include "FindReplacePane.h"
38
41class FindReplaceDialog : public wxDialog
42{
43public:
45 const wxString &title,
46 FindReplaceDialog **pointerToDialogue = NULL,
47 int style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER);
48
50
51 void SetFocus() override;
52
54 wxFindReplaceData *GetData()
55 { return m_contents->GetData(); }
56
57 bool GetRegexSearch() const {return m_contents->GetRegexSearch();}
58
60 void SetFindString(const wxString &strng)
61 { m_contents->SetFindString(strng); }
62
63protected:
65 void OnActivateEvent(wxActivateEvent &WXUNUSED(event));
66
68 void OnKeyDown(wxKeyEvent &WXUNUSED(event));
69
76
77private:
78 FindReplaceDialog **m_pointerToDialogue;
80 bool m_activateDuringConstruction;
85 static wxSize m_windowSize;
94 static wxPoint m_windowPos;
95};
96
97#endif // FINDREPLACEDIALOG_H
This file defines the class FindReplacePane.
The find+replace dialog.
Definition: FindReplaceDialog.h:42
wxFindReplaceData * GetData()
Returns the standard wxFindReplaceData data structure.
Definition: FindReplaceDialog.h:54
FindReplacePane * m_contents
The contents of the dialog.
Definition: FindReplaceDialog.h:75
void OnKeyDown(wxKeyEvent &WXUNUSED(event))
We catch a few hot keys here as we don't provide a menu that could declare them.
Definition: FindReplaceDialog.cpp:76
void SetFindString(const wxString &strng)
Set the string we are currently searching for.
Definition: FindReplaceDialog.h:60
void OnActivateEvent(wxActivateEvent &WXUNUSED(event))
Is called if this element looses or gets the focus.
Definition: FindReplaceDialog.cpp:83
Definition: FindReplacePane.h:48
The find+replace pane.
Definition: FindReplacePane.h:44