NCBI C++ ToolKit
Public Types | Public Member Functions | Static Public Member Functions | Private Types | Private Member Functions | Private Attributes | List of all members
CStringConstraintPanel Class Reference

Search Toolkit Book for CStringConstraintPanel

#include <gui/packages/pkg_sequence_edit/string_constraint_panel.hpp>

+ Inheritance diagram for CStringConstraintPanel:
+ Collaboration diagram for CStringConstraintPanel:

Public Types

enum  {
  ID_CSTRINGCONSTRAINTPANEL = 6300 , ID_STRING_CONSTRAINT_MATCH_CHOICE , ID_STRING_CONSTRAINT_MATCH_TEXT , ID_STRING_CONSTRAINT_CHECKBOX5 ,
  ID_STRING_CONSTRAINT_CHECKBOX6 , ID_STRING_CONSTRAINT_CLEAR_BUTTON
}
 

Public Member Functions

 CStringConstraintPanel ()
 Constructors. More...
 
 CStringConstraintPanel (wxWindow *parent, bool parentAECRDlg=false, wxWindowID id=ID_CSTRINGCONSTRAINTPANEL, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(400, 300), long style=wxTAB_TRAVERSAL, bool cap_constraints=false)
 
bool Create (wxWindow *parent, wxWindowID id=ID_CSTRINGCONSTRAINTPANEL, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(400, 300), long style=wxTAB_TRAVERSAL)
 Creation. More...
 
 ~CStringConstraintPanel ()
 Destructor. More...
 
void Init ()
 Initialises member variables. More...
 
void CreateControls ()
 Creates the controls and sizers. More...
 
void OnClear (wxCommandEvent &event)
 
void OnMatchTypeSelected (wxCommandEvent &event)
 
CRef< edit::CStringConstraint > GetStringConstraint ()
 
bool Match (const string &str)
 
string GetMacroStringConstraint (const string &field_name)
 
void SetStringSelection (const wxString &str)
 
void ClearValues (void)
 
void SetChoices (const vector< string > &choices, const vector< string > &values)
 
void ShowChoiceOrText (void)
 
wxBitmap GetBitmapResource (const wxString &name)
 Retrieves bitmap resources. More...
 
wxIcon GetIconResource (const wxString &name)
 Retrieves icon resources. More...
 

Static Public Member Functions

static bool ShowToolTips ()
 Should we show tooltips? More...
 

Private Types

enum  EMatchType {
  eMatchType_Contains = 0 , eMatchType_DoesNotContain , eMatchType_Equals , eMatchType_DoesNotEqual ,
  eMatchType_StartsWith , eMatchType_EndsWith , eMatchType_IsOneOf , eMatchType_IsNotOneOf ,
  eMatchType_DoesNotStartWith , eMatchType_DoesNotEndWith , eMatchType_Is_all_caps , eMatchType_Is_first_each_cap ,
  eMatchType_IsFirstCap
}
 

Private Member Functions

string x_ReplaceChoices (const string &orig)
 

Private Attributes

wxChoice * m_MatchType
 
wxTextCtrl * m_MatchText
 
wxCheckBox * m_IgnoreCase
 
wxCheckBox * m_IgnoreSpace
 
wxComboBox * m_MatchChoice
 
bool m_ParentAECRDlg
 flag is set if parent is the AECRDlg, for having specific features More...
 
bool m_CapConstraints
 
wxBoxSizer * m_TextSizer
 
bool m_is_choice
 
map< string, stringm_ChoiceToValue
 

Detailed Description

CStringConstraintPanel class declaration

Definition at line 75 of file string_constraint_panel.hpp.

Member Enumeration Documentation

◆ anonymous enum

anonymous enum
Enumerator
ID_CSTRINGCONSTRAINTPANEL 
ID_STRING_CONSTRAINT_MATCH_CHOICE 
ID_STRING_CONSTRAINT_MATCH_TEXT 
ID_STRING_CONSTRAINT_CHECKBOX5 
ID_STRING_CONSTRAINT_CHECKBOX6 
ID_STRING_CONSTRAINT_CLEAR_BUTTON 

Definition at line 133 of file string_constraint_panel.hpp.

◆ EMatchType

Enumerator
eMatchType_Contains 
eMatchType_DoesNotContain 
eMatchType_Equals 
eMatchType_DoesNotEqual 
eMatchType_StartsWith 
eMatchType_EndsWith 
eMatchType_IsOneOf 
eMatchType_IsNotOneOf 
eMatchType_DoesNotStartWith 
eMatchType_DoesNotEndWith 
eMatchType_Is_all_caps 
eMatchType_Is_first_each_cap 
eMatchType_IsFirstCap 

Definition at line 143 of file string_constraint_panel.hpp.

Constructor & Destructor Documentation

◆ CStringConstraintPanel() [1/2]

CStringConstraintPanel::CStringConstraintPanel ( )

Constructors.

CStringConstraintPanel type definition

CStringConstraintPanel event table definition

CStringConstraintPanel constructors

Definition at line 63 of file string_constraint_panel.cpp.

References Init().

◆ CStringConstraintPanel() [2/2]

CStringConstraintPanel::CStringConstraintPanel ( wxWindow *  parent,
bool  parentAECRDlg = false,
wxWindowID  id = ID_CSTRINGCONSTRAINTPANEL,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxSize(400,300),
long  style = wxTAB_TRAVERSAL,
bool  cap_constraints = false 
)

◆ ~CStringConstraintPanel()

CStringConstraintPanel::~CStringConstraintPanel ( )

Destructor.

CStringConstraintPanel destructor

Definition at line 102 of file string_constraint_panel.cpp.

Member Function Documentation

◆ ClearValues()

void CStringConstraintPanel::ClearValues ( void  )

◆ Create()

bool CStringConstraintPanel::Create ( wxWindow *  parent,
wxWindowID  id = ID_CSTRINGCONSTRAINTPANEL,
const wxPoint &  pos = wxDefaultPosition,
const wxSize &  size = wxSize(400,300),
long  style = wxTAB_TRAVERSAL 
)

◆ CreateControls()

void CStringConstraintPanel::CreateControls ( )

◆ GetBitmapResource()

wxBitmap CStringConstraintPanel::GetBitmapResource ( const wxString &  name)

Retrieves bitmap resources.

Get bitmap resources

Definition at line 282 of file string_constraint_panel.cpp.

◆ GetIconResource()

wxIcon CStringConstraintPanel::GetIconResource ( const wxString &  name)

Retrieves icon resources.

Get icon resources

Definition at line 295 of file string_constraint_panel.cpp.

◆ GetMacroStringConstraint()

string CStringConstraintPanel::GetMacroStringConstraint ( const string field_name)

◆ GetStringConstraint()

CRef< edit::CStringConstraint > CStringConstraintPanel::GetStringConstraint ( void  )

◆ Init()

void CStringConstraintPanel::Init ( void  )

Initialises member variables.

Member initialisation

Definition at line 113 of file string_constraint_panel.cpp.

References m_IgnoreCase, m_IgnoreSpace, m_is_choice, m_MatchChoice, m_MatchText, m_MatchType, m_TextSizer, and NULL.

Referenced by CStringConstraintPanel().

◆ Match()

bool CStringConstraintPanel::Match ( const string str)

◆ OnClear()

void CStringConstraintPanel::OnClear ( wxCommandEvent &  event)

Definition at line 197 of file string_constraint_panel.cpp.

References ClearValues().

◆ OnMatchTypeSelected()

void CStringConstraintPanel::OnMatchTypeSelected ( wxCommandEvent &  event)

Definition at line 263 of file string_constraint_panel.cpp.

References ShowChoiceOrText().

◆ SetChoices()

void CStringConstraintPanel::SetChoices ( const vector< string > &  choices,
const vector< string > &  values 
)

◆ SetStringSelection()

void CStringConstraintPanel::SetStringSelection ( const wxString &  str)
inline

◆ ShowChoiceOrText()

void CStringConstraintPanel::ShowChoiceOrText ( void  )

◆ ShowToolTips()

bool CStringConstraintPanel::ShowToolTips ( )
static

Should we show tooltips?

Should we show tooltips?

Definition at line 273 of file string_constraint_panel.cpp.

◆ x_ReplaceChoices()

string CStringConstraintPanel::x_ReplaceChoices ( const string orig)
private

Member Data Documentation

◆ m_CapConstraints

bool CStringConstraintPanel::m_CapConstraints
private

Definition at line 171 of file string_constraint_panel.hpp.

Referenced by CreateControls().

◆ m_ChoiceToValue

map<string, string> CStringConstraintPanel::m_ChoiceToValue
private

Definition at line 174 of file string_constraint_panel.hpp.

Referenced by SetChoices(), and x_ReplaceChoices().

◆ m_IgnoreCase

wxCheckBox* CStringConstraintPanel::m_IgnoreCase
private

◆ m_IgnoreSpace

wxCheckBox* CStringConstraintPanel::m_IgnoreSpace
private

◆ m_is_choice

bool CStringConstraintPanel::m_is_choice
private

◆ m_MatchChoice

wxComboBox* CStringConstraintPanel::m_MatchChoice
private

◆ m_MatchText

wxTextCtrl* CStringConstraintPanel::m_MatchText
private

◆ m_MatchType

wxChoice* CStringConstraintPanel::m_MatchType
private

◆ m_ParentAECRDlg

bool CStringConstraintPanel::m_ParentAECRDlg
private

flag is set if parent is the AECRDlg, for having specific features

Definition at line 169 of file string_constraint_panel.hpp.

Referenced by CreateControls().

◆ m_TextSizer

wxBoxSizer* CStringConstraintPanel::m_TextSizer
private

Definition at line 172 of file string_constraint_panel.hpp.

Referenced by ClearValues(), CreateControls(), Init(), and ShowChoiceOrText().


The documentation for this class was generated from the following files:
Modified on Fri Sep 20 14:57:24 2024 by modify_doxy.py rev. 669887