FLTK Utility Library and Widget Collection (FLU): Flu_Label.h Source File

Main Page | Class Hierarchy | Class List | File List | Class Members

# Flu_Label.h

    00001 // $Id: Flu_Label.h,v 1.7 2004/03/28 14:06:57 jbryan Exp $
    00002
    00003 /***************************************************************
    00004  *                FLU - FLTK Utility Widgets
    00005  *  Copyright (C) 2002 Ohio Supercomputer Center, Ohio State University
    00006  *
    00007  * This file and its content is protected by a software license.
    00008  * You should have received a copy of this license with this file.
    00009  * If not, please contact the Ohio Supercomputer Center immediately:
    00010  * Attn: Jason Bryan Re: FLU 1224 Kinnear Rd, Columbus, Ohio 43212
    00011  *
    00012  ***************************************************************/
    00013
    00014
    00015
    00016 #ifndef _FLU_LABEL_H
    00017 #define _FLU_LABEL_H
    00018
    00019 #include <stdlib.h>
    00020 #include <string.h>
    00021 #include <FL/Fl_Box.H>
    00022
    00023 #include "FLU/Flu_Enumerations.h"
    00024
    00026
    00028 class FLU_EXPORT Flu_Label : public Fl_Box
    00029 {
    00030
    00031  public:
    00032
    00034   Flu_Label( int x, int y, int w, int h, const char* l = 0 );
    00035
    00037   virtual ~Flu_Label();
    00038
    00040   void draw();
    00041
    00043   inline void auto_resize( bool b )
    00044     { _autoSize = b; }
    00045
    00047   inline bool auto_resize() const
    00048     { return _autoSize; }
    00049
    00051   inline void value( const char* l )
    00052     { label(l); }
    00053
    00055   inline const char* value() const
    00056     { return _label; }
    00057
    00059   void label( const char* l );
    00060
    00062   inline const char* label() const
    00063     { return _label; }
    00064
    00065  protected:
    00066
    00067   char* _label;
    00068   bool _autoSize;
    00069
    00070 };
    00071
    00072 #endif