0
|
1 /* Define X specific console, device, and frame object for XEmacs.
|
|
2 Copyright (C) 1989, 1992, 1993, 1994, 1995 Free Software Foundation, Inc.
|
|
3 Copyright (C) 1994, 1995 Board of Trustees, University of Illinois.
|
|
4
|
|
5 This file is part of XEmacs.
|
|
6
|
|
7 XEmacs is free software; you can redistribute it and/or modify it
|
|
8 under the terms of the GNU General Public License as published by the
|
|
9 Free Software Foundation; either version 2, or (at your option) any
|
|
10 later version.
|
|
11
|
|
12 XEmacs is distributed in the hope that it will be useful, but WITHOUT
|
|
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
|
|
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
|
|
15 for more details.
|
|
16
|
|
17 You should have received a copy of the GNU General Public License
|
|
18 along with XEmacs; see the file COPYING. If not, write to
|
|
19 the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
20 Boston, MA 02111-1307, USA. */
|
|
21
|
|
22 /* Synched up with: Not in FSF. */
|
|
23
|
|
24
|
|
25 /* Authorship:
|
|
26
|
|
27 Ultimately based on FSF, then later on JWZ work for Lemacs.
|
|
28 Rewritten over time by Ben Wing and Chuck Thompson (original
|
|
29 multi-device work by Chuck Thompson).
|
|
30 */
|
|
31
|
|
32 #ifndef _XEMACS_CONSOLE_X_H_
|
|
33 #define _XEMACS_CONSOLE_X_H_
|
|
34
|
|
35 #ifdef HAVE_X_WINDOWS
|
|
36
|
|
37 #include "console.h"
|
|
38 #include "xintrinsic.h"
|
|
39
|
|
40 #include <X11/cursorfont.h>
|
|
41 #include <X11/keysym.h>
|
|
42 #include <X11/Xatom.h>
|
|
43
|
|
44 #ifdef USG
|
|
45 #undef USG /* ####KLUDGE for Solaris 2.2 and up */
|
|
46 #include <X11/Xos.h>
|
|
47 #define USG
|
|
48 #else
|
|
49 #include <X11/Xos.h>
|
|
50 #endif
|
|
51
|
|
52 #include <X11/StringDefs.h>
|
|
53
|
|
54 #ifdef HAVE_XPM
|
|
55 #include <X11/xpm.h>
|
|
56 #endif
|
|
57
|
|
58 /* R5 defines the XPointer type, but R4 doesn't.
|
|
59 R4 also doesn't define a version number, but R5 does. */
|
|
60 #if (XlibSpecificationRelease < 5)
|
|
61 # define XPointer char *
|
|
62 #endif
|
|
63
|
|
64 DECLARE_CONSOLE_TYPE (x);
|
|
65
|
|
66 struct x_device
|
|
67 {
|
|
68 /* The X connection of this device. */
|
|
69 Display *display;
|
|
70
|
|
71 /* Xt application info. */
|
|
72 Widget Xt_app_shell;
|
|
73
|
|
74 /* Cache of GC's for frame's on this device. */
|
|
75 struct gc_cache *gc_cache;
|
|
76
|
|
77 /* Used by x_bevel_modeline in redisplay-x.c */
|
|
78 Pixmap gray_pixmap;
|
|
79
|
|
80 /* Atoms associated with this device. */
|
|
81 /* allocated in Xatoms_of_xfns in xfns.c */
|
|
82 Atom Xatom_WM_PROTOCOLS;
|
|
83 Atom Xatom_WM_DELETE_WINDOW;
|
|
84 Atom Xatom_WM_SAVE_YOURSELF;
|
|
85 Atom Xatom_WM_TAKE_FOCUS;
|
|
86 Atom Xatom_WM_STATE;
|
|
87
|
|
88 /* allocated in Xatoms_of_xselect in xselect.c */
|
|
89 Atom Xatom_CLIPBOARD;
|
|
90 Atom Xatom_TIMESTAMP;
|
|
91 Atom Xatom_TEXT;
|
|
92 Atom Xatom_DELETE;
|
|
93 Atom Xatom_MULTIPLE;
|
|
94 Atom Xatom_INCR;
|
|
95 Atom Xatom_EMACS_TMP;
|
|
96 Atom Xatom_TARGETS;
|
|
97 Atom Xatom_NULL;
|
|
98 Atom Xatom_ATOM_PAIR;
|
|
99 Atom Xatom_COMPOUND_TEXT;
|
|
100
|
|
101 /* allocated in Xatoms_of_objects_x in objects-x.c */
|
|
102 Atom Xatom_FOUNDRY;
|
|
103 Atom Xatom_FAMILY_NAME;
|
|
104 Atom Xatom_WEIGHT_NAME;
|
|
105 Atom Xatom_SLANT;
|
|
106 Atom Xatom_SETWIDTH_NAME;
|
|
107 Atom Xatom_ADD_STYLE_NAME;
|
|
108 Atom Xatom_PIXEL_SIZE;
|
|
109 Atom Xatom_POINT_SIZE;
|
|
110 Atom Xatom_RESOLUTION_X;
|
|
111 Atom Xatom_RESOLUTION_Y;
|
|
112 Atom Xatom_SPACING;
|
|
113 Atom Xatom_AVERAGE_WIDTH;
|
|
114 Atom Xatom_CHARSET_REGISTRY;
|
|
115 Atom Xatom_CHARSET_ENCODING;
|
|
116
|
|
117 /* The following items are all used exclusively in event-Xt.c. */
|
|
118 int MetaMask, HyperMask, SuperMask, AltMask, ModeMask;
|
|
119 KeySym lock_interpretation;
|
|
120
|
|
121 XModifierKeymap *x_modifier_keymap;
|
|
122
|
|
123 KeySym *x_keysym_map;
|
|
124 int x_keysym_map_min_code;
|
|
125 int x_keysym_map_keysyms_per_code;
|
|
126
|
|
127 /* frame that holds the WM_COMMAND property; there should be exactly
|
|
128 one of these per device. */
|
|
129 Lisp_Object WM_COMMAND_frame;
|
|
130
|
|
131 /* #### It's not clear that there is much distinction anymore
|
|
132 between mouse_timestamp and global_mouse_timestamp, now that
|
|
133 Emacs doesn't see most (all?) events not destined for it. */
|
|
134
|
|
135 /* The timestamp of the last button or key event used by emacs itself.
|
|
136 This is used for asserting selections and input focus. */
|
|
137 Time mouse_timestamp;
|
|
138
|
|
139 /* This is the timestamp the last button or key event whether it was
|
|
140 dispatched to emacs or widgets. */
|
|
141 Time global_mouse_timestamp;
|
|
142
|
|
143 /* This is the last known timestamp received from the server. It is
|
|
144 maintained by x_event_to_emacs_event and used to patch bogus
|
|
145 WM_TAKE_FOCUS messages sent by Mwm. */
|
|
146 Time last_server_timestamp;
|
|
147
|
|
148 /* Used by Xlib to preserve information across calls to
|
|
149 XLookupString(), to implement compose processing.
|
|
150
|
|
151 According to The X Window System, p. 467, "The creation of
|
|
152 XComposeStatus structures is implementation dependent;
|
|
153 a portable program must pass NULL for this argument."
|
|
154 But this means that a portable program cannot implement
|
|
155 compose processing! WTF?
|
|
156
|
|
157 So we just set it to all zeros. */
|
|
158
|
|
159 XComposeStatus x_compose_status;
|
|
160
|
|
161 /* stuff for sticky modifiers: */
|
|
162
|
|
163 unsigned int need_to_add_mask, down_mask;
|
|
164 KeyCode last_downkey;
|
|
165 Time release_time;
|
|
166 };
|
|
167
|
|
168 #define DEVICE_X_DATA(d) DEVICE_TYPE_DATA (d, x)
|
|
169
|
|
170 #define FRAME_X_DISPLAY(f) (DEVICE_X_DISPLAY (XDEVICE (f->device)))
|
|
171 #define DEVICE_X_DISPLAY(d) (DEVICE_X_DATA (d)->display)
|
|
172 #define DEVICE_XT_APP_SHELL(d) (DEVICE_X_DATA (d)->Xt_app_shell)
|
|
173 #define DEVICE_X_GC_CACHE(d) (DEVICE_X_DATA (d)->gc_cache)
|
|
174 #define DEVICE_X_GRAY_PIXMAP(d) (DEVICE_X_DATA (d)->gray_pixmap)
|
|
175 #define DEVICE_X_WM_COMMAND_FRAME(d) (DEVICE_X_DATA (d)->WM_COMMAND_frame)
|
|
176 #define DEVICE_X_MOUSE_TIMESTAMP(d) (DEVICE_X_DATA (d)->mouse_timestamp)
|
|
177 #define DEVICE_X_GLOBAL_MOUSE_TIMESTAMP(d) \
|
|
178 (DEVICE_X_DATA (d)->global_mouse_timestamp)
|
|
179 #define DEVICE_X_LAST_SERVER_TIMESTAMP(d) \
|
|
180 (DEVICE_X_DATA (d)->last_server_timestamp)
|
|
181 #define DEVICE_X_X_COMPOSE_STATUS(d) (DEVICE_X_DATA (d)->x_compose_status)
|
|
182
|
|
183 /* allocated in Xatoms_of_xfns in xfns.c */
|
|
184 #define DEVICE_XATOM_WM_PROTOCOLS(d) (DEVICE_X_DATA (d)->Xatom_WM_PROTOCOLS)
|
|
185 #define DEVICE_XATOM_WM_DELETE_WINDOW(d) \
|
|
186 (DEVICE_X_DATA (d)->Xatom_WM_DELETE_WINDOW)
|
|
187 #define DEVICE_XATOM_WM_SAVE_YOURSELF(d) \
|
|
188 (DEVICE_X_DATA (d)->Xatom_WM_SAVE_YOURSELF)
|
|
189 #define DEVICE_XATOM_WM_TAKE_FOCUS(d) (DEVICE_X_DATA (d)->Xatom_WM_TAKE_FOCUS)
|
|
190 #define DEVICE_XATOM_WM_STATE(d) (DEVICE_X_DATA (d)->Xatom_WM_STATE)
|
|
191
|
|
192 /* allocated in Xatoms_of_xselect in xselect.c */
|
|
193 #define DEVICE_XATOM_CLIPBOARD(d) (DEVICE_X_DATA (d)->Xatom_CLIPBOARD)
|
|
194 #define DEVICE_XATOM_TIMESTAMP(d) (DEVICE_X_DATA (d)->Xatom_TIMESTAMP)
|
|
195 #define DEVICE_XATOM_TEXT(d) (DEVICE_X_DATA (d)->Xatom_TEXT)
|
|
196 #define DEVICE_XATOM_DELETE(d) (DEVICE_X_DATA (d)->Xatom_DELETE)
|
|
197 #define DEVICE_XATOM_MULTIPLE(d) (DEVICE_X_DATA (d)->Xatom_MULTIPLE)
|
|
198 #define DEVICE_XATOM_INCR(d) (DEVICE_X_DATA (d)->Xatom_INCR)
|
|
199 #define DEVICE_XATOM_EMACS_TMP(d) (DEVICE_X_DATA (d)->Xatom_EMACS_TMP)
|
|
200 #define DEVICE_XATOM_TARGETS(d) (DEVICE_X_DATA (d)->Xatom_TARGETS)
|
|
201 #define DEVICE_XATOM_NULL(d) (DEVICE_X_DATA (d)->Xatom_NULL)
|
|
202 #define DEVICE_XATOM_ATOM_PAIR(d) (DEVICE_X_DATA (d)->Xatom_ATOM_PAIR)
|
|
203 #define DEVICE_XATOM_COMPOUND_TEXT(d) (DEVICE_X_DATA (d)->Xatom_COMPOUND_TEXT)
|
|
204
|
|
205 /* allocated in Xatoms_of_objects_x in objects-x.c */
|
|
206 #define DEVICE_XATOM_FOUNDRY(d) (DEVICE_X_DATA (d)->Xatom_FOUNDRY)
|
|
207 #define DEVICE_XATOM_FAMILY_NAME(d) (DEVICE_X_DATA (d)->Xatom_FAMILY_NAME)
|
|
208 #define DEVICE_XATOM_WEIGHT_NAME(d) (DEVICE_X_DATA (d)->Xatom_WEIGHT_NAME)
|
|
209 #define DEVICE_XATOM_SLANT(d) (DEVICE_X_DATA (d)->Xatom_SLANT)
|
|
210 #define DEVICE_XATOM_SETWIDTH_NAME(d) (DEVICE_X_DATA (d)->Xatom_SETWIDTH_NAME)
|
|
211 #define DEVICE_XATOM_ADD_STYLE_NAME(d) \
|
|
212 (DEVICE_X_DATA (d)->Xatom_ADD_STYLE_NAME)
|
|
213 #define DEVICE_XATOM_PIXEL_SIZE(d) (DEVICE_X_DATA (d)->Xatom_PIXEL_SIZE)
|
|
214 #define DEVICE_XATOM_POINT_SIZE(d) (DEVICE_X_DATA (d)->Xatom_POINT_SIZE)
|
|
215 #define DEVICE_XATOM_RESOLUTION_X(d) (DEVICE_X_DATA (d)->Xatom_RESOLUTION_X)
|
|
216 #define DEVICE_XATOM_RESOLUTION_Y(d) (DEVICE_X_DATA (d)->Xatom_RESOLUTION_Y)
|
|
217 #define DEVICE_XATOM_SPACING(d) (DEVICE_X_DATA (d)->Xatom_SPACING)
|
|
218 #define DEVICE_XATOM_AVERAGE_WIDTH(d) (DEVICE_X_DATA (d)->Xatom_AVERAGE_WIDTH)
|
|
219 #define DEVICE_XATOM_CHARSET_REGISTRY(d) \
|
|
220 (DEVICE_X_DATA (d)->Xatom_CHARSET_REGISTRY)
|
|
221 #define DEVICE_XATOM_CHARSET_ENCODING(d) \
|
|
222 (DEVICE_X_DATA (d)->Xatom_CHARSET_ENCODING)
|
|
223
|
|
224 /* The maximum number of widgets that can be displayed above the text
|
|
225 area at one time. Currently no more than 3 will ever actually be
|
|
226 displayed (menubar, psheet, debugger panel). */
|
|
227 #define MAX_CONCURRENT_TOP_WIDGETS 8
|
|
228
|
|
229 struct x_frame
|
|
230 {
|
|
231 /* The widget of this frame. This is an EmacsShell or an
|
|
232 ExternalShell. */
|
|
233 Widget widget;
|
|
234
|
|
235 /* The parent of the EmacsFrame, the menubar, and the scrollbars.
|
|
236 This is an EmacsManager. */
|
|
237 Widget container;
|
|
238
|
|
239 /* The widget of the menubar, of whatever widget class it happens to be. */
|
|
240 Widget menubar_widget;
|
|
241
|
|
242 /* The widget of the edit portion of this frame; this is an EmacsFrame,
|
|
243 and the window of this widget is what the redisplay code draws on. */
|
|
244 Widget edit_widget;
|
|
245
|
|
246 /* Lists the widgets above the text area, in the proper order.
|
|
247 Used by the EmacsManager. */
|
|
248 Widget top_widgets[MAX_CONCURRENT_TOP_WIDGETS];
|
|
249 int num_top_widgets;
|
|
250
|
|
251 #ifdef ENERGIZE
|
|
252 /* The Energize property-sheets. The current_ slots are the ones which are
|
|
253 actually on the frame. The desired_ slots are the ones which should
|
|
254 be there. Redisplay synchs these.
|
|
255 */
|
|
256 int *current_psheets;
|
|
257 int *desired_psheets;
|
|
258 int current_psheet_count;
|
|
259 int desired_psheet_count;
|
|
260 Lisp_Object current_psheet_buffer;
|
|
261 Lisp_Object desired_psheet_buffer;
|
16
|
262 #endif /* ENERGIZE */
|
0
|
263
|
|
264 /*************************** Miscellaneous **************************/
|
|
265
|
|
266 /* The icon pixmaps; these are Lisp_Image_Instance objects, or Qnil. */
|
|
267 Lisp_Object icon_pixmap;
|
|
268 Lisp_Object icon_pixmap_mask;
|
|
269
|
|
270 /* We don't provide a mechanism for changing these are they are
|
|
271 initialized so we might as well keep pointers to them and avoid
|
|
272 lots of expensive calls to gc_cache_lookup. */
|
|
273 GC toolbar_top_shadow_gc;
|
|
274 GC toolbar_bottom_shadow_gc;
|
|
275 GC toolbar_blank_background_gc;
|
|
276 GC toolbar_pixmap_background_gc;
|
|
277
|
|
278 /* geometry string that ought to be freed. */
|
|
279 char *geom_free_me_please;
|
|
280
|
16
|
281
|
0
|
282 int old_toolbar_size[4];
|
|
283
|
|
284 /* 1 if the frame is completely visible on the display, 0 otherwise.
|
|
285 if 0 the frame may have been iconified or may be totally
|
|
286 or partially hidden by another X window */
|
16
|
287 unsigned int totally_visible_p :1;
|
0
|
288
|
|
289 /* NB: Both of the following flags are derivable from the 'shell'
|
|
290 field above, but it's easier if we also have them separately here. */
|
|
291
|
|
292 /* Are we a top-level frame? This means that our shell is a
|
|
293 TopLevelShell, and we should do certain things to interact with
|
|
294 the window manager. */
|
16
|
295 unsigned int top_level_frame_p :1;
|
0
|
296
|
|
297 #ifdef EXTERNAL_WIDGET
|
|
298 /* Are we using somebody else's window for our shell window? This
|
|
299 means that our shell is an ExternalShell. If this flag is set, then
|
|
300 `top_level_frame_p' will never be set. */
|
16
|
301 unsigned int external_window_p :1;
|
0
|
302 #endif /* EXTERNAL_WIDGET */
|
|
303 };
|
|
304
|
|
305 #define FRAME_X_DATA(f) FRAME_TYPE_DATA (f, x)
|
|
306
|
|
307 #define FRAME_X_SHELL_WIDGET(f) (FRAME_X_DATA (f)->widget)
|
|
308 #define FRAME_X_CONTAINER_WIDGET(f) (FRAME_X_DATA (f)->container)
|
|
309 #define FRAME_X_MENUBAR_WIDGET(f) (FRAME_X_DATA (f)->menubar_widget)
|
|
310 #define FRAME_X_TEXT_WIDGET(f) (FRAME_X_DATA (f)->edit_widget)
|
|
311 #define FRAME_X_TOP_WIDGETS(f) (FRAME_X_DATA (f)->top_widgets)
|
|
312 #define FRAME_X_NUM_TOP_WIDGETS(f) (FRAME_X_DATA (f)->num_top_widgets)
|
|
313
|
|
314 #define FRAME_X_OLD_TOOLBAR_SIZE(f, pos) \
|
|
315 (FRAME_X_DATA (f)->old_toolbar_size[pos])
|
|
316
|
|
317 #ifdef ENERGIZE
|
|
318 #define FRAME_X_CURRENT_PSHEETS(f) (FRAME_X_DATA (f)->current_psheets)
|
|
319 #define FRAME_X_DESIRED_PSHEETS(f) (FRAME_X_DATA (f)->desired_psheets)
|
|
320 #define FRAME_X_CURRENT_PSHEET_COUNT(f) \
|
|
321 (FRAME_X_DATA (f)->current_psheet_count)
|
|
322 #define FRAME_X_DESIRED_PSHEET_COUNT(f) \
|
|
323 (FRAME_X_DATA (f)->desired_psheet_count)
|
|
324 #define FRAME_X_CURRENT_PSHEET_BUFFER(f) \
|
|
325 (FRAME_X_DATA (f)->current_psheet_buffer)
|
|
326 #define FRAME_X_DESIRED_PSHEET_BUFFER(f) \
|
|
327 (FRAME_X_DATA (f)->desired_psheet_buffer)
|
|
328 #endif
|
|
329
|
|
330 #define FRAME_X_ICON_PIXMAP(f) (FRAME_X_DATA (f)->icon_pixmap)
|
|
331 #define FRAME_X_ICON_PIXMAP_MASK(f) (FRAME_X_DATA (f)->icon_pixmap_mask)
|
|
332
|
|
333 #define FRAME_X_TOOLBAR_TOP_SHADOW_GC(f) \
|
|
334 (FRAME_X_DATA (f)->toolbar_top_shadow_gc)
|
|
335 #define FRAME_X_TOOLBAR_BOTTOM_SHADOW_GC(f) \
|
|
336 (FRAME_X_DATA (f)->toolbar_bottom_shadow_gc)
|
|
337 #define FRAME_X_TOOLBAR_BLANK_BACKGROUND_GC(f) \
|
|
338 (FRAME_X_DATA (f)->toolbar_blank_background_gc)
|
|
339 #define FRAME_X_TOOLBAR_PIXMAP_BACKGROUND_GC(f) \
|
|
340 (FRAME_X_DATA (f)->toolbar_pixmap_background_gc)
|
|
341
|
|
342 #define FRAME_X_GEOM_FREE_ME_PLEASE(f) (FRAME_X_DATA (f)->geom_free_me_please)
|
|
343
|
|
344 #define FRAME_X_TOTALLY_VISIBLE_P(f) (FRAME_X_DATA (f)->totally_visible_p)
|
|
345 #define FRAME_X_TOP_LEVEL_FRAME_P(f) (FRAME_X_DATA (f)->top_level_frame_p)
|
|
346
|
|
347 #ifdef EXTERNAL_WIDGET
|
|
348 #define FRAME_X_EXTERNAL_WINDOW_P(f) (FRAME_X_DATA (f)->external_window_p)
|
|
349 #endif
|
|
350
|
|
351 /* This needs to go in an include file that's included by inline.c
|
|
352 in order for the error-checking functions to get defined. */
|
|
353 #ifdef EPOCH
|
|
354 DECLARE_LRECORD (x_resource, struct Lisp_X_Resource);
|
|
355 #endif
|
|
356
|
|
357 /* Variables associated with the X display frame this emacs is using. */
|
|
358 extern XtAppContext Xt_app_con;
|
|
359
|
|
360 extern Lisp_Object Vx_gc_pointer_shape;
|
|
361 extern Lisp_Object Vx_scrollbar_pointer_shape;
|
|
362 extern Lisp_Object Qx_error;
|
|
363
|
|
364 extern struct console_type *x_console_type;
|
|
365 extern Lisp_Object Vdefault_x_device;
|
|
366
|
|
367 /* Number of pixels below each line. */
|
|
368 extern int x_interline_space;
|
|
369
|
|
370 extern int x_selection_timeout;
|
|
371
|
|
372 struct frame *x_any_window_to_frame (struct device *d, Window);
|
|
373 struct frame *x_any_widget_or_parent_to_frame (struct device *d,
|
|
374 Widget widget);
|
|
375 struct frame *decode_x_frame (Lisp_Object);
|
|
376 Display *get_x_display (Lisp_Object);
|
|
377 struct frame *x_window_to_frame (struct device *d, Window);
|
|
378 struct device *get_device_from_display (Display *dpy);
|
|
379 struct device *decode_x_device (Lisp_Object);
|
|
380
|
|
381 void x_handle_selection_notify (XSelectionEvent *event);
|
|
382 void x_handle_selection_request (XSelectionRequestEvent *event);
|
|
383 void x_handle_selection_clear (XSelectionClearEvent *event);
|
|
384 void x_handle_property_notify (XPropertyEvent *event);
|
|
385
|
|
386 void Xatoms_of_xselect (struct device *d);
|
|
387 void Xatoms_of_objects_x (struct device *d);
|
|
388
|
|
389 void x_wm_set_shell_iconic_p (Widget shell, int iconic_p);
|
|
390 void x_wm_set_cell_size (Widget wmshell, int cw, int ch);
|
|
391 void x_wm_set_variable_size (Widget wmshell, int width, int height);
|
|
392
|
|
393 CONST char *x_event_name (int event_type);
|
|
394 int x_error_handler (Display *disp, XErrorEvent *event);
|
|
395 void expect_x_error (Display *dpy);
|
|
396 int x_error_occurred_p (Display *dpy);
|
|
397 int signal_if_x_error (Display *dpy, int resumable_p);
|
|
398 int x_IO_error_handler (Display *disp);
|
|
399
|
|
400 void x_redraw_exposed_area (struct frame *f, int x, int y,
|
|
401 int width, int height);
|
|
402 struct Lisp_Image_Instance;
|
|
403 void x_output_string (struct window *w, struct display_line *dl,
|
|
404 emchar_dynarr *buf, int xpos, int xoffset,
|
|
405 int start_pixpos, int width, face_index findex,
|
|
406 int cursor, int cursor_start, int cursor_width,
|
|
407 int cursor_height);
|
|
408 void x_output_x_pixmap (struct frame *f, struct Lisp_Image_Instance *p,
|
|
409 int x, int y, int clip_x, int clip_y,
|
|
410 int clip_width, int clip_height, int width,
|
|
411 int height, int pixmap_offset,
|
|
412 unsigned long fg, unsigned long bg,
|
|
413 GC override_gc);
|
|
414 void x_output_shadows (struct frame *f, int x, int y, int width,
|
|
415 int height, GC top_shadow_gc,
|
|
416 GC bottom_shadow_gc, GC background_gc,
|
|
417 int shadow_thickness);
|
|
418 void x_generate_shadow_pixels (struct frame *f,
|
|
419 unsigned long *top_shadow,
|
|
420 unsigned long *bottom_shadow,
|
|
421 unsigned long background,
|
|
422 unsigned long core_background);
|
|
423
|
|
424 int x_initialize_frame_menubar (struct frame *f);
|
|
425 void x_init_modifier_mapping (struct device *d);
|
|
426
|
|
427 #define X_ERROR_OCCURRED(dpy, body) \
|
|
428 (expect_x_error ((dpy)), (body), x_error_occurred_p (dpy))
|
|
429
|
|
430 #define HANDLING_X_ERROR(dpy, body) \
|
|
431 ( expect_x_error ((dpy)), (body), signal_if_x_error ((dpy), 0))
|
|
432
|
|
433 Lisp_Object x_atom_to_symbol (struct device *d, Atom atom);
|
|
434 Atom symbol_to_x_atom (struct device *d, Lisp_Object sym,
|
|
435 int only_if_exists);
|
|
436
|
|
437 #ifdef EPOCH
|
|
438 extern Lisp_Object Qx_property_change, Qx_client_message, Qx_map, Qx_unmap;
|
|
439 extern Lisp_Object Vepoch_event, Vepoch_event_handler;
|
|
440 #endif
|
|
441
|
|
442 extern int in_resource_setting;
|
|
443 extern int in_specifier_change_function;
|
|
444
|
|
445 extern Lisp_Object Vx_initial_argv_list; /* #### ugh! */
|
|
446
|
|
447 #endif /* HAVE_X_WINDOWS */
|
|
448 #endif /* _XEMACS_DEVICE_X_H_ */
|