32 #ifndef SUSPECT_PRODUCT_RULE_EDITOR__HPP
33 #define SUSPECT_PRODUCT_RULE_EDITOR__HPP
58 #include <wx/valtext.h>
59 #include <wx/wxchar.h>
60 #include <wx/choicebk.h>
71 #define ID_SUSPECT_PRODUCT_RULE wxID_ANY
72 #define SYMBOL_SUSPECT_PRODUCT_RULE_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX|wxTAB_TRAVERSAL
73 #define SYMBOL_SUSPECT_PRODUCT_RULE_TITLE _("Suspect Product Rule Editor")
74 #define SYMBOL_SUSPECT_PRODUCT_RULE_IDNAME ID_SUSPECT_PRODUCT_RULE
75 #define SYMBOL_SUSPECT_PRODUCT_RULE_SIZE wxSize(704, 504)
76 #define SYMBOL_SUSPECT_PRODUCT_RULE_POSITION wxDefaultPosition
78 #define ID_LOAD_RULE_LIST_MENU 11401
79 #define ID_ADD_RULE_LIST_MENU 11402
80 #define ID_SAVE_RULE_LIST_MENU 11403
81 #define ID_SAVE_AS_RULE_LIST_MENU 11404
82 #define ID_QUIT_RULE_LIST_MENU 11405
83 #define ID_LIST_MATCHES_RULE_LIST_BUTTON 11406
84 #define ID_APPLY_FIXES_RULE_LIST_BUTTON 11407
85 #define ID_SHOW_DIFFS_RULE_LIST_BUTTON 11410
86 #define ID_DISPLAY_TEXT_RULE_LIST_BUTTON 11411
87 #define ID_ADD_BEFORE_RULE_LIST_BUTTON 11412
88 #define ID_ADD_AFTER_RULE_LIST_BUTTON 11413
89 #define ID_DELETE_SELECTED_RULE_LIST_BUTTON 11414
90 #define ID_SORT_FIND_RULE_LIST_MENU 11415
91 #define ID_SORT_CAT_RULE_LIST_MENU 11416
132 void OnQuit( wxCommandEvent& event );
133 void CanSort(wxUpdateUIEvent &event);
165 #define SYMBOL_CADD_SUSPECT_RULE_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX|wxTAB_TRAVERSAL
166 #define SYMBOL_CADD_SUSPECT_RULE_TITLE _("Suspect Rule")
167 #define SYMBOL_CADD_SUSPECT_RULE_IDNAME wxID_ANY
168 #define SYMBOL_CADD_SUSPECT_RULE_SIZE wxDefaultSize
169 #define SYMBOL_CADD_SUSPECT_RULE_POSITION wxDefaultPosition
176 DECLARE_EVENT_TABLE()
183 bool Create( wxWindow* parent,
205 void OnAccept( wxCommandEvent& event );
206 void OnCancel( wxCommandEvent& event );
234 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_STYLE wxTAB_TRAVERSAL
235 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_TITLE _("StringConstraintPanel")
236 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_IDNAME wxID_ANY
237 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_SIZE wxDefaultSize
238 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_POSITION wxDefaultPosition
239 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_CLEAR_ID 12010
240 #define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_WORD_SUBST_ID 12011
250 DECLARE_EVENT_TABLE()
261 bool Create( wxWindow* parent,
277 void OnClear( wxCommandEvent& event );
299 void SetChoices(
const vector<string> &choices);
348 const wxPoint& pos = wxDefaultPosition,
349 const wxSize&
size = wxDefaultSize,
350 long style = wxTAB_TRAVERSAL)
353 wxPanel::Create( parent,
id, pos,
size, style );
373 const wxPoint& pos = wxDefaultPosition,
374 const wxSize&
size = wxDefaultSize,
375 long style = wxTAB_TRAVERSAL)
378 wxPanel::Create( parent,
id, pos,
size, style );
379 wxBoxSizer* itemBoxSizer2 =
new wxBoxSizer(wxVERTICAL);
380 SetSizer(itemBoxSizer2);
381 m_Text =
new wxTextCtrl(
this,
wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
382 itemBoxSizer2->Add(
m_Text, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
383 m_Text->SetValidator( wxTextValidator( wxFILTER_NUMERIC ) );
386 GetSizer()->SetSizeHints(
this);
396 if (
m_Text->GetValue().IsEmpty())
432 const wxPoint& pos = wxDefaultPosition,
433 const wxSize&
size = wxDefaultSize,
434 long style = wxTAB_TRAVERSAL)
437 wxPanel::Create( parent,
id, pos,
size, style );
438 wxBoxSizer* itemBoxSizer2 =
new wxBoxSizer(wxVERTICAL);
439 SetSizer(itemBoxSizer2);
440 m_Text =
new wxTextCtrl(
this,
wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 );
441 itemBoxSizer2->Add(
m_Text, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5);
444 GetSizer()->SetSizeHints(
this);
454 if (
m_Text->GetValue().IsEmpty())
493 DECLARE_EVENT_TABLE()
498 const wxPoint& pos = wxDefaultPosition,
499 const wxSize&
size = wxDefaultSize,
500 long style = wxTAB_TRAVERSAL);
502 bool Create( wxWindow* parent,
504 const wxPoint& pos = wxDefaultPosition,
505 const wxSize&
size = wxDefaultSize,
506 long style = wxTAB_TRAVERSAL);
521 DECLARE_EVENT_TABLE()
526 const wxPoint& pos = wxDefaultPosition,
527 const wxSize&
size = wxDefaultSize,
528 long style = wxTAB_TRAVERSAL);
530 bool Create( wxWindow* parent,
532 const wxPoint& pos = wxDefaultPosition,
533 const wxSize&
size = wxDefaultSize,
534 long style = wxTAB_TRAVERSAL);
553 DECLARE_EVENT_TABLE()
558 const wxPoint& pos = wxDefaultPosition,
559 const wxSize&
size = wxDefaultSize,
560 long style = wxTAB_TRAVERSAL);
562 bool Create( wxWindow* parent,
564 const wxPoint& pos = wxDefaultPosition,
565 const wxSize&
size = wxDefaultSize,
566 long style = wxTAB_TRAVERSAL);
583 DECLARE_EVENT_TABLE()
588 const wxPoint& pos = wxDefaultPosition,
589 const wxSize&
size = wxDefaultSize,
590 long style = wxTAB_TRAVERSAL);
592 bool Create( wxWindow* parent,
594 const wxPoint& pos = wxDefaultPosition,
595 const wxSize&
size = wxDefaultSize,
596 long style = wxTAB_TRAVERSAL);
User-defined methods of the data storage class.
User-defined methods of the data storage class.
User-defined methods of the data storage class.
wxBitmap GetBitmapResource(const wxString &name)
CRef< CSuspect_rule > m_rule
void SetRule(CRef< CSuspect_rule > rule, int pos)
wxTextCtrl * m_Description
wxIcon GetIconResource(const wxString &name)
CSuspectCompoundConstraintPanel * m_CompoundConstraintPanel
void OnAccept(wxCommandEvent &event)
void OnCancel(wxCommandEvent &event)
wxChoicebook * m_DoesNotMatch
static bool ShowToolTips()
~CAddSuspectProductRule()
objects::CSeq_entry_Handle m_TopSeqEntry
wxCheckBox * m_OriginalToNote
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &caption=_("Suspect Rule"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX|wxTAB_TRAVERSAL)
virtual void SetSearchFunc(const CSearch_func &search_func)
virtual ~CMacroBlankConstraintPanel()
Destructor.
CRef< CSearch_func > m_Search_func
virtual CRef< CSearch_func > GetSearchFunc()
CMacroBlankConstraintPanel(wxWindow *parent, CRef< CSearch_func > search_func, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
wxDECLARE_NO_COPY_CLASS(CMacroBlankConstraintPanel)
CMacroBlankConstraintPanel()
Constructors.
CMacroIntConstraintPanel(wxWindow *parent, CRef< CSearch_func > search_func, int *val, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
virtual ~CMacroIntConstraintPanel()
Destructor.
virtual CRef< CSearch_func > GetSearchFunc()
CMacroIntConstraintPanel()
Constructors.
virtual void SetSearchFunc(const CSearch_func &search_func)
wxDECLARE_NO_COPY_CLASS(CMacroIntConstraintPanel)
CRef< CSearch_func > m_Search_func
virtual void SetSearchFunc(const CSearch_func &search_func)
virtual ~CMacroStrConstraintPanel()
Destructor.
CRef< CSearch_func > m_Search_func
CMacroStrConstraintPanel(wxWindow *parent, CRef< CSearch_func > search_func, string *val, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
wxDECLARE_NO_COPY_CLASS(CMacroStrConstraintPanel)
CMacroStrConstraintPanel()
Constructors.
virtual CRef< CSearch_func > GetSearchFunc()
wxCheckBox * m_IgnoreCase
wxCheckBox * m_IgnorePunct
wxCheckBox * m_IgnoreSpace
wxComboBox * m_MatchChoice
CRef< objects::CWord_substitution_set > m_word_subst
wxRadioButton * m_AllPunct
void SetChoices(const vector< string > &choices)
wxRadioButton * m_AllLower
virtual CRef< CSearch_func > GetSearchFunc()
CRef< objects::CString_constraint > GetStringConstraint()
void CreateControls()
Creates the controls and sizers.
wxIcon GetIconResource(const wxString &name)
Retrieves icon resources.
void Init()
Initialises member variables.
CMacroStringConstraintPanel()
Constructors.
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
Creation.
virtual void AddWordSubstSet(CRef< objects::CWord_substitution_set > word_subst)
wxRadioButton * m_AllUpper
static bool ShowToolTips()
Should we show tooltips?
~CMacroStringConstraintPanel()
Destructor.
void OnWordSubstitution(wxCommandEvent &event)
void OnMatchTypeSelected(wxCommandEvent &event)
wxRadioButton * m_AnyLetters
void ShowChoiceOrText(void)
virtual void SetSearchFunc(const CSearch_func &search_func)
wxBitmap GetBitmapResource(const wxString &name)
Retrieves bitmap resources.
void OnClear(wxCommandEvent &event)
@ eMatchType_DoesNotContain
@ eMatchType_DoesNotEndWith
@ eMatchType_DoesNotEqual
@ eMatchType_DoesNotStartWith
virtual ~CReplace_rule_provider()
virtual void SetReplace(const CReplace_rule &replace)=0
virtual CRef< CReplace_rule > GetReplace()=0
wxBitmap GetBitmapResource(const wxString &name)
virtual void SetReplace(const CReplace_rule &replace)
wxIcon GetIconResource(const wxString &name)
virtual CRef< CReplace_rule > GetReplace()
static bool ShowToolTips()
~CReplacementActionHaem()
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
wxIcon GetIconResource(const wxString &name)
static bool ShowToolTips()
CReplacementActionHypothetical()
wxBitmap GetBitmapResource(const wxString &name)
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
virtual void SetReplace(const CReplace_rule &replace)
~CReplacementActionHypothetical()
virtual CRef< CReplace_rule > GetReplace()
wxBitmap GetBitmapResource(const wxString &name)
virtual CRef< CReplace_rule > GetReplace()
static bool ShowToolTips()
wxIcon GetIconResource(const wxString &name)
~CReplacementActionNone()
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
virtual void SetReplace(const CReplace_rule &replace)
~CReplacementActionSimple()
wxIcon GetIconResource(const wxString &name)
CReplacementActionSimple()
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxDefaultSize, long style=wxTAB_TRAVERSAL)
static bool ShowToolTips()
virtual void SetReplace(const CReplace_rule &replace)
virtual CRef< CReplace_rule > GetReplace()
wxBitmap GetBitmapResource(const wxString &name)
virtual ~CSearch_func_provider()
virtual CRef< CSearch_func > GetSearchFunc()=0
virtual void SetSearchFunc(const CSearch_func &search_func)=0
void OnAddRuleAfter(wxCommandEvent &event)
objects::CSeq_entry_Handle m_TopSeqEntry
virtual ~CSuspectProductRulesEditor()
Destructor.
void OnListMatches(wxCommandEvent &event)
virtual void UpdateCheckedState(size_t checked)
void OnSortByCat(wxCommandEvent &event)
void x_SetUpTSEandUnDoManager()
void ReplaceRule(CRef< CSuspect_rule > rule, int n)
void AddRule(CRef< CSuspect_rule > rule, bool before)
void OnFileAdd(wxCommandEvent &event)
void CreateControls()
Creates the controls and sizers.
wxIcon GetIconResource(const wxString &name)
Retrieves icon resources.
void OnApplyFixes(wxCommandEvent &event)
void OnAddRuleBefore(wxCommandEvent &event)
vector< CRef< CSuspect_rule > > m_Rules
void OnDeleteRules(wxCommandEvent &event)
wxBitmap GetBitmapResource(const wxString &name)
Retrieves bitmap resources.
void CanFileSaveAs(wxUpdateUIEvent &event)
void OnDisplay(wxCommandEvent &event)
void OnShowDiffs(wxCommandEvent &event)
void OnFileSaveAs(wxCommandEvent &event)
bool MatchConstraint(CRef< CSuspect_rule > rule, const string &str)
void OnQuit(wxCommandEvent &event)
void OnFileSave(wxCommandEvent &event)
ICommandProccessor * m_CmdProcessor
bool Create(wxWindow *parent, wxWindowID id=wxID_ANY, const wxString &caption=_("Suspect Product Rule Editor"), const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(704, 504), long style=wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX|wxTAB_TRAVERSAL)
Creation.
void OnFileLoad(wxCommandEvent &event)
void OnSortByFind(wxCommandEvent &event)
wxButton * m_DeleteButton
virtual void DoubleClick(int n)
void CanSort(wxUpdateUIEvent &event)
void Init()
Initialises member variables.
static bool ShowToolTips()
Should we show tooltips?
void CanFileSave(wxUpdateUIEvent &event)
CSuspectProductRulesEditor()
Constructors.
Undo/Redo interface for editing operations.
IWorkbench is the central interface in the application framework.
Include a standard set of the NCBI C++ Toolkit most basic headers.
static const char * str(char *buf, int n)
virtual void Assign(const CSerialObject &source, ESerialRecursionMode how=eRecursive)
Set object to copy of another one.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
static string TruncateSpaces(const string &str, ETrunc where=eTrunc_Both)
Truncate whitespace in a string.
bool IsPrefix_and_numbers(void) const
Check if variant Prefix_and_numbers is selected.
THas_term & SetHas_term(void)
Select the variant.
bool IsToo_long(void) const
Check if variant Too_long is selected.
bool IsN_or_more_brackets_or_parentheses(void) const
Check if variant N_or_more_brackets_or_parentheses is selected.
bool IsHas_term(void) const
Check if variant Has_term is selected.
TPrefix_and_numbers & SetPrefix_and_numbers(void)
Select the variant.
TN_or_more_brackets_or_parentheses & SetN_or_more_brackets_or_parentheses(void)
Select the variant.
TToo_long & SetToo_long(void)
Select the variant.
const struct ncbi::grid::netcache::search::fields::SIZE size
#define SYMBOL_CADD_SUSPECT_RULE_TITLE
#define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_IDNAME
#define SYMBOL_SUSPECT_PRODUCT_RULE_STYLE
#define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_STYLE
#define SYMBOL_CADD_SUSPECT_RULE_IDNAME
#define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_POSITION
#define SYMBOL_CADD_SUSPECT_RULE_SIZE
#define SYMBOL_SUSPECT_PRODUCT_RULE_TITLE
#define SYMBOL_SUSPECT_PRODUCT_RULE_IDNAME
#define SYMBOL_CMACROSTRINGCONSTRAINTPANEL_SIZE
#define SYMBOL_SUSPECT_PRODUCT_RULE_SIZE
#define SYMBOL_CADD_SUSPECT_RULE_STYLE
#define SYMBOL_CADD_SUSPECT_RULE_POSITION
#define SYMBOL_SUSPECT_PRODUCT_RULE_POSITION