… | |
… | |
25 | #include "rxvt.h" /* NECESSARY */ |
25 | #include "rxvt.h" /* NECESSARY */ |
26 | |
26 | |
27 | /*----------------------------------------------------------------------*/ |
27 | /*----------------------------------------------------------------------*/ |
28 | #if defined(RXVT_SCROLLBAR) |
28 | #if defined(RXVT_SCROLLBAR) |
29 | |
29 | |
30 | /* draw triangular button with a shadow of SHADOW (1 or 2) pixels */ |
30 | /* draw triangular button with a shadow of MENU_SHADOW (1 or 2) pixels */ |
31 | void |
31 | void |
32 | rxvt_term::Draw_button (int x, int y, int state, int dirn) |
32 | rxvt_term::Draw_button (int x, int y, int state, int dirn) |
33 | { |
33 | { |
34 | unsigned int sz, sz2; |
34 | unsigned int sz, sz2; |
35 | XPoint pt[3]; |
35 | XPoint pt[3]; |
… | |
… | |
78 | pt[1].x = x + sz2 - 1; |
78 | pt[1].x = x + sz2 - 1; |
79 | pt[1].y = y + (dirn == UP ? 0 : sz - 1); |
79 | pt[1].y = y + (dirn == UP ? 0 : sz - 1); |
80 | XDrawLine (display->display, scrollBar.win, top, |
80 | XDrawLine (display->display, scrollBar.win, top, |
81 | pt[0].x, pt[0].y, pt[1].x, pt[1].y); |
81 | pt[0].x, pt[0].y, pt[1].x, pt[1].y); |
82 | |
82 | |
83 | #if (SHADOW > 1) |
83 | #if (MENU_SHADOW > 1) |
84 | /* doubled */ |
84 | /* doubled */ |
85 | pt[0].x++; |
85 | pt[0].x++; |
86 | |
86 | |
87 | if (dirn == UP) |
87 | if (dirn == UP) |
88 | { |
88 | { |
… | |
… | |
104 | pt[1].y = y + (dirn == UP ? sz - 1 : 0); |
104 | pt[1].y = y + (dirn == UP ? sz - 1 : 0); |
105 | pt[2].y = y + (dirn == UP ? 0 : sz - 1); |
105 | pt[2].y = y + (dirn == UP ? 0 : sz - 1); |
106 | XDrawLine (display->display, scrollBar.win, bot, |
106 | XDrawLine (display->display, scrollBar.win, bot, |
107 | pt[2].x, pt[2].y, pt[1].x, pt[1].y); |
107 | pt[2].x, pt[2].y, pt[1].x, pt[1].y); |
108 | |
108 | |
109 | #if (SHADOW > 1) |
109 | #if (MENU_SHADOW > 1) |
110 | /* doubled */ |
110 | /* doubled */ |
111 | pt[1].x--; |
111 | pt[1].x--; |
112 | if (dirn == UP) |
112 | if (dirn == UP) |
113 | { |
113 | { |
114 | pt[2].y++; |
114 | pt[2].y++; |