]> rtime.felk.cvut.cz Git - l4.git/blob - l4/pkg/dope/server/include/button.h
Inital import
[l4.git] / l4 / pkg / dope / server / include / button.h
1 /*
2  * \brief   Interface of DOpE Button widget module
3  * \date    2002-11-13
4  * \author  Norman Feske <nf2@inf.tu-dresden.de>
5  */
6
7 /*
8  * Copyright (C) 2002-2004  Norman Feske  <nf2@os.inf.tu-dresden.de>
9  * Technische Universitaet Dresden, Operating Systems Research Group
10  *
11  * This file is part of the DOpE package, which is distributed under
12  * the  terms  of the  GNU General Public Licence 2.  Please see the
13  * COPYING file for details.
14  */
15
16 #ifndef _DOPE_BUTTON_H_
17 #define _DOPE_BUTTON_H_
18
19 struct button_methods;
20 struct button_data;
21
22 #define BUTTON struct button
23
24 struct button {
25         struct widget_methods *gen;
26         struct button_methods *but;
27         struct widget_data    *wd;
28         struct button_data    *bd;
29 };
30
31 struct button_methods {
32         void    (*set_text)    (BUTTON *, char *new_txt);
33         char   *(*get_text)    (BUTTON *);
34         void    (*set_font)    (BUTTON *, s32 new_font_id);
35         s32     (*get_font)    (BUTTON *);
36         void    (*set_style)   (BUTTON *, s32 new_style);
37         s32     (*get_style)   (BUTTON *);
38         void    (*set_click)   (BUTTON *, void (*)(BUTTON *));
39         void    (*set_release) (BUTTON *, void (*)(BUTTON *));
40         void    (*set_free_w)  (BUTTON *, int free_w_flag);
41         void    (*set_free_h)  (BUTTON *, int free_h_flag);
42         void    (*set_pad_x)   (BUTTON *, int);
43         void    (*set_pad_y)   (BUTTON *, int);
44 };
45
46 struct button_services {
47         BUTTON *(*create) (void);
48 };
49
50
51 #endif /* _DOPE_BUTTON_H_ */