39 |
#define BLACK_PIX_DEFAULT(f) RGB_TO_ULONG(0,0,0) |
#define BLACK_PIX_DEFAULT(f) RGB_TO_ULONG(0,0,0) |
40 |
#define WHITE_PIX_DEFAULT(f) RGB_TO_ULONG(255,255,255) |
#define WHITE_PIX_DEFAULT(f) RGB_TO_ULONG(255,255,255) |
41 |
|
|
42 |
#define FONT_WIDTH(f) ((f)->max_bounds.width) |
#define FONT_WIDTH(f) ((f)->max_bounds.width) |
43 |
#define FONT_HEIGHT(f) ((f)->ascent + (f)->descent) |
#define FONT_HEIGHT(f) ((f)->ascent + (f)->descent) |
44 |
#define FONT_BASE(f) ((f)->ascent) |
#define FONT_BASE(f) ((f)->ascent) |
45 |
#define FONT_DESCENT(f) ((f)->descent) |
#define FONT_DESCENT(f) ((f)->descent) |
46 |
|
|
82 |
/* Whether the screen supports color */ |
/* Whether the screen supports color */ |
83 |
int color_p; |
int color_p; |
84 |
|
|
|
#if 0 |
|
|
/* Number of bits per pixel on this screen. */ |
|
|
int n_cbits; |
|
|
#endif |
|
|
|
|
85 |
/* Dimensions of this screen. */ |
/* Dimensions of this screen. */ |
86 |
int height, width; |
int height, width; |
|
#if 0 |
|
|
int height_in,width_in; |
|
|
#endif |
|
87 |
|
|
88 |
/* Mask of things that cause the mouse to be grabbed. */ |
/* Mask of things that cause the mouse to be grabbed. */ |
89 |
int grabbed; |
int grabbed; |
103 |
/* Resource data base */ |
/* Resource data base */ |
104 |
XrmDatabase xrdb; |
XrmDatabase xrdb; |
105 |
|
|
|
#if 0 |
|
|
/* color palette information. */ |
|
|
int has_palette; |
|
|
struct w32_palette_entry * color_list; |
|
|
unsigned num_colors; |
|
|
HPALETTE palette; |
|
|
|
|
|
/* deferred action flags checked when starting frame update. */ |
|
|
int regen_palette; |
|
|
|
|
|
/* Keystroke that has been faked by Emacs and will be ignored when |
|
|
received; value is reset after key is received. */ |
|
|
int faked_key; |
|
|
|
|
|
#endif |
|
|
|
|
106 |
/* A table of all the fonts we have already loaded. */ |
/* A table of all the fonts we have already loaded. */ |
107 |
struct font_info *font_table; |
struct font_info *font_table; |
108 |
|
|
109 |
/* The current capacity of font_table. */ |
/* The current capacity of font_table. */ |
110 |
int font_table_size; |
int font_table_size; |
111 |
|
|
|
/* The number of fonts actually stored in the font table. |
|
|
font_table[n] is used and valid iff 0 <= n < n_fonts. 0 <= |
|
|
n_fonts <= font_table_size. and font_table[i].name != 0. */ |
|
|
int n_fonts; |
|
|
|
|
112 |
/* Minimum width over all characters in all fonts in font_table. */ |
/* Minimum width over all characters in all fonts in font_table. */ |
113 |
int smallest_char_width; |
int smallest_char_width; |
114 |
|
|
119 |
GC scratch_cursor_gc; |
GC scratch_cursor_gc; |
120 |
|
|
121 |
/* These variables describe the range of text currently shown in its |
/* These variables describe the range of text currently shown in its |
122 |
mouse-face, together with the window they apply to. As long as |
mouse-face, together with the window they apply to. As long as |
123 |
the mouse stays within this range, we need not redraw anything on |
the mouse stays within this range, we need not redraw anything on |
124 |
its account. Rows and columns are glyph matrix positions in |
its account. Rows and columns are glyph matrix positions in |
125 |
MOUSE_FACE_WINDOW. */ |
MOUSE_FACE_WINDOW. */ |
139 |
/* FRAME and X, Y position of mouse when last checked for |
/* FRAME and X, Y position of mouse when last checked for |
140 |
highlighting. X and Y can be negative or out of range for the frame. */ |
highlighting. X and Y can be negative or out of range for the frame. */ |
141 |
struct frame *mouse_face_mouse_frame; |
struct frame *mouse_face_mouse_frame; |
|
|
|
142 |
int mouse_face_mouse_x, mouse_face_mouse_y; |
int mouse_face_mouse_x, mouse_face_mouse_y; |
143 |
|
|
144 |
/* Nonzero means defer mouse-motion highlighting. */ |
/* Nonzero means defer mouse-motion highlighting. */ |
151 |
|
|
152 |
char *mac_id_name; |
char *mac_id_name; |
153 |
|
|
154 |
|
/* The number of fonts actually stored in the font table. |
155 |
|
font_table[n] is used and valid iff 0 <= n < n_fonts. 0 <= |
156 |
|
n_fonts <= font_table_size and font_table[i].name != 0. */ |
157 |
|
int n_fonts; |
158 |
|
|
159 |
/* Pointer to bitmap records. */ |
/* Pointer to bitmap records. */ |
160 |
struct mac_bitmap_record *bitmaps; |
struct mac_bitmap_record *bitmaps; |
161 |
|
|
212 |
extern struct x_display_info *x_display_info_for_display P_ ((Display *)); |
extern struct x_display_info *x_display_info_for_display P_ ((Display *)); |
213 |
extern struct x_display_info *x_display_info_for_name P_ ((Lisp_Object)); |
extern struct x_display_info *x_display_info_for_name P_ ((Lisp_Object)); |
214 |
|
|
215 |
extern struct mac_display_info *mac_term_init (); |
extern struct mac_display_info *mac_term_init P_ ((Lisp_Object, char *, char *)); |
216 |
|
|
217 |
extern Lisp_Object x_list_fonts P_ ((struct frame *, Lisp_Object, int, int)); |
extern Lisp_Object x_list_fonts P_ ((struct frame *, Lisp_Object, int, int)); |
218 |
extern struct font_info *x_get_font_info P_ ((struct frame *f, int)); |
extern struct font_info *x_get_font_info P_ ((struct frame *f, int)); |
237 |
/* Menubar "widget" handle. */ |
/* Menubar "widget" handle. */ |
238 |
int menubar_widget; |
int menubar_widget; |
239 |
|
|
|
Window mWP; /* pointer to QuickDraw window */ |
|
240 |
FRAME_PTR mFP; /* points back to the frame struct */ |
FRAME_PTR mFP; /* points back to the frame struct */ |
241 |
|
|
|
#if 0 |
|
|
int mNumCols; /* number of characters per column */ |
|
|
int mNumRows; /* number of characters per row */ |
|
|
int mLineHeight; /* height of one line of text in pixels */ |
|
|
int mCharWidth; /* width of one character in pixels */ |
|
|
int mHomeX; /* X pixel coordinate of lower left |
|
|
corner of character at (0, 0) */ |
|
|
int mHomeY; /* Y pixel coordinate of lower left |
|
|
corner of character at (0, 0) */ |
|
|
int mHighlight; /* current highlight state (0 = off). */ |
|
|
int mTermWinSize; /* num of lines from top of window |
|
|
affected by ins_del_lines; set by |
|
|
set_terminal_window. */ |
|
|
#endif /* 0 */ |
|
|
|
|
|
#if 0 |
|
|
/* stuffs used by xfaces.c */ |
|
|
struct face **param_faces; |
|
|
int n_param_faces; |
|
|
struct face **computed_faces; |
|
|
int n_computed_faces; |
|
|
int size_computed_faces; |
|
|
#endif |
|
|
|
|
242 |
/* Here are the Graphics Contexts for the default font. */ |
/* Here are the Graphics Contexts for the default font. */ |
243 |
GC normal_gc; /* Normal video */ |
GC normal_gc; /* Normal video */ |
244 |
GC reverse_gc; /* Reverse video */ |
GC reverse_gc; /* Reverse video */ |
272 |
unsigned long mouse_pixel; |
unsigned long mouse_pixel; |
273 |
unsigned long cursor_foreground_pixel; |
unsigned long cursor_foreground_pixel; |
274 |
|
|
275 |
|
#if 0 |
276 |
/* Foreground color for scroll bars. A value of -1 means use the |
/* Foreground color for scroll bars. A value of -1 means use the |
277 |
default (black for non-toolkit scroll bars). */ |
default (black for non-toolkit scroll bars). */ |
278 |
unsigned long scroll_bar_foreground_pixel; |
unsigned long scroll_bar_foreground_pixel; |
281 |
default (background color of the frame for non-toolkit scroll |
default (background color of the frame for non-toolkit scroll |
282 |
bars). */ |
bars). */ |
283 |
unsigned long scroll_bar_background_pixel; |
unsigned long scroll_bar_background_pixel; |
284 |
|
#endif |
285 |
|
|
286 |
/* Descriptor for the cursor in use for this window. */ |
/* Descriptor for the cursor in use for this window. */ |
287 |
Cursor text_cursor; |
Cursor text_cursor; |
309 |
ControlRef hourglass_control; |
ControlRef hourglass_control; |
310 |
#endif |
#endif |
311 |
|
|
|
#if 0 |
|
|
DWORD dwStyle; |
|
|
#endif |
|
|
|
|
312 |
/* This is the Emacs structure for the display this frame is on. */ |
/* This is the Emacs structure for the display this frame is on. */ |
313 |
/* struct w32_display_info *display_info; */ |
/* struct w32_display_info *display_info; */ |
314 |
|
|
325 |
/* Nonzero means a menu command is being processed. */ |
/* Nonzero means a menu command is being processed. */ |
326 |
char menu_command_in_progress; |
char menu_command_in_progress; |
327 |
|
|
|
/* Nonzero means menubar is about to become active, but should be |
|
|
brought up to date first. */ |
|
|
volatile char pending_menu_activation; |
|
|
|
|
328 |
/* Relief GCs, colors etc. */ |
/* Relief GCs, colors etc. */ |
329 |
struct relief |
struct relief |
330 |
{ |
{ |
348 |
#define FRAME_X_OUTPUT(f) ((f)->output_data.mac) |
#define FRAME_X_OUTPUT(f) ((f)->output_data.mac) |
349 |
|
|
350 |
/* Return the Mac window used for displaying data in frame F. */ |
/* Return the Mac window used for displaying data in frame F. */ |
351 |
#define FRAME_MAC_WINDOW(f) ((f)->output_data.mac->mWP) |
#define FRAME_MAC_WINDOW(f) ((f)->output_data.mac->window_desc) |
352 |
#define FRAME_X_WINDOW(f) ((f)->output_data.mac->mWP) |
#define FRAME_X_WINDOW(f) ((f)->output_data.mac->window_desc) |
353 |
|
|
354 |
#define FRAME_FOREGROUND_PIXEL(f) ((f)->output_data.x->foreground_pixel) |
#define FRAME_FOREGROUND_PIXEL(f) ((f)->output_data.x->foreground_pixel) |
355 |
#define FRAME_BACKGROUND_PIXEL(f) ((f)->output_data.x->background_pixel) |
#define FRAME_BACKGROUND_PIXEL(f) ((f)->output_data.x->background_pixel) |
475 |
|
|
476 |
/* Return the inside width of a vertical scroll bar, given the outside |
/* Return the inside width of a vertical scroll bar, given the outside |
477 |
width. */ |
width. */ |
478 |
#define VERTICAL_SCROLL_BAR_INSIDE_WIDTH(f,width) \ |
#define VERTICAL_SCROLL_BAR_INSIDE_WIDTH(f, width) \ |
479 |
((width) \ |
((width) \ |
480 |
- VERTICAL_SCROLL_BAR_LEFT_BORDER \ |
- VERTICAL_SCROLL_BAR_LEFT_BORDER \ |
481 |
- VERTICAL_SCROLL_BAR_RIGHT_BORDER \ |
- VERTICAL_SCROLL_BAR_RIGHT_BORDER \ |