]> icculus.org git repositories - duncan/yast2-web-wt.git/blob - src/YWebPushButton.h
examples
[duncan/yast2-web-wt.git] / src / YWebPushButton.h
1 /*---------------------------------------------------------------------\
2 |                                                                      |
3 |                      __   __    ____ _____ ____                      |
4 |                      \ \ / /_ _/ ___|_   _|___ \                     |
5 |                       \ V / _` \___ \ | |   __) |                    |
6 |                        | | (_| |___) || |  / __/                     |
7 |                        |_|\__,_|____/ |_| |_____|                    |
8 |                                                                      |
9 |                               core system                            |
10 |                                                        (C) SuSE GmbH |
11 \----------------------------------------------------------------------/
12
13   File:         YWebPushButton.h
14
15   Author:       Stefan Hundhammer <sh@suse.de>
16
17 /-*/
18
19 #ifndef YWebPushButton_h
20 #define YWebPushButton_h
21
22 #include <yui/YPushButton.h>
23
24
25 using std::string;
26
27
28 class YWebPushButton : public YPushButton
29 {
30 public:
31     /**
32      * Constructor.
33      **/
34     YWebPushButton( YWidget * parent, const string & label );
35
36     /**
37      * Destructor.
38      **/
39     ~YWebPushButton();
40
41     /**
42      * Return a descriptive name of this widget class for logging,
43      * debugging etc.
44      **/
45     virtual const char * widgetClass() const { return "YWebPushButton"; }
46
47     /**
48      * Preferred width of the widget.
49      *
50      * Reimplemented from YWidget
51      **/
52     virtual int preferredWidth();
53
54     /**
55      * Preferred height of the widget.
56      *
57      * Reimplemented from YWidget
58      **/
59     virtual int preferredHeight();
60
61     /**
62      * Set the new size of the widget.
63      *
64      * Layout manager widgets (like YLayoutBox) call this during geometry
65      * management after all widgets are queried about their preferred widths
66      * and heights. Depending on layout constraints, widgets might be resized
67      * beyond or below their preferred size.
68      *
69      * The sizes passed here are not meant to affect any future
70      * preferredWidth() or preferredHeight() calls; they are just the outcome
71      * of all kinds of compromises (too little screen space or too much) for
72      * the current geometry management calculation.
73      *
74      * Reimplemented from YWidget
75      **/
76     virtual void setSize( int newWidth, int newHeight );
77
78 };
79
80
81 typedef YWebPushButton YWebIconButton;
82
83
84 #endif // YWebPushButton_h