32 const wxPoint& aPosition,
const wxSize& aSize,
int aStyle ) :
34 wxDEFAULT_DIALOG_STYLE | wxRESIZE_BORDER | aStyle ),
40 wxASSERT_MSG(
m_findReplaceData, wxT(
"can't create find dialog without data" ) );
45 if( aStyle & wxFR_REPLACEDIALOG )
47 SetTitle(
_(
"Find and Replace" ) );
84 wxString hotkeyHint = wxString::Format( wxT(
" (%s)" ),
KeyNameFromKeyCode( hotkey ) );
94 GetSizer()->SetSizeHints(
this );
97 if( aSize != wxDefaultSize )
99 wxSize bestSize = GetBestSize();
101 if( size.GetHeight() != bestSize.GetHeight() )
102 size.SetHeight( bestSize.GetHeight() );
107 GetSizer()->Fit(
this );
163 EndModal( wxID_CANCEL );
176 aEvent.Enable( HasFlag( wxFR_REPLACEDIALOG ) && !
m_comboFind->GetValue().empty()
183 aEvent.Enable( HasFlag( wxFR_REPLACEDIALOG ) && !
m_comboFind->GetValue().empty() );
199 if( aEvent.GetSelection() != 0 )
222 if( aEvent.GetSelection() != 0 )
287 if(
index == wxNOT_FOUND )
291 else if(
index != 0 )
310 if(
index == wxNOT_FOUND )
314 else if(
index != 0 )
323 if( aEvent.GetId() == wxID_REPLACE )
325 else if( aEvent.GetId() == wxID_REPLACE_ALL )
334 if(
index == wxNOT_FOUND )
338 else if(
index != 0 )
356 m_frame->GetFindHistoryList().pop_back();
360 if( !aFindString.IsEmpty() )
379 m_frame->GetFindHistoryList().pop_back();
static TOOL_ACTION replaceAll
static TOOL_ACTION updateFind
static TOOL_ACTION replaceAndFindNext
static TOOL_ACTION findNext
static TOOL_ACTION showSearch
wxCheckBox * m_cbReplaceReferences
wxStaticLine * m_staticline1
wxCheckBox * m_cbSearchHiddenFields
wxStaticText * m_staticReplace
wxRadioButton * m_radioForward
wxCheckBox * m_cbSelectedOnly
wxComboBox * m_comboReplace
wxButton * m_buttonCancel
DIALOG_SCH_FIND_BASE(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &title=_("Find"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(-1,-1), long style=wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER)
wxHyperlinkCtrl * m_searchPanelLink
wxCheckBox * m_cbSearchPins
wxButton * m_buttonReplaceAll
wxCheckBox * m_checkMatchCase
wxRadioButton * m_radioBackward
wxCheckBox * m_cbSearchNetNames
wxButton * m_buttonReplace
wxCheckBox * m_cbCurrentSheetOnly
wxCheckBox * m_checkRegexMatch
wxCheckBox * m_checkWholeWord
void OnSearchForSelect(wxCommandEvent &aEvent) override
void OnReplaceWithEnter(wxCommandEvent &event) override
wxArrayString GetFindEntries() const
void OnIdle(wxIdleEvent &event) override
SCH_FIND_REPLACE_TOOL * m_findReplaceTool
SCH_SEARCH_DATA * m_findReplaceData
void OnUpdateReplaceUI(wxUpdateUIEvent &aEvent) override
void SetReplaceEntries(const wxArrayString &aEntries)
void SetFindEntries(const wxArrayString &aEntries, const wxString &aFindString)
void OnReplaceWithText(wxCommandEvent &aEvent) override
void OnReplaceWithSelect(wxCommandEvent &aEvent) override
DIALOG_SCH_FIND(SCH_BASE_FRAME *aParent, SCH_SEARCH_DATA *aData, const wxPoint &aPosition=wxDefaultPosition, const wxSize &aSize=wxDefaultSize, int aStyle=0)
void OnUpdateReplaceAllUI(wxUpdateUIEvent &aEvent) override
void OnSearchForText(wxCommandEvent &aEvent) override
void OnClose(wxCloseEvent &aEvent) override
void OnReplace(wxCommandEvent &aEvent) override
void OnSearchForEnter(wxCommandEvent &event) override
void OnFind(wxCommandEvent &aEvent) override
void OnCancel(wxCommandEvent &aEvent) override
void OnOptions(wxCommandEvent &event) override
void onShowSearchPanel(wxHyperlinkEvent &event) override
std::vector< wxWindow * > m_tabOrder
void OptOut(wxWindow *aWindow)
Opt out of control state saving.
void SetInitialFocus(wxWindow *aWindow)
Sets the window (usually a wxTextCtrl) that should be focused when the dialog is shown.
A shim class between EDA_DRAW_FRAME and several derived classes: SYMBOL_EDIT_FRAME,...
Schematic editor (Eeschema) main window.
#define SCH_EDIT_FRAME_NAME
@ FRAME_SCH_SYMBOL_EDITOR
wxString KeyNameFromKeyCode(int aKeycode, bool *aIsFound)
Return the key name from the key code.
std::vector< FAB_LAYER_COLOR > dummy