aboutsummaryrefslogtreecommitdiff
path: root/src/WinClient.hh
diff options
context:
space:
mode:
Diffstat (limited to 'src/WinClient.hh')
-rw-r--r--src/WinClient.hh29
1 files changed, 3 insertions, 26 deletions
diff --git a/src/WinClient.hh b/src/WinClient.hh
index 51d3b3e..9c6dc9e 100644
--- a/src/WinClient.hh
+++ b/src/WinClient.hh
@@ -22,6 +22,7 @@
22#ifndef WINCLIENT_HH 22#ifndef WINCLIENT_HH
23#define WINCLIENT_HH 23#define WINCLIENT_HH
24 24
25#include "FbWinFrame.hh"
25#include "Window.hh" 26#include "Window.hh"
26#include "FbTk/FbWindow.hh" 27#include "FbTk/FbWindow.hh"
27#include "FbTk/FbString.hh" 28#include "FbTk/FbString.hh"
@@ -43,21 +44,6 @@ public:
43 unsigned long decorations; // Motif wm decorations 44 unsigned long decorations; // Motif wm decorations
44 } MwmHints; 45 } MwmHints;
45 46
46 typedef struct SizeHints {
47 unsigned int min_width;
48 unsigned int max_width;
49 unsigned int min_height;
50 unsigned int max_height;
51 unsigned int width_inc;
52 unsigned int height_inc;
53 unsigned int min_aspect_x;
54 unsigned int max_aspect_x;
55 unsigned int min_aspect_y;
56 unsigned int max_aspect_y;
57 unsigned int base_width;
58 unsigned int base_height;
59 } SizeHints;
60
61 WinClient(Window win, BScreen &screen, FluxboxWindow *fbwin = 0); 47 WinClient(Window win, BScreen &screen, FluxboxWindow *fbwin = 0);
62 48
63 ~WinClient(); 49 ~WinClient();
@@ -95,16 +81,6 @@ public:
95 void setAttentionState(bool value); 81 void setAttentionState(bool value);
96 const std::string &title() const { return m_title; } 82 const std::string &title() const { return m_title; }
97 83
98 /**
99 * Changes width and height to the nearest (lower) value
100 * that conforms to it's size hints.
101 *
102 * display_* give the values that would be displayed
103 * to the user when resizing.
104 * We use pointers for display_* since they are optional.
105 */
106 void applySizeHints(int &width, int &height, int *display_width = 0,
107 int *display_height = 0, bool maximizing = false);
108 bool checkSizeHints(unsigned int width, unsigned int height); 84 bool checkSizeHints(unsigned int width, unsigned int height);
109 85
110 void setGroupLeftWindow(Window win); 86 void setGroupLeftWindow(Window win);
@@ -143,6 +119,7 @@ public:
143 Window getGroupLeftWindow() const; 119 Window getGroupLeftWindow() const;
144 120
145 const MwmHints *getMwmHint() const { return m_mwm_hint; } 121 const MwmHints *getMwmHint() const { return m_mwm_hint; }
122 const FbWinFrame::SizeHints &sizeHints() const { return m_size_hints; }
146 123
147 unsigned int minWidth() const { return m_size_hints.min_width; } 124 unsigned int minWidth() const { return m_size_hints.min_width; }
148 unsigned int minHeight() const { return m_size_hints.min_height; } 125 unsigned int minHeight() const { return m_size_hints.min_height; }
@@ -187,7 +164,7 @@ private:
187 164
188 Focusable::WindowType m_window_type; 165 Focusable::WindowType m_window_type;
189 MwmHints *m_mwm_hint; 166 MwmHints *m_mwm_hint;
190 SizeHints m_size_hints; 167 FbWinFrame::SizeHints m_size_hints;
191 168
192 Strut *m_strut; 169 Strut *m_strut;
193 // map transient_for X window to winclient transient 170 // map transient_for X window to winclient transient