button.h

00001 /***************************************************************************
00002                           button.h  -  description
00003                              -------------------
00004     begin                : Wed Jan 28 2004
00005     copyright            : (C) 2004 by Dynacube Team
00006     email                : 
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; either version 2 of the License, or     *
00014  *   (at your option) any later version.                                   *
00015  *                                                                         *
00016  ***************************************************************************/
00017 
00018  #ifndef __BUTTON_H
00019  #define __BUTTON_H
00020 
00021  #ifdef __cplusplus
00022    extern "C"
00023    {
00024      #include "common/ktypes.h"
00025      #include "common/stdlib.h"
00026      #include "gui/graphics.h"
00027      #include "common/string.h"
00028    }
00029  #else
00030       #include "common/ktypes.h"
00031       #include "common/stdlib.h"
00032       #include "gui/graphics.h"
00033       #include "common/string.h"
00034  #endif
00035 
00036  #include "gui/components/component.h"
00037  #include "gui/components/window.h"
00038  #include "gui/components/frame.h"
00039 
00040  #define MIN_BUT_WIDTH 20
00041  #define MIN_BUT_HEIGHT 10
00042  #define BUTTON_COLOR   0xDE99 //0x8BF1 //0xB577 //0xD5F7
00043 
00044  class button:public component
00045  {
00046    public :   
00047    char label[15];
00048    bool state;
00049 
00050    void but_init(DW _id,DW _parent_id,DW _cnt_type,void *_cnt_ptr,DW _alias_id,DW _x,DW _y,DW _width,DW _height,DD _style,char *_label);
00051    void paint();
00052    void react();   
00053  };
00054 
00055 
00056 
00057  #endif

Generated on Thu Jul 27 23:52:25 2006 for Dynacube by  doxygen 1.4.7