00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00047 #ifdef USE_WXWIDGETS
00048
00049 #ifndef __bbwxCommandButton_h_INCLUDED_H__
00050 #define __bbwxCommandButton_h_INCLUDED_H__
00051
00052
00053 #include "bbtkWxBlackBox.h"
00054 #include "bbwx_EXPORT.h"
00055
00056
00057 namespace bbwx
00058 {
00059
00060
00061 class bbwx_EXPORT CommandButton : public bbtk::WxBlackBox
00062 {
00063 friend class CommandButtonWidget;
00064 BBTK_BLACK_BOX_INTERFACE(CommandButton,bbtk::WxBlackBox);
00065 BBTK_DECLARE_INPUT(In, std::string );
00066 BBTK_DECLARE_INPUT(Label, std::string );
00067 BBTK_DECLARE_INPUT(Colour, std::vector<double> );
00068
00069 BBTK_PROCESS(Process);
00070 void Process();
00071 BBTK_CREATE_WIDGET(CreateWidget);
00072 void CreateWidget(wxWindow*);
00073 protected:
00074 virtual void bbUserConstructor();
00075
00076
00077 private:
00078 void UpdateColour();
00079 void UpdateLabel();
00080 };
00081
00082
00083
00084 BBTK_BEGIN_DESCRIBE_BLACK_BOX(CommandButton,bbtk::WxBlackBox);
00085 BBTK_NAME("CommandButton");
00086 BBTK_AUTHOR("eduardo.davila@creatis.insa-lyon.fr");
00087 BBTK_DESCRIPTION("Button which executes bbi commands");
00088
00089 typedef std::vector<double> vectorcolour;
00090
00091 BBTK_INPUT(CommandButton,In,"Commands to be executed separated by commas (;). Each single quote (') is replaced by a double quote (\").",std::string,"");
00092 BBTK_INPUT(CommandButton,Label,"Label of the button",std::string,"");
00093 BBTK_INPUT(CommandButton,Colour,"Colour of the button (-1 -1 -1 Background)",vectorcolour,"colour");
00094
00095 BBTK_END_DESCRIBE_BLACK_BOX(CommandButton);
00096
00097
00098
00099 }
00100
00101 #endif // __bbwxCommandButton_h_INCLUDED_H__
00102
00103 #endif //USE_WXWIDGETS