aboutsummaryrefslogtreecommitdiff
path: root/src/WinButton.hh
diff options
context:
space:
mode:
authormathias <mathias>2005-05-06 18:04:14 (GMT)
committermathias <mathias>2005-05-06 18:04:14 (GMT)
commit4338fbec76d8ca822dcb21c66b6d8e492ee49020 (patch)
treed99a44d5269b244e9fcea2bbddcd170ae91df6e6 /src/WinButton.hh
parent783a3903759117112e4120a5ff47b59f2a67cf06 (diff)
downloadfluxbox_pavel-4338fbec76d8ca822dcb21c66b6d8e492ee49020.zip
fluxbox_pavel-4338fbec76d8ca822dcb21c66b6d8e492ee49020.tar.bz2
Added new Buttons for the Titlebar of a Window (Mathias)
- Shade - just like the "Stick"-button Styleresources: window.shade.pixmap, window.shade.unfocus.pixmap, window.shade.pressed.pixmap window.unshade.pixmap, window.unshade.unfocus.pixmap, window.unshade.pressed.pixmap etc. - MenuIcon - click on it provides the windowmenu, if the app contains a pixmap (gvim, konqueror etc etc) the pixmap is displayed, a little menu otherwise. Styleresources: windowmenu.pixmap, windowmenu.unfocus.pixmap windowmenu.pressed.pixmap etc. Example ~/.fluxbox/init - entry: session.titlebar.left: MenuIcon Stick session.titlebar.right: Shade Minimize Maximize Close hint: if the app HAS a pixmap i use window.title.focus.pixmap (look WinButtonTheme for reference)in pixmap-based-styles. this looks excellent and dont need much extra-code to pipe that info into WinButtons.
Diffstat (limited to 'src/WinButton.hh')
-rw-r--r--src/WinButton.hh11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/WinButton.hh b/src/WinButton.hh
index e0036af..e4482d3 100644
--- a/src/WinButton.hh
+++ b/src/WinButton.hh
@@ -21,8 +21,9 @@
21 21
22/// $Id$ 22/// $Id$
23 23
24#include "Button.hh" 24#include "FbTk/Button.hh"
25#include "Observer.hh" 25#include "FbTk/Observer.hh"
26#include "FbTk/FbPixmap.hh"
26 27
27class FluxboxWindow; 28class FluxboxWindow;
28class WinButtonTheme; 29class WinButtonTheme;
@@ -35,7 +36,7 @@ class Color;
35class WinButton:public FbTk::Button, public FbTk::Observer { 36class WinButton:public FbTk::Button, public FbTk::Observer {
36public: 37public:
37 /// draw type for the button 38 /// draw type for the button
38 enum Type {MAXIMIZE, MINIMIZE, SHADE, STICK, CLOSE}; 39 enum Type {MAXIMIZE, MINIMIZE, SHADE, STICK, CLOSE, MENUICON};
39 WinButton(const FluxboxWindow &listen_to, 40 WinButton(const FluxboxWindow &listen_to,
40 WinButtonTheme &theme, 41 WinButtonTheme &theme,
41 Type buttontype, const FbTk::FbWindow &parent, int x, int y, 42 Type buttontype, const FbTk::FbWindow &parent, int x, int y,
@@ -58,5 +59,9 @@ private:
58 Type m_type; ///< the button type 59 Type m_type; ///< the button type
59 const FluxboxWindow &m_listen_to; 60 const FluxboxWindow &m_listen_to;
60 WinButtonTheme &m_theme; 61 WinButtonTheme &m_theme;
62
63 FbTk::FbPixmap m_icon_pixmap;
64 FbTk::FbPixmap m_icon_mask;
65
61 bool overrode_bg, overrode_pressed; 66 bool overrode_bg, overrode_pressed;
62}; 67};