/[emacs]/emacs/src/xterm.c
ViewVC logotype

Diff of /emacs/src/xterm.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.861 by schwab, Thu Feb 17 12:51:16 2005 UTC revision 1.862 by monnier, Thu Mar 31 22:42:46 2005 UTC
# Line 130  extern void _XEditResCheckMessages (); Line 130  extern void _XEditResCheckMessages ();
130  #ifdef HAVE_XAW3D  #ifdef HAVE_XAW3D
131  #include <X11/Xaw3d/Simple.h>  #include <X11/Xaw3d/Simple.h>
132  #include <X11/Xaw3d/Scrollbar.h>  #include <X11/Xaw3d/Scrollbar.h>
133  #define ARROW_SCROLLBAR  #include <X11/Xaw3d/ThreeD.h>
 #define XAW_ARROW_SCROLLBARS  
 #include <X11/Xaw3d/ScrollbarP.h>  
134  #else /* !HAVE_XAW3D */  #else /* !HAVE_XAW3D */
135  #include <X11/Xaw/Simple.h>  #include <X11/Xaw/Simple.h>
136  #include <X11/Xaw/Scrollbar.h>  #include <X11/Xaw/Scrollbar.h>
# Line 4547  x_create_toolkit_scroll_bar (f, bar) Line 4545  x_create_toolkit_scroll_bar (f, bar)
4545        f->output_data.x->scroll_bar_bottom_shadow_pixel = pixel;        f->output_data.x->scroll_bar_bottom_shadow_pixel = pixel;
4546      }      }
4547    
4548    #ifdef XtNbeNiceToColormap
4549    /* Tell the toolkit about them.  */    /* Tell the toolkit about them.  */
4550    if (f->output_data.x->scroll_bar_top_shadow_pixel == -1    if (f->output_data.x->scroll_bar_top_shadow_pixel == -1
4551        || f->output_data.x->scroll_bar_bottom_shadow_pixel == -1)        || f->output_data.x->scroll_bar_bottom_shadow_pixel == -1)
# Line 4570  x_create_toolkit_scroll_bar (f, bar) Line 4569  x_create_toolkit_scroll_bar (f, bar)
4569        pixel = f->output_data.x->scroll_bar_top_shadow_pixel;        pixel = f->output_data.x->scroll_bar_top_shadow_pixel;
4570        if (pixel != -1)        if (pixel != -1)
4571          {          {
4572            XtSetArg (av[ac], "topShadowPixel", pixel);            XtSetArg (av[ac], XtNtopShadowPixel, pixel);
4573            ++ac;            ++ac;
4574          }          }
4575        pixel = f->output_data.x->scroll_bar_bottom_shadow_pixel;        pixel = f->output_data.x->scroll_bar_bottom_shadow_pixel;
4576        if (pixel != -1)        if (pixel != -1)
4577          {          {
4578            XtSetArg (av[ac], "bottomShadowPixel", pixel);            XtSetArg (av[ac], XtNbottomShadowPixel, pixel);
4579            ++ac;            ++ac;
4580          }          }
4581      }      }
4582    #endif
4583    
4584    widget = XtCreateWidget (scroll_bar_name, scrollbarWidgetClass,    widget = XtCreateWidget (scroll_bar_name, scrollbarWidgetClass,
4585                             f->output_data.x->edit_widget, av, ac);                             f->output_data.x->edit_widget, av, ac);
# Line 4725  x_set_toolkit_scroll_bar_thumb (bar, por Line 4725  x_set_toolkit_scroll_bar_thumb (bar, por
4725            XawScrollbarSetThumb (widget, top, shown);            XawScrollbarSetThumb (widget, top, shown);
4726          else          else
4727            {            {
 #ifdef HAVE_XAW3D  
             ScrollbarWidget sb = (ScrollbarWidget) widget;  
             int scroll_mode = 0;  
   
             /* `scroll_mode' only exists with Xaw3d + ARROW_SCROLLBAR.  */  
             if (xaw3d_arrow_scroll)  
               {  
                 /* Xaw3d stupidly ignores resize requests while dragging  
                    so we have to make it believe it's not in dragging mode.  */  
                 scroll_mode = sb->scrollbar.scroll_mode;  
                 if (scroll_mode == 2)  
                   sb->scrollbar.scroll_mode = 0;  
               }  
 #endif  
4728              /* Try to make the scrolling a tad smoother.  */              /* Try to make the scrolling a tad smoother.  */
4729              if (!xaw3d_pick_top)              if (!xaw3d_pick_top)
4730                shown = min (shown, old_shown);                shown = min (shown, old_shown);
4731    
4732              XawScrollbarSetThumb (widget, top, shown);              XawScrollbarSetThumb (widget, top, shown);
   
 #ifdef HAVE_XAW3D  
             if (xaw3d_arrow_scroll && scroll_mode == 2)  
               sb->scrollbar.scroll_mode = scroll_mode;  
 #endif  
4733            }            }
4734        }        }
4735    }    }

Legend:
Removed from v.1.861  
changed lines
  Added in v.1.862

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26