00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #ifndef FXDOCKTITLE_H
00025 #define FXDOCKTITLE_H
00026
00027 #ifndef FXDOCKHANDLER_H
00028 #include "FXDockHandler.h"
00029 #endif
00030
00031 namespace FX {
00032
00033
00039 class FXAPI FXDockTitle : public FXDockHandler {
00040 FXDECLARE(FXDockTitle)
00041 protected:
00042 FXString caption;
00043 FXFont *font;
00044 FXColor captionColor;
00045 protected:
00046 FXDockTitle();
00047 private:
00048 FXDockTitle(const FXDockTitle&);
00049 FXDockTitle& operator=(const FXDockTitle&);
00050 public:
00051 long onPaint(FXObject*,FXSelector,void*);
00052 long onCmdSetValue(FXObject*,FXSelector,void*);
00053 long onCmdSetStringValue(FXObject*,FXSelector,void*);
00054 long onCmdGetStringValue(FXObject*,FXSelector,void*);
00055 public:
00056
00058 FXDockTitle(FXComposite* p,const FXString& text,FXObject* tgt=NULL,FXSelector sel=0,FXuint opts=FRAME_NORMAL|JUSTIFY_CENTER_X|JUSTIFY_CENTER_Y,FXint x=0,FXint y=0,FXint w=0,FXint h=0,FXint pl=0,FXint pr=0,FXint pt=0,FXint pb=0);
00059
00061 virtual void create();
00062
00064 virtual void detach();
00065
00067 virtual FXint getDefaultWidth();
00068
00070 virtual FXint getDefaultHeight();
00071
00073 void setCaption(const FXString& text);
00074
00076 FXString getCaption() const { return caption; }
00077
00079 void setFont(FXFont *fnt);
00080
00082 FXFont* getFont() const { return font; }
00083
00085 FXColor getCaptionColor() const { return captionColor; }
00086
00088 void setCaptionColor(FXColor clr);
00089
00091 void setJustify(FXuint mode);
00092
00094 FXuint getJustify() const;
00095
00097 virtual void save(FXStream& store) const;
00098
00100 virtual void load(FXStream& store);
00101
00103 virtual ~FXDockTitle();
00104 };
00105
00106 }
00107
00108 #endif