From cc23d4cd3eb6b98c87f53933510edc53c1513223 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Wed, 19 Dec 2012 15:22:39 +0000 Subject: use DPI for scrollbar width --- source/blender/editors/space_text/text_draw.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/blender/editors/space_text') diff --git a/source/blender/editors/space_text/text_draw.c b/source/blender/editors/space_text/text_draw.c index ce758ddefbd..8e247911597 100644 --- a/source/blender/editors/space_text/text_draw.c +++ b/source/blender/editors/space_text/text_draw.c @@ -49,6 +49,7 @@ #include "UI_interface.h" #include "UI_resources.h" +#include "UI_view2d.h" #include "text_intern.h" #include "text_format.h" @@ -735,12 +736,12 @@ static void calc_text_rcts(SpaceText *st, ARegion *ar, rcti *scroll, rcti *back) blank_lines = st->viewlines / 2; /* nicer code: use scroll rect for entire bar */ - back->xmin = ar->winx - 18; + back->xmin = ar->winx - (V2D_SCROLL_WIDTH + 1); back->xmax = ar->winx; back->ymin = 0; back->ymax = ar->winy; - scroll->xmin = ar->winx - 17; + scroll->xmin = ar->winx - V2D_SCROLL_WIDTH; scroll->xmax = ar->winx - 5; scroll->ymin = 4; scroll->ymax = 4 + pix_available; -- cgit v1.2.3