Mercurial > hg > xemacs-beta
annotate src/console-x-impl.h @ 5237:6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
FRAME_X_FTDRAW.
(struct x_device): Add XftDraw field.
(struct x_frame): Remove XftDraw field.
Move XftDraw from frame to device for improved caching.
* device-x.c (x_delete_device): Free XftDraw here.
* frame-x.c (x_delete_frame): Remove freeing of XftDraw.
* redisplay-xlike-inc.c (XLIKE_output_string): Use
DEVICE_X_XFTDRAW instead of FRAME_X_XFTDRAW when lazily creating
XftDraw structure.
author | Jeff Sparkes <jsparkes@gmail.com> |
---|---|
date | Wed, 23 Jun 2010 08:04:18 -0400 |
parents | 97eb4942aec8 |
children | f19e6bc25969 |
rev | line source |
---|---|
872 | 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. | |
1346 | 4 Copyright (C) 1996, 2002, 2003 Ben Wing. |
5080
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
5 Copyright (C) 2010 Didier Verna |
872 | 6 |
7 This file is part of XEmacs. | |
8 | |
9 XEmacs is free software; you can redistribute it and/or modify it | |
10 under the terms of the GNU General Public License as published by the | |
11 Free Software Foundation; either version 2, or (at your option) any | |
12 later version. | |
13 | |
14 XEmacs is distributed in the hope that it will be useful, but WITHOUT | |
15 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
16 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License | |
17 for more details. | |
18 | |
19 You should have received a copy of the GNU General Public License | |
20 along with XEmacs; see the file COPYING. If not, write to | |
21 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |
22 Boston, MA 02111-1307, USA. */ | |
23 | |
24 /* Synched up with: Not in FSF. */ | |
25 | |
26 | |
27 /* Authorship: | |
28 | |
29 Ultimately based on FSF, then later on JWZ work for Lemacs. | |
30 Rewritten over time by Ben Wing and Chuck Thompson (original | |
31 multi-device work by Chuck Thompson). | |
32 */ | |
33 | |
34 #ifndef INCLUDED_console_x_impl_h_ | |
35 #define INCLUDED_console_x_impl_h_ | |
36 | |
37 #ifdef HAVE_X_WINDOWS | |
38 | |
39 #include "console-impl.h" | |
40 #include "console-x.h" | |
41 | |
42 DECLARE_CONSOLE_TYPE (x); | |
43 | |
3381 | 44 extern int wedge_metacity; |
45 | |
872 | 46 struct x_device |
47 { | |
3092 | 48 #ifdef NEW_GC |
5127
a9c41067dd88
more cleanups, terminology clarification, lots of doc work
Ben Wing <ben@xemacs.org>
parents:
5125
diff
changeset
|
49 NORMAL_LISP_OBJECT_HEADER header; |
3092 | 50 #endif /* NEW_GC */ |
872 | 51 /* The X connection of this device. */ |
52 Display *display; | |
53 | |
54 /* Set by x_IO_error_handler(). */ | |
55 int being_deleted; | |
56 | |
57 /* Xt application info. */ | |
58 Widget Xt_app_shell; | |
59 | |
60 /* Cache of GC's for frames on this device. */ | |
61 struct gc_cache *gc_cache; | |
62 | |
63 /* Selected visual, depth and colormap for this device */ | |
64 Visual *visual; | |
65 int depth; | |
66 Colormap device_cmap; | |
67 | |
68 /* Used by x_bevel_modeline in redisplay-x.c */ | |
69 Pixmap gray_pixmap; | |
70 | |
5237
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
71 #ifdef HAVE_XFT |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
72 /* The Xft Drawable wrapper for this device. */ |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
73 /* This is persistent to take advantage of the ability of Xft's glyph |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
74 cache in the server, and avoid rendering the font again and again... |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
75 |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
76 This is created the first time through redisplay, and destroyed when our |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
77 connection to the X display is destroyed. */ |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
78 XftDraw *xftDraw; |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
79 #endif |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
80 |
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
81 |
872 | 82 /* Atoms associated with this device. */ |
83 /* allocated in Xatoms_of_device_x */ | |
84 Atom Xatom_WM_PROTOCOLS; | |
85 Atom Xatom_WM_DELETE_WINDOW; | |
86 Atom Xatom_WM_SAVE_YOURSELF; | |
87 Atom Xatom_WM_TAKE_FOCUS; | |
88 Atom Xatom_WM_STATE; | |
89 | |
90 /* allocated in Xatoms_of_select_x */ | |
91 Atom Xatom_CLIPBOARD; | |
92 Atom Xatom_TIMESTAMP; | |
93 Atom Xatom_TEXT; | |
94 Atom Xatom_DELETE; | |
95 Atom Xatom_MULTIPLE; | |
96 Atom Xatom_INCR; | |
97 Atom Xatom_EMACS_TMP; | |
98 Atom Xatom_TARGETS; | |
99 Atom Xatom_NULL; | |
100 Atom Xatom_ATOM_PAIR; | |
101 Atom Xatom_COMPOUND_TEXT; | |
102 | |
5176
8b2f75cecb89
rename objects* (.c, .h and .el files) to fontcolor*
Ben Wing <ben@xemacs.org>
parents:
4916
diff
changeset
|
103 /* allocated in Xatoms_of_fontcolor_x */ |
872 | 104 Atom Xatom_FOUNDRY; |
105 Atom Xatom_FAMILY_NAME; | |
106 Atom Xatom_WEIGHT_NAME; | |
107 Atom Xatom_SLANT; | |
108 Atom Xatom_SETWIDTH_NAME; | |
109 Atom Xatom_ADD_STYLE_NAME; | |
110 Atom Xatom_PIXEL_SIZE; | |
111 Atom Xatom_POINT_SIZE; | |
112 Atom Xatom_RESOLUTION_X; | |
113 Atom Xatom_RESOLUTION_Y; | |
114 Atom Xatom_SPACING; | |
115 Atom Xatom_AVERAGE_WIDTH; | |
116 Atom Xatom_CHARSET_REGISTRY; | |
117 Atom Xatom_CHARSET_ENCODING; | |
118 | |
119 /* The following items are all used exclusively in event-Xt.c. */ | |
120 int MetaMask, HyperMask, SuperMask, AltMask, ModeMask; | |
121 KeySym lock_interpretation; | |
122 | |
123 XModifierKeymap *x_modifier_keymap; | |
124 | |
125 KeySym *x_keysym_map; | |
126 int x_keysym_map_min_code; | |
127 int x_keysym_map_max_code; | |
128 int x_keysym_map_keysyms_per_code; | |
129 Lisp_Object x_keysym_map_hash_table; | |
130 | |
131 /* frame that holds the WM_COMMAND property; there should be exactly | |
132 one of these per device. */ | |
133 Lisp_Object WM_COMMAND_frame; | |
134 | |
135 /* #### It's not clear that there is much distinction anymore | |
136 between mouse_timestamp and global_mouse_timestamp, now that | |
137 Emacs doesn't see most (all?) events not destined for it. */ | |
138 | |
139 /* The timestamp of the last button or key event used by emacs itself. | |
140 This is used for asserting selections and input focus. */ | |
141 Time mouse_timestamp; | |
142 | |
143 /* This is the timestamp the last button or key event whether it was | |
144 dispatched to emacs or widgets. */ | |
145 Time global_mouse_timestamp; | |
146 | |
147 /* This is the last known timestamp received from the server. It is | |
148 maintained by x_event_to_emacs_event and used to patch bogus | |
149 WM_TAKE_FOCUS messages sent by Mwm. */ | |
150 Time last_server_timestamp; | |
151 | |
152 /* Used by Xlib to preserve information across calls to | |
153 XLookupString(), to implement compose processing. | |
154 | |
155 According to The X Window System, p. 467, "The creation of | |
156 XComposeStatus structures is implementation dependent; | |
157 a portable program must pass NULL for this argument." | |
158 But this means that a portable program cannot implement | |
159 compose processing! WTF? | |
160 | |
161 So we just set it to all zeros. */ | |
162 | |
163 /* No X Server ever used this, AFAIK -- mrb */ | |
164 /* XComposeStatus x_compose_status; */ | |
165 | |
166 #ifdef HAVE_XIM | |
167 XIM xim; | |
168 XIMStyles *xim_styles; | |
169 #endif /* HAVE_XIM */ | |
170 | |
171 /* stuff for sticky modifiers: */ | |
172 | |
173 unsigned int need_to_add_mask, down_mask; | |
174 KeyCode last_downkey; | |
175 Time release_time; | |
176 Time modifier_release_time; | |
177 }; | |
178 | |
3092 | 179 #ifdef NEW_GC |
180 typedef struct x_device Lisp_X_Device; | |
181 | |
5118
e0db3c197671
merge up to latest default branch, doesn't compile yet
Ben Wing <ben@xemacs.org>
parents:
4584
diff
changeset
|
182 DECLARE_LISP_OBJECT (x_device, Lisp_X_Device); |
3092 | 183 |
184 #define XX_DEVICE(x) \ | |
185 XRECORD (x, x_device, Lisp_X_Device) | |
186 #define wrap_x_device(p) wrap_record (p, x_device) | |
187 #define X_DEVICE_P(x) RECORDP (x, x_device) | |
188 #endif /* NEW_GC */ | |
189 | |
872 | 190 #define DEVICE_X_DATA(d) DEVICE_TYPE_DATA (d, x) |
191 | |
192 #define FRAME_X_DISPLAY(f) (DEVICE_X_DISPLAY (XDEVICE (f->device))) | |
193 #define DEVICE_X_DISPLAY(d) (DEVICE_X_DATA (d)->display) | |
194 #define DEVICE_X_BEING_DELETED(d) (DEVICE_X_DATA (d)->being_deleted) | |
195 #define DEVICE_X_VISUAL(d) (DEVICE_X_DATA (d)->visual) | |
196 #define DEVICE_X_DEPTH(d) (DEVICE_X_DATA (d)->depth) | |
197 #define DEVICE_X_COLORMAP(d) (DEVICE_X_DATA (d)->device_cmap) | |
198 #define DEVICE_XT_APP_SHELL(d) (DEVICE_X_DATA (d)->Xt_app_shell) | |
199 #define DEVICE_X_GC_CACHE(d) (DEVICE_X_DATA (d)->gc_cache) | |
200 #define DEVICE_X_GRAY_PIXMAP(d) (DEVICE_X_DATA (d)->gray_pixmap) | |
5237
6466bc9ebf15
* console-x-impl.h (DEVICE_X_XFTDRAW): Define, instead of
Jeff Sparkes <jsparkes@gmail.com>
parents:
5178
diff
changeset
|
201 #define DEVICE_X_XFTDRAW(d) (DEVICE_X_DATA (d)->xftDraw) |
872 | 202 #define DEVICE_X_WM_COMMAND_FRAME(d) (DEVICE_X_DATA (d)->WM_COMMAND_frame) |
203 #define DEVICE_X_MOUSE_TIMESTAMP(d) (DEVICE_X_DATA (d)->mouse_timestamp) | |
204 #define DEVICE_X_GLOBAL_MOUSE_TIMESTAMP(d) (DEVICE_X_DATA (d)->global_mouse_timestamp) | |
205 #define DEVICE_X_LAST_SERVER_TIMESTAMP(d) (DEVICE_X_DATA (d)->last_server_timestamp) | |
206 #define DEVICE_X_KEYSYM_MAP_HASH_TABLE(d) (DEVICE_X_DATA (d)->x_keysym_map_hash_table) | |
207 /* #define DEVICE_X_X_COMPOSE_STATUS(d) (DEVICE_X_DATA (d)->x_compose_status) */ | |
208 #ifdef HAVE_XIM | |
209 #define DEVICE_X_XIM(d) (DEVICE_X_DATA (d)->xim) | |
210 #define DEVICE_X_XIM_STYLES(d) (DEVICE_X_DATA (d)->xim_styles) | |
211 #define DEVICE_X_FONTSET(d) (DEVICE_X_DATA (d)->fontset) | |
212 #endif /* HAVE_XIM */ | |
213 | |
214 /* allocated in Xatoms_of_device_x */ | |
215 #define DEVICE_XATOM_WM_PROTOCOLS(d) (DEVICE_X_DATA (d)->Xatom_WM_PROTOCOLS) | |
216 #define DEVICE_XATOM_WM_DELETE_WINDOW(d) (DEVICE_X_DATA (d)->Xatom_WM_DELETE_WINDOW) | |
217 #define DEVICE_XATOM_WM_SAVE_YOURSELF(d) (DEVICE_X_DATA (d)->Xatom_WM_SAVE_YOURSELF) | |
218 #define DEVICE_XATOM_WM_TAKE_FOCUS(d) (DEVICE_X_DATA (d)->Xatom_WM_TAKE_FOCUS) | |
219 #define DEVICE_XATOM_WM_STATE(d) (DEVICE_X_DATA (d)->Xatom_WM_STATE) | |
220 | |
221 /* allocated in Xatoms_of_select_x */ | |
222 #define DEVICE_XATOM_CLIPBOARD(d) (DEVICE_X_DATA (d)->Xatom_CLIPBOARD) | |
223 #define DEVICE_XATOM_TIMESTAMP(d) (DEVICE_X_DATA (d)->Xatom_TIMESTAMP) | |
224 #define DEVICE_XATOM_TEXT(d) (DEVICE_X_DATA (d)->Xatom_TEXT) | |
225 #define DEVICE_XATOM_DELETE(d) (DEVICE_X_DATA (d)->Xatom_DELETE) | |
226 #define DEVICE_XATOM_MULTIPLE(d) (DEVICE_X_DATA (d)->Xatom_MULTIPLE) | |
227 #define DEVICE_XATOM_INCR(d) (DEVICE_X_DATA (d)->Xatom_INCR) | |
228 #define DEVICE_XATOM_EMACS_TMP(d) (DEVICE_X_DATA (d)->Xatom_EMACS_TMP) | |
229 #define DEVICE_XATOM_TARGETS(d) (DEVICE_X_DATA (d)->Xatom_TARGETS) | |
230 #define DEVICE_XATOM_NULL(d) (DEVICE_X_DATA (d)->Xatom_NULL) | |
231 #define DEVICE_XATOM_ATOM_PAIR(d) (DEVICE_X_DATA (d)->Xatom_ATOM_PAIR) | |
232 #define DEVICE_XATOM_COMPOUND_TEXT(d) (DEVICE_X_DATA (d)->Xatom_COMPOUND_TEXT) | |
233 | |
5176
8b2f75cecb89
rename objects* (.c, .h and .el files) to fontcolor*
Ben Wing <ben@xemacs.org>
parents:
4916
diff
changeset
|
234 /* allocated in Xatoms_of_fontcolor_x */ |
872 | 235 #define DEVICE_XATOM_FOUNDRY(d) (DEVICE_X_DATA (d)->Xatom_FOUNDRY) |
236 #define DEVICE_XATOM_FAMILY_NAME(d) (DEVICE_X_DATA (d)->Xatom_FAMILY_NAME) | |
237 #define DEVICE_XATOM_WEIGHT_NAME(d) (DEVICE_X_DATA (d)->Xatom_WEIGHT_NAME) | |
238 #define DEVICE_XATOM_SLANT(d) (DEVICE_X_DATA (d)->Xatom_SLANT) | |
239 #define DEVICE_XATOM_SETWIDTH_NAME(d) (DEVICE_X_DATA (d)->Xatom_SETWIDTH_NAME) | |
240 #define DEVICE_XATOM_ADD_STYLE_NAME(d) (DEVICE_X_DATA (d)->Xatom_ADD_STYLE_NAME) | |
241 #define DEVICE_XATOM_PIXEL_SIZE(d) (DEVICE_X_DATA (d)->Xatom_PIXEL_SIZE) | |
242 #define DEVICE_XATOM_POINT_SIZE(d) (DEVICE_X_DATA (d)->Xatom_POINT_SIZE) | |
243 #define DEVICE_XATOM_RESOLUTION_X(d) (DEVICE_X_DATA (d)->Xatom_RESOLUTION_X) | |
244 #define DEVICE_XATOM_RESOLUTION_Y(d) (DEVICE_X_DATA (d)->Xatom_RESOLUTION_Y) | |
245 #define DEVICE_XATOM_SPACING(d) (DEVICE_X_DATA (d)->Xatom_SPACING) | |
246 #define DEVICE_XATOM_AVERAGE_WIDTH(d) (DEVICE_X_DATA (d)->Xatom_AVERAGE_WIDTH) | |
247 #define DEVICE_XATOM_CHARSET_REGISTRY(d) (DEVICE_X_DATA (d)->Xatom_CHARSET_REGISTRY) | |
248 #define DEVICE_XATOM_CHARSET_ENCODING(d) (DEVICE_X_DATA (d)->Xatom_CHARSET_ENCODING) | |
249 | |
250 /* The maximum number of widgets that can be displayed above the text | |
251 area at one time. Currently no more than 3 will ever actually be | |
3381 | 252 displayed (menubar, psheet, debugger panel). |
253 #### Are "psheet" and "debugger panel" relevant any more? */ | |
872 | 254 #define MAX_CONCURRENT_TOP_WIDGETS 8 |
255 | |
256 struct x_frame | |
257 { | |
3092 | 258 #ifdef NEW_GC |
5127
a9c41067dd88
more cleanups, terminology clarification, lots of doc work
Ben Wing <ben@xemacs.org>
parents:
5125
diff
changeset
|
259 NORMAL_LISP_OBJECT_HEADER header; |
3092 | 260 #endif /* NEW_GC */ |
261 | |
3381 | 262 /* The widget of this frame. |
263 This is an EmacsShell or an ExternalShell. | |
264 It negotiates with the window manager or containing app on behalf of | |
265 the container widget. Should be (but isn't) invisible to Emacs. */ | |
872 | 266 Widget widget; |
267 | |
268 /* The parent of the EmacsFrame, the menubar, and the scrollbars. | |
3381 | 269 This is an EmacsManager. |
270 It is responsible for managing the geometry of the frame. This is what | |
271 Emacs mostly talks to. Anything that affects its geometry will be | |
272 reflected in the Shell widget, and thus cause WM interaction. */ | |
872 | 273 Widget container; |
274 | |
275 /* The widget of the menubar, of whatever widget class it happens to be. */ | |
276 Widget menubar_widget; | |
277 | |
278 /* The widget of the edit portion of this frame; this is an EmacsFrame, | |
279 and the window of this widget is what the redisplay code draws on. */ | |
280 Widget edit_widget; | |
5080
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
281 /* Position of the edit widget above, for absolute background placement. */ |
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
282 int x, y; |
872 | 283 |
284 /* Lists the widgets above the text area, in the proper order. | |
285 Used by the EmacsManager. */ | |
286 Widget top_widgets[MAX_CONCURRENT_TOP_WIDGETS]; | |
287 int num_top_widgets; | |
288 | |
1346 | 289 /* lwlib ID of the tree of widgets corresponding to this popup. We pass |
290 this to lw_map_widget_values() to retrieve all of our Lispy call-data | |
291 and accel values that need to be GCPRO'd, and store them in the | |
292 following list. (We used to call lw_map_widget_values() during GC | |
293 mark, but that isn't compatible with KKCC.) */ | |
294 LWLIB_ID menubar_id; | |
295 | |
296 /* For the frame popup data, this is the last buffer for which the | |
297 menubar was displayed. If the buffer has changed, we may have to | |
298 update things. */ | |
299 Lisp_Object last_menubar_buffer; | |
300 | |
301 /* This flag tells us if the menubar contents are up-to-date with respect | |
302 to the current menubar structure. If we want to actually pull down a | |
303 menu and this is false, then we need to update things. */ | |
2367 | 304 Boolbyte menubar_contents_up_to_date; |
872 | 305 |
306 /* The icon pixmaps; these are Lisp_Image_Instance objects, or Qnil. */ | |
307 Lisp_Object icon_pixmap; | |
308 Lisp_Object icon_pixmap_mask; | |
309 | |
310 #ifdef HAVE_TOOLBARS | |
311 int old_toolbar_size[4]; | |
312 | |
313 /* We don't provide a mechanism for changing these after they are | |
314 initialized so we might as well keep pointers to them and avoid | |
315 lots of expensive calls to gc_cache_lookup. */ | |
316 GC toolbar_top_shadow_gc; | |
317 GC toolbar_bottom_shadow_gc; | |
318 GC toolbar_blank_background_gc; | |
319 GC toolbar_pixmap_background_gc; | |
320 #endif /* HAVE_TOOLBARS */ | |
321 | |
322 /* geometry string that ought to be freed. */ | |
2367 | 323 Ascbyte *geom_free_me_please; |
872 | 324 |
325 #ifdef HAVE_XIM | |
326 XPoint xic_spot; /* Spot Location cache */ | |
327 #ifdef XIM_XLIB | |
328 XIC xic; | |
329 /* Could get these at any time by asking xic, but... */ | |
330 XIMStyle xic_style; /* XIM Style cache */ | |
331 #endif /* XIM_XLIB */ | |
332 #endif /* HAVE_XIM */ | |
333 | |
334 /* 1 if the frame is completely visible on the display, 0 otherwise. | |
335 if 0 the frame may have been iconified or may be totally | |
336 or partially hidden by another X window */ | |
337 unsigned int totally_visible_p :1; | |
338 | |
4584
56e67d42eb04
Clarify comment in struct x_frame.
Stephen J. Turnbull <stephen@xemacs.org>
parents:
3381
diff
changeset
|
339 /* NB: Both of the following flags are derivable from the 'widget' |
872 | 340 field above, but it's easier if we also have them separately here. */ |
341 | |
342 /* Are we a top-level frame? This means that our shell is a | |
343 TopLevelShell, and we should do certain things to interact with | |
344 the window manager. */ | |
345 unsigned int top_level_frame_p :1; | |
346 | |
347 #ifdef EXTERNAL_WIDGET | |
348 /* Are we using somebody else's window for our shell window? This | |
349 means that our shell is an ExternalShell. If this flag is set, then | |
350 `top_level_frame_p' will never be set. */ | |
351 unsigned int external_window_p :1; | |
352 #endif /* EXTERNAL_WIDGET */ | |
353 }; | |
354 | |
3092 | 355 #ifdef NEW_GC |
356 typedef struct x_frame Lisp_X_Frame; | |
357 | |
5118
e0db3c197671
merge up to latest default branch, doesn't compile yet
Ben Wing <ben@xemacs.org>
parents:
4584
diff
changeset
|
358 DECLARE_LISP_OBJECT (x_frame, Lisp_X_Frame); |
3092 | 359 |
360 #define XX_FRAME(x) \ | |
361 XRECORD (x, x_frame, Lisp_X_Frame) | |
362 #define wrap_x_frame(p) wrap_record (p, x_frame) | |
363 #define X_FRAME_P(x) RECORDP (x, x_frame) | |
364 #endif /* NEW_GC */ | |
872 | 365 #define FRAME_X_DATA(f) FRAME_TYPE_DATA (f, x) |
366 | |
5080
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
367 #define FRAME_X_X(f) (FRAME_X_DATA (f)->x) |
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
368 #define FRAME_X_Y(f) (FRAME_X_DATA (f)->y) |
872 | 369 #define FRAME_X_SHELL_WIDGET(f) (FRAME_X_DATA (f)->widget) |
370 #define FRAME_X_CONTAINER_WIDGET(f) (FRAME_X_DATA (f)->container) | |
371 #define FRAME_X_MENUBAR_WIDGET(f) (FRAME_X_DATA (f)->menubar_widget) | |
372 #define FRAME_X_TEXT_WIDGET(f) (FRAME_X_DATA (f)->edit_widget) | |
373 #define FRAME_X_TOP_WIDGETS(f) (FRAME_X_DATA (f)->top_widgets) | |
374 #define FRAME_X_NUM_TOP_WIDGETS(f) (FRAME_X_DATA (f)->num_top_widgets) | |
375 | |
1346 | 376 #define FRAME_X_MENUBAR_ID(f) (FRAME_X_DATA (f)->menubar_id) |
377 #define FRAME_X_LAST_MENUBAR_BUFFER(f) (FRAME_X_DATA (f)->last_menubar_buffer) | |
378 #define FRAME_X_MENUBAR_CONTENTS_UP_TO_DATE(f) \ | |
379 (FRAME_X_DATA (f)->menubar_contents_up_to_date) | |
380 | |
872 | 381 #define FRAME_X_ICON_PIXMAP(f) (FRAME_X_DATA (f)->icon_pixmap) |
382 #define FRAME_X_ICON_PIXMAP_MASK(f) (FRAME_X_DATA (f)->icon_pixmap_mask) | |
383 | |
384 #ifdef HAVE_TOOLBARS | |
385 #define FRAME_X_OLD_TOOLBAR_SIZE(f, pos) (FRAME_X_DATA (f)->old_toolbar_size[pos]) | |
386 | |
387 #define FRAME_X_TOOLBAR_TOP_SHADOW_GC(f) (FRAME_X_DATA (f)->toolbar_top_shadow_gc) | |
388 #define FRAME_X_TOOLBAR_BOTTOM_SHADOW_GC(f) (FRAME_X_DATA (f)->toolbar_bottom_shadow_gc) | |
389 #define FRAME_X_TOOLBAR_BLANK_BACKGROUND_GC(f) (FRAME_X_DATA (f)->toolbar_blank_background_gc) | |
390 #define FRAME_X_TOOLBAR_PIXMAP_BACKGROUND_GC(f) (FRAME_X_DATA (f)->toolbar_pixmap_background_gc) | |
391 #endif /* HAVE_TOOLBARS */ | |
392 | |
393 #define FRAME_X_GEOM_FREE_ME_PLEASE(f) (FRAME_X_DATA (f)->geom_free_me_please) | |
394 | |
395 #define FRAME_X_TOTALLY_VISIBLE_P(f) (FRAME_X_DATA (f)->totally_visible_p) | |
396 #define FRAME_X_TOP_LEVEL_FRAME_P(f) (FRAME_X_DATA (f)->top_level_frame_p) | |
397 | |
398 #ifdef EXTERNAL_WIDGET | |
399 #define FRAME_X_EXTERNAL_WINDOW_P(f) (FRAME_X_DATA (f)->external_window_p) | |
400 #endif | |
401 | |
402 #ifdef HAVE_XIM | |
403 #define FRAME_X_XIC_SPOT(f) (FRAME_X_DATA (f)->xic_spot) | |
404 #ifdef XIM_XLIB | |
405 #define FRAME_X_XIC(f) (FRAME_X_DATA (f)->xic) | |
406 #define FRAME_X_XIC_STYLE(f) (FRAME_X_DATA (f)->xic_style) | |
407 #endif /* XIM_XLIB */ | |
408 #endif /* HAVE_XIM */ | |
409 | |
410 extern struct console_type *x_console_type; | |
411 | |
5080
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
412 void x_get_frame_text_position (struct frame *); |
5502045ec510
The background-placement face property.
Didier Verna <didier@lrde.epita.fr>
parents:
4916
diff
changeset
|
413 |
872 | 414 #endif /* HAVE_X_WINDOWS */ |
415 | |
416 #endif /* INCLUDED_console_x_impl_h_ */ |