--- rxvt-unicode/src/scrollbar.h 2007/12/29 14:25:43 1.2 +++ rxvt-unicode/src/scrollbar.h 2008/01/04 17:57:28 1.10 @@ -14,8 +14,14 @@ unsigned int bot; /* slider bottom position */ unsigned int style; /* style: rxvt, xterm, next */ unsigned int width; /* scrollbar width */ - int sb_shadow; /* scrollbar shadow width */ + int shadow; /* scrollbar shadow width */ + int last_bot; /* scrollbar last bottom position */ + int last_top; /* scrollbar last top position */ + int last_state; /* scrollbar last state */ + int len; + unsigned char align; Window win; + Cursor leftptr_cursor; int (rxvt_term::*update)(int, int, int, int); void setIdle() { state = 1 ; } @@ -24,12 +30,11 @@ void setDn() { state = 'D'; } } scrollBar_t; -#define scrollbar_TotalWidth() (scrollBar.width + scrollBar.sb_shadow * 2) +#define scrollbar_TotalWidth() (scrollBar.width + scrollBar.shadow * 2) #define scrollbar_isMotion() (scrollBar.state == 'm') #define scrollbar_isUp() (scrollBar.state == 'U') #define scrollbar_isDn() (scrollBar.state == 'D') -#define scrollbar_isUpDn() isupper (scrollBar.state) -#define isScrollbarWindow(w) (scrollBar.state && (w) == scrollBar.win) +#define scrollbar_isUpDn() (scrollbar_isUp () || scrollbar_isDn ()) #define scrollbarnext_dnval() (scrollBar.end + (scrollBar.width + 1)) #define scrollbarnext_upButton(y) ((y) > scrollBar.end \ @@ -39,7 +44,6 @@ #define scrollbarrxvt_upButton(y) ((y) < scrollBar.beg) #define scrollbarrxvt_dnButton(y) ((y) > scrollBar.end) #define SCROLLRXVT_MINHEIGHT 10 -#define SCROLLXTERM_MINHEIGHT 10 #define scrollbar_minheight() (scrollBar.style == R_SB_NEXT \ ? SCROLLNEXT_MINHEIGHT \