NCBI C++ ToolKit
blast_search_params_panel.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 #ifndef PKG_ALIGNMENT___BLAST_SEARCH_PARAMS_PANEL__HPP
2 #define PKG_ALIGNMENT___BLAST_SEARCH_PARAMS_PANEL__HPP
3 
4 /* $Id: blast_search_params_panel.hpp 37403 2017-01-05 18:30:35Z katargir $
5  * ===========================================================================
6  *
7  * PUBLIC DOMAIN NOTICE
8  * National Center for Biotechnology Information
9  *
10  * This software/database is a "United States Government Work" under the
11  * terms of the United States Copyright Act. It was written as part of
12  * the author's official duties as a United States Government employee and
13  * thus cannot be copyrighted. This software/database is freely available
14  * to the public for use. The National Library of Medicine and the U.S.
15  * Government have not placed any restriction on its use or reproduction.
16  *
17  * Although all reasonable efforts have been taken to ensure the accuracy
18  * and reliability of the software and data, the NLM and the U.S.
19  * Government do not and cannot warrant the performance or results that
20  * may be obtained by using this software or data. The NLM and the U.S.
21  * Government disclaim all warranties, express or implied, including
22  * warranties of performance, merchantability or fitness for any particular
23  * purpose.
24  *
25  * Please cite the author in any work or product based on this material.
26  *
27  * ===========================================================================
28  *
29  * Authors: Andrey Yazhuk
30  *
31  * File Description:
32  *
33  */
34 
35 #include <corelib/ncbistd.hpp>
36 
37 ////@begin includes
38 #include "wx/valgen.h"
39 ////@end includes
40 
41 #include <wx/panel.h>
42 #include <wx/choice.h>
43 
47 
48 ////@begin forward declarations
49 class wxFlexGridSizer;
50 ////@end forward declarations
51 
52 class wxButton;
53 class wxStaticText;
54 class wxStaticBox;
55 class wxTextCtrl;
56 class wxComboBox;
57 class wxCheckBox;
58 class wxFlexGridSizer;
59 class wxStaticBoxSizer;
60 
61 
62 ////@begin control identifiers
63 #define SYMBOL_CBLASTSEARCHPARAMSPANEL_STYLE wxTAB_TRAVERSAL
64 #define SYMBOL_CBLASTSEARCHPARAMSPANEL_TITLE _("BLAST Search Params Panel")
65 #define SYMBOL_CBLASTSEARCHPARAMSPANEL_IDNAME ID_CBLASTSEARCHPARAMSPANEL
66 #define SYMBOL_CBLASTSEARCHPARAMSPANEL_SIZE wxSize(400, 300)
67 #define SYMBOL_CBLASTSEARCHPARAMSPANEL_POSITION wxDefaultPosition
68 ////@end control identifiers
69 
70 
72 
73 /** @addtogroup GUI_PKG_ALIGNMENT
74  *
75  * @{
76  */
77 
78 class CObjectListWidget;
79 class CBLASTParams;
80 
81 ///////////////////////////////////////////////////////////////////////////////
82 ///
85 {
86  DECLARE_DYNAMIC_CLASS( CBLASTSearchParamsPanel )
87  DECLARE_EVENT_TABLE()
88 
89 public:
91  CBLASTSearchParamsPanel( wxWindow* parent,
93  const wxPoint& pos = SYMBOL_CBLASTSEARCHPARAMSPANEL_POSITION,
94  const wxSize& size = wxSize(),
96 
97  bool Create( wxWindow* parent,
99  const wxPoint& pos = SYMBOL_CBLASTSEARCHPARAMSPANEL_POSITION,
100  const wxSize& size = wxSize(),
102 
104 
105  void Init();
106 
107  /// @name CTaxIdHelper::ICallback interface implementation
108  /// @{
109  virtual void TaxonsLoaded(bool local);
110  /// @}
111 
112  void CreateControls();
113 
114  bool TransferDataToWindow();
115 
116  bool TransferDataFromWindow();
117 
118  /// @name CAlgoToolManagerParamsPanel implementation
119  virtual void LoadSettings() {}
120  virtual void SaveSettings() const {}
121  void RestoreDefaults();
122  /// @}
123 
124 ////@begin CBLASTSearchParamsPanel event handler declarations
125 
126  void OnRepeatTypeSelected( wxCommandEvent& event );
127 
128  void OnWindowmaskerTaxIdSelected( wxCommandEvent& event );
129 
130  void OnWMDownload( wxCommandEvent& event );
131 
132  void OnStandaloneClick( wxCommandEvent& event );
133 
134 ////@end CBLASTSearchParamsPanel event handler declarations
135 
136 ////@begin CBLASTSearchParamsPanel member function declarations
137 
138  wxString GetAdvParams() const { return m_AdvParams ; }
139  void SetAdvParams(wxString value) { m_AdvParams = value ; }
140 
141  wxString GetDbGeneticCode() const { return m_DbGeneticCode ; }
143 
144  double GetEValue() const { return m_eValue ; }
145  void SetEValue(double value) { m_eValue = value ; }
146 
147  bool GetFilterLowComplex() const { return m_FilterLowComplex ; }
149 
150  wxString GetJobTitle() const { return m_JobTitle ; }
151  void SetJobTitle(wxString value) { m_JobTitle = value ; }
152 
153  wxString GetGeneticCode() const { return m_QueryGeneticCode ; }
155 
156  long GetThreshold() const { return m_Threshold ; }
157  void SetThreshold(long value) { m_Threshold = value ; }
158 
159  long GetWordSize() const { return m_WordSize ; }
160  void SetWordSize(long value) { m_WordSize = value ; }
161 
162  wxBitmap GetBitmapResource( const wxString& name );
163 
164  wxIcon GetIconResource( const wxString& name );
165 ////@end CBLASTSearchParamsPanel member function declarations
166 
167  static bool ShowToolTips();
168 
169 ////@begin CBLASTSearchParamsPanel member variables
170  wxFlexGridSizer* m_GeneralSizer;
171  wxStaticText* m_ThreshLabel;
172  wxTextCtrl* m_ThreshInput;
173  wxStaticText* m_QueryGenCodeLabel;
174  wxComboBox* m_QueryGenCodeCombo;
175  wxStaticText* m_DbGenCodeLabel;
176  wxComboBox* m_DbGenCodeCombo;
177  wxChoice* m_RepeatType;
178  wxCheckBox* m_LCRegionsCheck;
179  wxCheckBox* m_RepeatsCheck;
180  wxStaticBoxSizer* m_WMStaticBoxSizer;
181  wxStaticText* m_WMStatic;
182  wxChoice* m_WMTaxIds;
183  wxButton* m_WMDownload;
184  wxCheckBox* m_CompartCheck;
185  wxCheckBox* m_chbStandalone;
186 protected:
187  wxString m_AdvParams;
188  wxString m_DbGeneticCode;
189  double m_eValue;
191  wxString m_JobTitle;
197  enum {
199  ID_WORDSIZE = 10019,
200  ID_E_VALUE = 10020,
201  ID_THRESHOLD = 10018,
202  ID_GEN_CODE = 10024,
203  ID_COMBOBOX = 10003,
206  ID_REPEAT_TYPE = 10032,
209  ID_WMTI_CHOICE = 10035,
210  ID_BUTTON = 10036,
211  ID_ADV_TEXT = 10008,
213  ID_TITLE_TEXT = 10009,
214  ID_STANDALONE = 10033
215  };
216 ////@end CBLASTSearchParamsPanel member variables
217 
218  enum {
220  ID_LOADING_PROGRESS = 10101
221  };
222 
223 public:
224  void SetParams(CBLASTParams* params);
225 
226 protected:
228  void x_HideShowInputs();
229  void x_UpdateMaskCtrls();
230 
231  void x_InitTaxons();
232  void x_ShowWM(bool show);
233 
234 protected:
236  bool m_Local;
237 
239 };
240 
241 /* @} */
242 
244 
245 #endif
246  // PKG_ALIGNMENT___BLAST_SEARCH_PARAMS_PANEL__HPP
#define SYMBOL_CBLASTSEARCHPARAMSPANEL_STYLE
#define SYMBOL_CBLASTSEARCHPARAMSPANEL_IDNAME
#define SYMBOL_CBLASTSEARCHPARAMSPANEL_POSITION
CAlgoToolManagerParamsPanel.
CBLASTParams - save user-specified parameters and preferences.
CObjectListWidget - mediator widget.
Include a standard set of the NCBI C++ Toolkit most basic headers.
bool Create(wxWindow *parent, wxWindowID id=ID_CBLASTSEARCHPARAMSPANEL, const wxPoint &pos=wxDefaultPosition, const wxSize &size=wxSize(), long style=wxTAB_TRAVERSAL)
virtual void SaveSettings() const
override in derived classes
wxBitmap GetBitmapResource(const wxString &name)
void OnRepeatTypeSelected(wxCommandEvent &event)
void SetParams(CBLASTParams *params)
CTaxIdHelper::CAutoDelete m_AutoDelete
void OnStandaloneClick(wxCommandEvent &event)
wxIcon GetIconResource(const wxString &name)
virtual void TaxonsLoaded(bool local)
void OnWMDownload(wxCommandEvent &event)
void RestoreDefaults()
override in derived classes
void OnWindowmaskerTaxIdSelected(wxCommandEvent &event)
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
const struct ncbi::grid::netcache::search::fields::SIZE size
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
#define local
Definition: zutil.h:33
Modified on Wed Apr 17 13:08:45 2024 by modify_doxy.py rev. 669887