summaryrefslogtreecommitdiff
path: root/libs/gtkmm2ext/barcontroller.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libs/gtkmm2ext/barcontroller.cc')
-rw-r--r--libs/gtkmm2ext/barcontroller.cc8
1 files changed, 5 insertions, 3 deletions
diff --git a/libs/gtkmm2ext/barcontroller.cc b/libs/gtkmm2ext/barcontroller.cc
index f59d192ff1..c3c15b4281 100644
--- a/libs/gtkmm2ext/barcontroller.cc
+++ b/libs/gtkmm2ext/barcontroller.cc
@@ -267,14 +267,12 @@ BarController::expose (GdkEventExpose* event)
gint w, h;
double fract;
- w = darea.get_width() - 2;
- h = darea.get_height() - 2;
-
fract = ((adjustment.get_value() - adjustment.get_lower()) /
(adjustment.get_upper() - adjustment.get_lower()));
switch (_style) {
case Line:
+ w = darea.get_width() - 1;
h = darea.get_height();
x1 = (gint) floor (w * fract);
x2 = x1;
@@ -304,6 +302,10 @@ BarController::expose (GdkEventExpose* event)
break;
case LeftToRight:
+
+ w = darea.get_width() - 2;
+ h = darea.get_height() - 2;
+
x1 = 0;
x2 = (gint) floor (w * fract);
y1 = 0;