Mercurial > hg > xemacs-beta
annotate lwlib/xlwscrollbarP.h @ 934:c925bacdda60
[xemacs-hg @ 2002-07-29 09:21:12 by michaels]
2002-07-17 Marcus Crestani <crestani@informatik.uni-tuebingen.de>
Markus Kaltenbach <makalten@informatik.uni-tuebingen.de>
Mike Sperber <mike@xemacs.org>
configure flag to turn these changes on: --use-kkcc
First we added a dumpable flag to lrecord_implementation. It shows,
if the object is dumpable and should be processed by the dumper.
* lrecord.h (struct lrecord_implementation): added dumpable flag
(MAKE_LRECORD_IMPLEMENTATION): fitted the different makro definitions
to the new lrecord_implementation and their calls.
Then we changed mark_object, that it no longer needs a mark method for
those types that have pdump descritions.
* alloc.c:
(mark_object): If the object has a description, the new mark algorithm
is called, and the object is marked according to its description.
Otherwise it uses the mark method like before.
These procedures mark objects according to their descriptions. They
are modeled on the corresponding pdumper procedures.
(mark_with_description):
(get_indirect_count):
(structure_size):
(mark_struct_contents):
These procedures still call mark_object, this is needed while there are
Lisp_Objects without descriptions left.
We added pdump descriptions for many Lisp_Objects:
* extents.c: extent_auxiliary_description
* database.c: database_description
* gui.c: gui_item_description
* scrollbar.c: scrollbar_instance_description
* toolbar.c: toolbar_button_description
* event-stream.c: command_builder_description
* mule-charset.c: charset_description
* device-msw.c: devmode_description
* dialog-msw.c: mswindows_dialog_id_description
* eldap.c: ldap_description
* postgresql.c: pgconn_description
pgresult_description
* tooltalk.c: tooltalk_message_description
tooltalk_pattern_description
* ui-gtk.c: emacs_ffi_description
emacs_gtk_object_description
* events.c:
* events.h:
* event-stream.c:
* event-Xt.c:
* event-gtk.c:
* event-tty.c:
To write a pdump description for Lisp_Event, we converted every struct
in the union event to a Lisp_Object. So we created nine new
Lisp_Objects: Lisp_Key_Data, Lisp_Button_Data, Lisp_Motion_Data,
Lisp_Process_Data, Lisp_Timeout_Data, Lisp_Eval_Data,
Lisp_Misc_User_Data, Lisp_Magic_Data, Lisp_Magic_Eval_Data.
We also wrote makro selectors and mutators for the fields of the new
designed Lisp_Event and added everywhere these new abstractions.
We implemented XD_UNION support in (mark_with_description), so
we can describe exspecially console/device specific data with XD_UNION.
To describe with XD_UNION, we added a field to these objects, which
holds the variant type of the object. This field is initialized in
the appendant constructor. The variant is an integer, it has also to
be described in an description, if XD_UNION is used.
XD_UNION is used in following descriptions:
* console.c: console_description
(get_console_variant): returns the variant
(create_console): added variant initialization
* console.h (console_variant): the different console types
* console-impl.h (struct console): added enum console_variant contype
* device.c: device_description
(Fmake_device): added variant initialization
* device-impl.h (struct device): added enum console_variant devtype
* objects.c: image_instance_description
font_instance_description
(Fmake_color_instance): added variant initialization
(Fmake_font_instance): added variant initialization
* objects-impl.h (struct Lisp_Color_Instance): added color_instance_type
* objects-impl.h (struct Lisp_Font_Instance): added font_instance_type
* process.c: process_description
(make_process_internal): added variant initialization
* process.h (process_variant): the different process types
author | michaels |
---|---|
date | Mon, 29 Jul 2002 09:21:25 +0000 |
parents | 3ecd8885ac67 |
children | ade4c7e2c6cb |
rev | line source |
---|---|
428 | 1 /* Implements a lightweight scrollbar widget. |
2 Copyright (C) 1992, 1993, 1994 Lucid, Inc. | |
3 | |
4 This file is part of the Lucid Widget Library. | |
5 | |
6 The Lucid Widget Library is free software; you can redistribute it and/or | |
7 modify it under the terms of the GNU General Public License as published by | |
8 the Free Software Foundation; either version 2, or (at your option) | |
9 any later version. | |
10 | |
11 The Lucid Widget Library is distributed in the hope that it will be useful, | |
12 but WITHOUT ANY WARRANTY; without even the implied warranty of | |
13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
14 GNU General Public License 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 | |
18 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
19 Boston, MA 02111-1307, USA. */ | |
20 | |
21 /* Created by Douglas Keller <dkeller@vnet.ibm.com> */ | |
22 | |
23 #ifndef _XlwScrollBarP_h | |
24 #define _XlwScrollBarP_h | |
25 | |
26 | |
27 /* | |
28 ** Widget class | |
29 */ | |
30 typedef struct | |
31 { | |
32 int dummy_field; /* keep compiler happy */ | |
33 } XlwScrollBarClassPart; | |
34 | |
35 typedef struct _XlwScrollbarClassRec | |
36 { | |
37 CoreClassPart core_class; | |
38 XlwScrollBarClassPart scrollbar_class; | |
39 } XlwScrollBarClassRec; | |
40 | |
41 enum XlwScrollbarArm | |
42 { | |
43 ARM_NONE, | |
44 ARM_SLIDER, | |
45 ARM_UP, | |
46 ARM_DOWN, | |
47 ARM_PAGEUP, | |
48 ARM_PAGEDOWN | |
49 }; | |
50 | |
51 enum XlwScrollbarForcedScroll | |
52 { | |
53 FORCED_SCROLL_NONE, | |
54 FORCED_SCROLL_DOWNRIGHT, | |
55 FORCED_SCROLL_UPLEFT | |
56 }; | |
57 | |
58 /* | |
59 ** Widget instance | |
60 */ | |
61 typedef struct | |
62 { | |
63 /* resources */ | |
64 XtCallbackList valueChangedCBL; | |
65 XtCallbackList incrementCBL; | |
66 XtCallbackList decrementCBL; | |
67 XtCallbackList pageIncrementCBL; | |
68 XtCallbackList pageDecrementCBL; | |
69 XtCallbackList toTopCBL; | |
70 XtCallbackList toBottomCBL; | |
71 XtCallbackList dragCBL; | |
72 | |
73 Pixel foreground; | |
74 | |
75 Pixel topShadowColor; | |
76 Pixel bottomShadowColor; | |
77 | |
78 Pixel troughColor; | |
79 | |
80 Pixel armColor; | |
81 Pixel armTopShadowColor; | |
82 Pixel armBottomShadowColor; | |
83 | |
84 Pixmap topShadowPixmap; | |
85 Pixmap bottomShadowPixmap; | |
86 | |
87 int shadowThickness; | |
88 | |
89 Boolean showArrows; | |
90 | |
91 int minimum; | |
92 int maximum; | |
93 int sliderSize; | |
94 int value; | |
95 int pageIncrement; | |
96 int increment; | |
97 | |
98 int initialDelay; | |
99 int repeatDelay; | |
100 | |
101 unsigned char orientation; | |
102 | |
103 char *sliderStyle; | |
104 char *knobStyle; | |
105 char *arrowPosition; | |
106 | |
107 /* private */ | |
108 Pixmap grayPixmap; | |
109 | |
110 GC backgroundGC; | |
111 GC topShadowGC; | |
112 GC bottomShadowGC; | |
113 | |
114 int above, ss, below; | |
115 int lastY; | |
116 | |
117 enum XlwScrollbarArm armed; | |
118 | |
119 enum XlwScrollbarForcedScroll forced_scroll; | |
120 | |
121 int savedValue; | |
122 | |
123 Boolean fullRedrawNext; | |
124 | |
125 Boolean timerActive; | |
126 XtIntervalId timerId; | |
127 | |
128 } XlwScrollBarPart; | |
129 | |
130 typedef struct _XlwScrollBarRec | |
131 { | |
132 CorePart core; | |
133 XlwScrollBarPart sb; | |
134 } XlwScrollBarRec; | |
135 | |
136 #endif /* _XlwScrollBarP_h */ |