aboutsummaryrefslogtreecommitdiff
path: root/src/IconButton.cc
diff options
context:
space:
mode:
authorThomas Lübking <thomas.luebking@gmail.com>2016-08-04 13:20:35 (GMT)
committerThomas Lübking <thomas.luebking@gmail.com>2016-08-06 15:09:30 (GMT)
commitcc80230bd85dbaf1036b4cf37259d3146229fb00 (patch)
treee990270246cf1b07bf5eb6c6ba1ebcd71c9dd8b9 /src/IconButton.cc
parent59d9b0703ba8efb24893528f2eb9c84aaa8f5f83 (diff)
downloadfluxbox-cc80230bd85dbaf1036b4cf37259d3146229fb00.zip
fluxbox-cc80230bd85dbaf1036b4cf37259d3146229fb00.tar.bz2
expose a preferredWidth of *Button's
Diffstat (limited to 'src/IconButton.cc')
-rw-r--r--src/IconButton.cc7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/IconButton.cc b/src/IconButton.cc
index 4997365..4b0b423 100644
--- a/src/IconButton.cc
+++ b/src/IconButton.cc
@@ -279,3 +279,10 @@ bool IconButton::setOrientation(FbTk::Orientation orient) {
279 return false; 279 return false;
280} 280}
281 281
282unsigned int IconButton::preferredWidth() const {
283 unsigned int r = TextButton::preferredWidth();
284 if (m_icon_pixmap.drawable())
285 r += m_icon_window.width() + 1;
286 return r;
287}
288