QbBox.h

00001 #ifndef QBBOX_H
00002 #define QBBOX_H
00003 
00004 #include "QbWidget.h"
00005 #include "QbLabel.h"
00006 
00007 class QbBox : public QbWidget {
00008   SO_NODE_HEADER(QbBox);
00009   typedef QbWidget inherited;
00010 public:
00011   static void initClass(void);
00012   QbBox(void);
00013 
00014   virtual void addChild(SoNode *node);
00015   SoChildList * getWidgets(void) const;
00016   QbWidget * getWidget(int index) const;
00017   int getNumWidgets(void) const;
00018 
00019   enum Arrangement {
00020   HORIZONTAL = QbUtility::LEFT,
00021   VERTICAL = QbUtility::TOP };
00022   SoSFEnum arrangement;
00023 
00024   enum Alignment {
00025   TOP = 0, LEFT = 0,
00026   BOTTOM = 1, RIGHT = 1,
00027   MIDDLE = 2, CENTER = 2};
00028   SoSFEnum alignment;
00029 
00030   SoSFFloat margin;
00031   SoSFFloat border;
00032   SoSFString caption;
00033   SoSFFloat captionSize;
00034 
00035   virtual void notify(SoNotList * list);
00036 
00037 protected:
00038   virtual void setWidgetController(QbWidgetController *controller);
00039   ~QbBox(void);
00040 private:
00041   void setBounds();
00042   QbLabel * label;
00043   SoGroup * frame;
00044   bool hasCaption();
00045   void setUpFrame();
00046   static const char * QbBox::defaultFrame[];
00047   static const char * QbBox::defaultFrameNoCaption[];
00048 };
00049 
00050 #endif

Generated on Thu Oct 28 10:59:16 2004 for gitk by doxygen 1.3.6