summaryrefslogtreecommitdiff
path: root/src/ui
diff options
context:
space:
mode:
authorJaakko Keränen <jaakko.keranen@iki.fi>2021-10-09 12:46:25 +0300
committerJaakko Keränen <jaakko.keranen@iki.fi>2021-10-09 12:46:25 +0300
commit38240ae4887aafccf679295e418faf4727159269 (patch)
tree700652cb3274d11a090dd72362196d249e88cc87 /src/ui
parenteefcb39068773e51a57f908f3f0fe190938b58b2 (diff)
Widget: Keep frame inside the widget area
TODO: Check if this is only applicable to HiDPI.
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/widget.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/ui/widget.c b/src/ui/widget.c
index ec92ac5a..910c31a9 100644
--- a/src/ui/widget.c
+++ b/src/ui/widget.c
@@ -1407,7 +1407,8 @@ void drawBackground_Widget(const iWidget *d) {
1407 fillRect_Paint(&p, rect, d->bgColor); 1407 fillRect_Paint(&p, rect, d->bgColor);
1408 } 1408 }
1409 if (d->frameColor >= 0 && ~d->flags & frameless_WidgetFlag) { 1409 if (d->frameColor >= 0 && ~d->flags & frameless_WidgetFlag) {
1410 drawRectThickness_Paint(&p, rect, gap_UI / 4, d->frameColor); 1410 drawRectThickness_Paint(&p, adjusted_Rect(rect, zero_I2(), neg_I2(one_I2())),
1411 gap_UI / 4, d->frameColor);
1411 } 1412 }
1412 } 1413 }
1413 if (d->flags & (borderTop_WidgetFlag | borderBottom_WidgetFlag)) { 1414 if (d->flags & (borderTop_WidgetFlag | borderBottom_WidgetFlag)) {