*** icon.c	Fri Nov 27 06:21:18 1998
--- icon.c.new	Sat Dec  5 21:57:17 1998
***************
*** 44,49 ****
--- 44,56 ----
  #include "defaults.h"
  #include "appicon.h"
  
+ 
+ #ifdef TITLES_ON_BOTTOM
+ #define Y_COORD wPreferences.icon_size - (height+1)
+ #else
+ #define Y_COORD 0
+ #endif
+ 
  /**** Global variables ****/
  extern WPreferences wPreferences;
  
***************
*** 237,249 ****
  drawIconTitle(WScreen *scr, Pixmap pixmap, int height)
  {
      XFillRectangle(dpy, pixmap, scr->icon_title_texture->normal_gc,
! 		   0, 0, wPreferences.icon_size, height+1);
!     XDrawLine(dpy, pixmap, scr->icon_title_texture->light_gc, 0, 0,
! 	      wPreferences.icon_size, 0);
!     XDrawLine(dpy, pixmap, scr->icon_title_texture->light_gc, 0, 0,
! 	      0, height+1);
      XDrawLine(dpy, pixmap, scr->icon_title_texture->dim_gc, 
! 	      wPreferences.icon_size-1, 0, wPreferences.icon_size-1, height+1);
  }
  
  
--- 244,257 ----
  drawIconTitle(WScreen *scr, Pixmap pixmap, int height)
  {
      XFillRectangle(dpy, pixmap, scr->icon_title_texture->normal_gc,
! 		   0, Y_COORD, wPreferences.icon_size, height+1);
!     XDrawLine(dpy, pixmap, scr->icon_title_texture->light_gc, 0,
! 	      Y_COORD, wPreferences.icon_size, Y_COORD);
!     XDrawLine(dpy, pixmap, scr->icon_title_texture->light_gc, 0,
! 	      Y_COORD, 0, Y_COORD + height+1);
      XDrawLine(dpy, pixmap, scr->icon_title_texture->dim_gc, 
! 	      wPreferences.icon_size-1, Y_COORD, 
! 	      wPreferences.icon_size-1, Y_COORD + height+1);
  }
  
  
***************
*** 276,282 ****
--- 284,294 ----
  	} else {
  	    h = (icon->height+theight > wPreferences.icon_size
  		 ? wPreferences.icon_size-theight : icon->height);
+ #ifdef TITLES_ON_BOTTOM
+ 	    y = ((int)wPreferences.icon_size - icon->height - theight)/2;
+ #else
  	    y = theight+((int)wPreferences.icon_size-theight-h)/2;
+ #endif
  	    sy = (icon->height - h)/2;
  	}
  	RCombineArea(tile, icon, sx, sy, w, h, x, y);
***************
*** 654,660 ****
--- 666,676 ----
  		h = wPreferences.icon_size - title_height - 2;
  		y = title_height + 1;
  	    } else {
+ #ifdef TITLES_ON_BOTTOM
+ 		y = (wPreferences.icon_size-h-title_height)/2 + 1;
+ #else
  		y = (wPreferences.icon_size-h-title_height)/2+title_height + 1;
+ #endif
  	    }
  	} else {
  	    dotitle = 0;
***************
*** 771,778 ****
--- 787,799 ----
  	else
  	  x = (icon->core->width - w)/2;
  
+ #ifdef TITLES_ON_BOTTOM
+  	wDrawString(icon->core->window, scr->icon_title_font, gc, 
+  		      x, icon->core->height - 1, tmp, l);
+ #else
   	wDrawString(icon->core->window, scr->icon_title_font, gc, 
   		      x, 1 + scr->icon_title_font->y, tmp, l);
+ #endif
  	free(tmp);
      }
  
