Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members

/home/jeroen/FOX/fox/fox-1.7.33/include/FXStatusLine.h
00001 /********************************************************************************
00002 *                                                                               *
00003 *                       S t a t u s L i n e   W i d g e t                       *
00004 *                                                                               *
00005 *********************************************************************************
00006 * Copyright (C) 1999,2012 by Jeroen van der Zijp.   All Rights Reserved.        *
00007 *********************************************************************************
00008 * This library is free software; you can redistribute it and/or modify          *
00009 * it under the terms of the GNU Lesser General Public License as published by   *
00010 * the Free Software Foundation; either version 3 of the License, or             *
00011 * (at your option) any later version.                                           *
00012 *                                                                               *
00013 * This library is distributed in the hope that it will be useful,               *
00014 * but WITHOUT ANY WARRANTY; without even the implied warranty of                *
00015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the                 *
00016 * GNU Lesser General Public License for more details.                           *
00017 *                                                                               *
00018 * You should have received a copy of the GNU Lesser General Public License      *
00019 * along with this program.  If not, see <http://www.gnu.org/licenses/>          *
00020 ********************************************************************************/
00021 #ifndef FXSTATUSLINE_H
00022 #define FXSTATUSLINE_H
00023 
00024 #ifndef FXFRAME_H
00025 #include "FXFrame.h"
00026 #endif
00027 
00028 namespace FX {
00029 
00030 
00050 class FXAPI FXStatusLine : public FXFrame {
00051   FXDECLARE(FXStatusLine)
00052 protected:
00053   FXString  status;             // Current status message
00054   FXString  normal;             // Normally displayed message
00055   FXFont   *font;               // Font
00056   FXColor   textColor;          // Status text color
00057   FXColor   textHighlightColor; // Status text highlight color
00058 protected:
00059   FXStatusLine();
00060 private:
00061   FXStatusLine(const FXStatusLine&);
00062   FXStatusLine& operator=(const FXStatusLine&);
00063 public:
00064   long onPaint(FXObject*,FXSelector,void*);
00065   long onUpdate(FXObject*,FXSelector,void*);
00066   long onCmdGetStringValue(FXObject*,FXSelector,void*);
00067   long onCmdSetStringValue(FXObject*,FXSelector,void*);
00068 public:
00069 
00071   FXStatusLine(FXComposite* p,FXObject* tgt=NULL,FXSelector sel=0);
00072 
00074   virtual void create();
00075 
00077   virtual void detach();
00078 
00080   virtual FXint getDefaultWidth();
00081 
00083   virtual FXint getDefaultHeight();
00084 
00086   void setText(const FXString& text);
00087 
00089   FXString getText() const { return status; }
00090 
00092   void setNormalText(const FXString& text);
00093 
00095   FXString getNormalText() const { return normal; }
00096 
00098   void setFont(FXFont* fnt);
00099 
00101   FXFont* getFont() const { return font; }
00102 
00104   FXColor getTextColor() const { return textColor; }
00105 
00107   void setTextColor(FXColor clr);
00108 
00110   FXColor getTextHighlightColor() const { return textHighlightColor; }
00111 
00113   void setTextHighlightColor(FXColor clr);
00114 
00116   virtual void save(FXStream& store) const;
00117 
00119   virtual void load(FXStream& store);
00120 
00122   virtual ~FXStatusLine();
00123   };
00124 
00125 }
00126 
00127 #endif

Copyright © 1997-2011 Jeroen van der Zijp