Stimfit
0.13.15
|
00001 // This program is free software; you can redistribute it and/or 00002 // modify it under the terms of the GNU General Public License 00003 // as published by the Free Software Foundation; either version 2 00004 // of the License, or (at your option) any later version. 00005 00006 // This program is distributed in the hope that it will be useful, 00007 // but WITHOUT ANY WARRANTY; without even the implied warranty of 00008 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00009 // GNU General Public License for more details. 00010 00011 // You should have received a copy of the GNU General Public License 00012 // along with this program; if not, write to the Free Software 00013 // Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 00014 00021 #ifndef _FITSELDLG_H 00022 #define _FITSELDLG_H 00023 00028 #include <vector> 00029 #include <wx/listctrl.h> 00030 00031 #include "./../../stf.h" 00032 00034 class wxStfFitSelDlg : public wxDialog 00035 { 00036 DECLARE_EVENT_TABLE() 00037 00038 private: 00039 int m_fselect; 00040 Vector_double init_p; 00041 Vector_double opts; 00042 bool noInput, use_scaling; 00043 00044 void SetPars(); 00045 void SetOpts(); 00046 void InitOptions(wxFlexGridSizer* optionsGrid); 00047 void Update_fselect(); 00048 void read_init_p(); 00049 void read_opts(); 00050 static const int MAXPAR=20; 00051 00052 void OnListItemSelected( wxListEvent& event ); 00053 void OnButtonClick( wxCommandEvent& event ); 00054 00055 wxStdDialogButtonSizer* m_sdbSizer; 00056 wxListCtrl* m_listCtrl; 00057 wxTextCtrl *m_textCtrlMu,*m_textCtrlJTE,*m_textCtrlDP,*m_textCtrlE2, 00058 *m_textCtrlMaxiter, *m_textCtrlMaxpasses; 00059 wxCheckBox *m_checkBox; 00060 std::vector< wxStaticText* > paramDescArray; 00061 std::vector< wxTextCtrl* > paramEntryArray; 00062 00063 wxStfDoc* pDoc; 00064 00066 00068 bool OnOK(); 00069 00070 public: 00072 00080 wxStfFitSelDlg( 00081 wxWindow* parent, 00082 wxStfDoc* doc, 00083 int id = wxID_ANY, 00084 wxString title = wxT("Non-linear regression"), 00085 wxPoint pos = wxDefaultPosition, 00086 wxSize size = wxDefaultSize, 00087 int style = wxCAPTION 00088 ); 00089 00091 00094 virtual void EndModal(int retCode); 00095 00097 00099 int GetFSelect() const {return m_fselect;} 00100 00102 00104 Vector_double GetInitP() const {return init_p;} 00105 00107 00109 Vector_double GetOpts() const {return opts;} 00110 00112 00114 bool UseScaling() const {return use_scaling;} 00115 00117 00120 void SetNoInput(bool noInput_) {noInput=noInput_;} 00121 }; 00122 00123 /* @} */ 00124 00125 #endif 00126