home *** CD-ROM | disk | FTP | other *** search
/ Linux Cubed Series 2: Applications / Linux Cubed Series 2 - Applications.iso / editors / emacs / xemacs / xemacs-1.004 / xemacs-1 / xemacs-19.13 / src / scrollbar-x.h < prev    next >
Encoding:
C/C++ Source or Header  |  1995-08-04  |  2.5 KB  |  76 lines

  1. /* Define X-specific scrollbar instance.
  2.    Copyright (C) 1994, 1995 Board of Trustees, University of Illinois
  3.  
  4. This file is part of XEmacs.
  5.  
  6. XEmacs is free software; you can redistribute it and/or modify it
  7. under the terms of the GNU General Public License as published by the
  8. Free Software Foundation; either version 2, or (at your option) any
  9. later version.
  10.  
  11. XEmacs is distributed in the hope that it will be useful, but WITHOUT
  12. ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  13. FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
  14. for more details.
  15.  
  16. You should have received a copy of the GNU General Public License
  17. along with XEmacs; see the file COPYING.  If not, write to the Free
  18. Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.  */
  19.  
  20. /* Synched up with: Not in FSF. */
  21.  
  22. #ifndef _XEMACS_SCROLLBAR_X_H_
  23. #define _XEMACS_SCROLLBAR_X_H_
  24.  
  25. #ifdef HAVE_X_WINDOWS
  26.  
  27. #include "device.h"
  28. #include "xintrinsic.h"
  29. #include "lwlib.h"
  30. #include "scrollbar.h"
  31.  
  32. struct x_scrollbar_data
  33. {
  34.   /* Unique scrollbar identifier and name. */
  35.   unsigned int id;
  36.   char *name;
  37.  
  38.   /* Is set if we have already set the backing_store attribute correctly */
  39.   char backing_store_initialized;
  40.  
  41.   /* Positioning and sizing information for scrollbar and slider. */
  42.   scrollbar_values pos_data;
  43.  
  44.   /* Pointer to the scrollbar widget this structure describes. */
  45.   Widget widget;
  46.  
  47. #if defined (LWLIB_SCROLLBARS_MOTIF) || defined (LWLIB_SCROLLBARS_LUCID)
  48.   /* Recorded starting position for Motif-like scrollbar drags. */
  49.   int vdrag_orig_value;
  50.   Bufpos vdrag_orig_window_start;
  51. #endif
  52. };
  53.  
  54. #define SCROLLBAR_X_DATA(i) ((struct x_scrollbar_data *) ((i)->scrollbar_data))
  55.  
  56. #define SCROLLBAR_X_ID(i) (SCROLLBAR_X_DATA (i)->id)
  57. #define SCROLLBAR_X_NAME(i) (SCROLLBAR_X_DATA (i)->name)
  58. #define SCROLLBAR_X_BACKING_STORE_INITIALIZED(i) \
  59.   (SCROLLBAR_X_DATA (i)->backing_store_initialized)
  60. #define SCROLLBAR_X_POS_DATA(i) (SCROLLBAR_X_DATA (i)->pos_data)
  61. #define SCROLLBAR_X_WIDGET(i) (SCROLLBAR_X_DATA (i)->widget)
  62.  
  63. #if defined (LWLIB_SCROLLBARS_MOTIF) || defined (LWLIB_SCROLLBARS_LUCID)
  64. #define SCROLLBAR_X_VDRAG_ORIG_VALUE(i) \
  65.   (SCROLLBAR_X_DATA (i)->vdrag_orig_value)
  66. #define SCROLLBAR_X_VDRAG_ORIG_WINDOW_START(i) \
  67.   (SCROLLBAR_X_DATA (i)->vdrag_orig_window_start)
  68. #endif
  69.  
  70. extern void x_update_frame_scrollbars (struct frame *f);
  71. extern void x_set_scrollbar_pointer (struct frame *f, Lisp_Object cursor);
  72. extern int x_window_is_scrollbar (struct frame *f, Window win);
  73.  
  74. #endif /* HAVE_X_WINDOWS */
  75. #endif /* _XEMACS_SCROLLBAR_H_ */
  76.