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

Fl_Bar.h

00001 /*
00002  * $Id: Fl_Bar.h,v 1.8 2003/03/28 21:11:39 parshin Exp $
00003  *
00004  * Extended Fast Light Toolkit (EFLTK)
00005  * Copyright (C) 2002-2003 by EDE-Team
00006  * WWW: http://www.sourceforge.net/projects/ede
00007  *
00008  * Fast Light Toolkit (FLTK)
00009  * Copyright (C) 1998-2003 by Bill Spitzak and others.
00010  * WWW: http://www.fltk.org
00011  *
00012  * This library is distributed under the GNU LIBRARY GENERAL PUBLIC LICENSE
00013  * version 2. See COPYING for details.
00014  *
00015  * Author : Mikko Lahteenmaki
00016  * Email  : mikko@fltk.net
00017  *
00018  * Please report all bugs and problems to "efltk-bugs@fltk.net"
00019  *
00020  */
00021 
00022 #ifndef _FL_BAR_H_
00023 #define _FL_BAR_H_
00024 
00025 #include "Fl_Group.h"
00026 
00028 class FL_API Fl_Bar : public Fl_Group {
00029 public:
00030     static Fl_Named_Style* default_style;
00031 
00033     Fl_Bar(int x,int y,int w ,int h,const char *l = 0);
00035     Fl_Bar(const char* l = 0,int layout_size=30,Fl_Align layout_al=FL_ALIGN_TOP,int label_w=100);
00036 
00037     // values for type(int)
00038     enum {
00039         VERTICAL    = GROUP_TYPE,
00040         HORIZONTAL  = GROUP_TYPE+1
00041     };
00042 
00043     void layout();
00044     int handle(int);
00045     void draw();
00046     bool opened() const {return open_;}
00047     bool opened(bool);
00048     bool open() {return opened(true);}
00049     bool close() {return opened(false);}
00050     int glyph_size() const {return glyph_size_;}
00051     void glyph_size(int v) {glyph_size_ = v;}
00052 
00053 protected:
00054     bool highlighted;
00055     bool pushed;
00056 
00057 private:
00058     void ctor_init(int h);
00059 
00060     bool open_;
00061     int glyph_size_;
00062     int saved_size;
00063     void glyph_box(int& x, int& y, int& w, int& h);
00064 };
00065 
00066 #endif

Generated on Thu Jul 31 15:33:43 2003 for eFLTK by doxygen1.2.15