summaryrefslogtreecommitdiffstats
path: root/thumbs.c
diff options
context:
space:
mode:
authorBert Münnich <ber.t@posteo.de>2016-08-06 15:27:58 +0200
committerBert Münnich <ber.t@posteo.de>2016-08-06 15:27:58 +0200
commitc280129cef4ff2e8667b8700c9bdf671fdd7c8ef (patch)
treef440d93fe935f2e68bb0460927097130160f97f0 /thumbs.c
parentaabc2bddbdeecdb2651394d90b10a9290a69b527 (diff)
downloadnsxiv-c280129cef4ff2e8667b8700c9bdf671fdd7c8ef.tar.zst
Use Xft for font loading and text drawing
Diffstat (limited to 'thumbs.c')
-rw-r--r--thumbs.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/thumbs.c b/thumbs.c
index bfce2ff..f51f85f 100644
--- a/thumbs.c
+++ b/thumbs.c
@@ -480,14 +480,14 @@ void tns_mark(tns_t *tns, int n, bool mark)
if (n >= 0 && n < *tns->cnt && tns->thumbs[n].im != NULL) {
win_t *win = tns->win;
thumb_t *t = &tns->thumbs[n];
- unsigned long col = win->fullscreen ? win->fscol : win->bgcol;
+ unsigned long col = win->fullscreen ? win->fscol.pixel : win->bgcol.pixel;
int x = t->x + t->w, y = t->y + t->h;
win_draw_rect(win, x - 1, y + 1, 1, tns->bw, true, 1, col);
win_draw_rect(win, x + 1, y - 1, tns->bw, 1, true, 1, col);
if (mark)
- col = win->selcol;
+ col = win->selcol.pixel;
win_draw_rect(win, x, y, tns->bw + 2, tns->bw + 2, true, 1, col);
@@ -505,9 +505,9 @@ void tns_highlight(tns_t *tns, int n, bool hl)
int oxy = (tns->bw + 1) / 2 + 1, owh = tns->bw + 2;
if (hl)
- col = win->selcol;
+ col = win->selcol.pixel;
else
- col = win->fullscreen ? win->fscol : win->bgcol;
+ col = win->fullscreen ? win->fscol.pixel : win->bgcol.pixel;
win_draw_rect(win, t->x - oxy, t->y - oxy, t->w + owh, t->h + owh,
false, tns->bw, col);