*** empty log message ***
authorroot <root>
Mon, 16 Jan 2006 17:11:12 +0000 (17:11 +0000)
committerroot <root>
Mon, 16 Jan 2006 17:11:12 +0000 (17:11 +0000)
src/Makefile.in
src/misc.C
src/rxvt.h
src/scrollbar-rxvt.C

index 537fabc0589f011b2b978db399f93406da432503..793fd7ece912693f00b67fbb99109fdc105e0aab 100644 (file)
@@ -21,7 +21,7 @@ dummy:
 
 COMMON = \
         command.o rxvtfont.o init.o logging.o main.o misc.o netdisp.o      \
-       ptytty.o screen.o \ scrollbar.o scrollbar-next.o scrollbar-rxvt.o  \
+       ptytty.o screen.o scrollbar.o scrollbar-next.o scrollbar-rxvt.o    \
        scrollbar-xterm.o scrollbar-plain.o xdefaults.o xpm.o encoding.o   \
        rxvttoolkit.o rxvtutil.o iom.o keyboard.o @PERL_O@
 
index 97c4215a4facce288d998b483d157c75629cbdb4..0cb2012628834f4acd4dcf7ad2ecc901e499207c 100644 (file)
@@ -538,32 +538,6 @@ rxvt_File_find (const char *file, const char *ext, const char *path)
 }
 #endif
 
-/*----------------------------------------------------------------------*
- * miscellaneous drawing routines
- */
-
-/*
- * Draw top/left and bottom/right border shadows around windows
- */
-#ifdef RXVT_SCROLLBAR
-void
-rxvt_Draw_Shadow (Display *display, Window win, GC topShadow, GC botShadow, int x, int y, int w, int h)
-{
-  int             shadow;
-
-  shadow = (w == 0 || h == 0) ? 1 : 2;
-  w += x - 1;
-  h += y - 1;
-  for (; shadow-- > 0; x++, y++, w--, h--)
-    {
-      XDrawLine (display, win, topShadow, x, y, w, y);
-      XDrawLine (display, win, topShadow, x, y, x, h);
-      XDrawLine (display, win, botShadow, w, h, w, y + 1);
-      XDrawLine (display, win, botShadow, w, h, x + 1, h);
-    }
-}
-#endif
-
 // should not be used in interactive programs, for obvious reasons
 void rxvt_usleep (int usecs)
 {
index 4fbeb0197c3effd54f869fc4d025d54d547fe445..daf0b2d5d2d2934062a34b5db3f9a049ae6e07c6 100644 (file)
@@ -131,8 +131,6 @@ int              rxvt_Str_escaped                 (char *str);
 char          ** rxvt_splitcommastring            (const char *cs);
 void             rxvt_freecommastring             (char **cs);
 char           * rxvt_File_find                   (const char *file, const char *ext, const char *path);
-void             rxvt_Draw_Shadow                 (Display *display, Window win, GC topShadow, GC botShadow, int x, int y, int w, int h);
-void             rxvt_Draw_Triangle               (Display *display, Window win, GC topShadow, GC botShadow, int x, int y, int w, int type);
 void             rxvt_usleep                      (int usecs);
 
 /////////////////////////////////////////////////////////////////////////////
index 9e1bcf581af43525b7c23972feac94522f2a0d63..87a7c88284e280589f053880755c2d0c641dd478 100644 (file)
 /*----------------------------------------------------------------------*/
 #if defined(RXVT_SCROLLBAR)
 
-#define DOUBLED 1
+#define SHADOW_WIDTH 1
+
+static void  
+rxvt_Draw_Shadow (Display *display, Window win, GC topShadow, GC botShadow, int x, int y, int w, int h)
+{       
+  int             shadow;
+    
+  shadow = (w == 0 || h == 0) ? 1 : SHADOW_WIDTH;
+  w += x - 1;
+  h += y - 1;
+  for (; shadow-- > 0; x++, y++, w--, h--)
+    {     
+      XDrawLine (display, win, topShadow, x, y, w, y);
+      XDrawLine (display, win, topShadow, x, y, x, h);
+      XDrawLine (display, win, botShadow, w, h, w, y + 1);
+      XDrawLine (display, win, botShadow, w, h, x + 1, h);
+    }           
+}                 
 
 /* draw triangular button with a shadow of 2 pixels */
 void
@@ -82,7 +99,7 @@ rxvt_term::Draw_button (int x, int y, int state, int dirn)
   XDrawLine (display->display, scrollBar.win, top,
              pt[0].x, pt[0].y, pt[1].x, pt[1].y);
 
-#if DOUBLED
+#if SHADOW_WIDTH > 1
   /* doubled */
   pt[0].x++;
 
@@ -109,7 +126,7 @@ rxvt_term::Draw_button (int x, int y, int state, int dirn)
   XDrawLine (display->display, scrollBar.win, bot,
              pt[2].x, pt[2].y, pt[1].x, pt[1].y);
 
-#if DOUBLED
+#if SHADOW_WIDTH > 1
   /* doubled */
   pt[1].x--;
   if (dirn == UP)