Mercurial > hg > xemacs-beta
comparison src/gutter.c @ 5077:d372b17f63ce
clean up toolbar/gutter edge geometry
-------------------- ChangeLog entries follow: --------------------
src/ChangeLog addition:
2010-02-25 Ben Wing <ben@xemacs.org>
* EmacsFrame.c (EmacsFrameSetValues):
* frame-impl.h:
* frame-impl.h (struct frame):
* frame-impl.h (FRAME_THEORETICAL_TOP_TOOLBAR_HEIGHT):
* frame-impl.h (FRAME_THEORETICAL_TOP_TOOLBAR_BORDER_WIDTH):
* frame-impl.h (FRAME_REAL_TOP_TOOLBAR_HEIGHT):
* frame-impl.h (FRAME_REAL_TOP_TOOLBAR_BORDER_WIDTH):
* frame-impl.h (FRAME_REAL_TOP_TOOLBAR_VISIBLE):
* frame-impl.h (FRAME_REAL_TOP_TOOLBAR_BOUNDS):
* frame.h:
* frame.h (enum edge_pos):
* gutter.c:
* gutter.c (get_gutter_coords):
* gutter.c (display_boxes_in_gutter_p):
* gutter.c (construct_window_gutter_spec):
* gutter.c (calculate_gutter_size_from_display_lines):
* gutter.c (calculate_gutter_size):
* gutter.c (output_gutter):
* gutter.c (clear_gutter):
* gutter.c (mark_gutters):
* gutter.c (gutter_extent_signal_changed_region_maybe):
* gutter.c (update_gutter_geometry):
* gutter.c (update_frame_gutter_geometry):
* gutter.c (update_frame_gutters):
* gutter.c (reset_gutter_display_lines):
* gutter.c (redraw_exposed_gutter):
* gutter.c (redraw_exposed_gutters):
* gutter.c (free_frame_gutters):
* gutter.c (decode_gutter_position):
* gutter.c (Fset_default_gutter_position):
* gutter.c (Fgutter_pixel_width):
* gutter.c (Fgutter_pixel_height):
* gutter.c (recompute_overlaying_specifier):
* gutter.c (gutter_specs_changed_1):
* gutter.c (gutter_specs_changed):
* gutter.c (top_gutter_specs_changed):
* gutter.c (bottom_gutter_specs_changed):
* gutter.c (left_gutter_specs_changed):
* gutter.c (right_gutter_specs_changed):
* gutter.c (gutter_geometry_changed_in_window):
* gutter.c (init_frame_gutters):
* gutter.c (specifier_vars_of_gutter):
* gutter.h:
* gutter.h (WINDOW_REAL_TOP_GUTTER_BOUNDS):
* gutter.h (FRAME_TOP_GUTTER_BOUNDS):
* lisp.h (enum edge_style):
* native-gtk-toolbar.c:
* native-gtk-toolbar.c (gtk_output_toolbar):
* native-gtk-toolbar.c (gtk_clear_toolbar):
* native-gtk-toolbar.c (gtk_output_frame_toolbars):
* native-gtk-toolbar.c (gtk_initialize_frame_toolbars):
* toolbar-msw.c:
* toolbar-msw.c (TOOLBAR_HANDLE):
* toolbar-msw.c (allocate_toolbar_item_id):
* toolbar-msw.c (mswindows_clear_toolbar):
* toolbar-msw.c (mswindows_output_toolbar):
* toolbar-msw.c (mswindows_move_toolbar):
* toolbar-msw.c (mswindows_redraw_exposed_toolbars):
* toolbar-msw.c (mswindows_initialize_frame_toolbars):
* toolbar-msw.c (mswindows_output_frame_toolbars):
* toolbar-msw.c (mswindows_clear_frame_toolbars):
* toolbar-msw.c (DELETE_TOOLBAR):
* toolbar-msw.c (mswindows_free_frame_toolbars):
* toolbar-msw.c (mswindows_get_toolbar_button_text):
* toolbar-xlike.c:
* toolbar-xlike.c (__prepare_button_area):
* toolbar-xlike.c (XLIKE_OUTPUT_BUTTONS_LOOP):
* toolbar-xlike.c (xlike_output_toolbar):
* toolbar-xlike.c (xlike_clear_toolbar):
* toolbar-xlike.c (xlike_output_frame_toolbars):
* toolbar-xlike.c (xlike_clear_frame_toolbars):
* toolbar-xlike.c (xlike_redraw_exposed_toolbar):
* toolbar-xlike.c (xlike_redraw_exposed_toolbars):
* toolbar-xlike.c (xlike_redraw_frame_toolbars):
* toolbar.c:
* toolbar.c (decode_toolbar_position):
* toolbar.c (Fset_default_toolbar_position):
* toolbar.c (mark_frame_toolbar_buttons_dirty):
* toolbar.c (compute_frame_toolbar_buttons):
* toolbar.c (set_frame_toolbar):
* toolbar.c (compute_frame_toolbars_data):
* toolbar.c (update_frame_toolbars_geometry):
* toolbar.c (init_frame_toolbars):
* toolbar.c (get_toolbar_coords):
* toolbar.c (CHECK_TOOLBAR):
* toolbar.c (toolbar_buttons_at_pixpos):
* toolbar.c (CTB_ERROR):
* toolbar.c (recompute_overlaying_specifier):
* toolbar.c (specifier_vars_of_toolbar):
* toolbar.h:
* toolbar.h (SET_TOOLBAR_WAS_VISIBLE_FLAG):
Create new enum edge_pos with TOP_EDGE, BOTTOM_EDGE, LEFT_EDGE,
RIGHT_EDGE; subsume TOP_BORDER, TOP_GUTTER, enum toolbar_pos,
enum gutter_pos, etc.
Create EDGE_POS_LOOP, subsuming GUTTER_POS_LOOP.
Create NUM_EDGES, use in many places instead of hardcoded '4'.
Instead of top_toolbar_was_visible, bottom_toolbar_was_visible,
etc. make an array toolbar_was_visible[NUM_EDGES]. This increases
the frame size by 15 bytes or so (could be 3 if we use Boolbytes)
but hardly seems w to matter -- frames are heavy weight objects
anyway. Same with top_gutter_was_visible, etc.
Remove duplicated SET_TOOLBAR_WAS_VISIBLE_FLAG and put defn in
one place (toolbar.h).
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Thu, 25 Feb 2010 04:45:13 -0600 |
parents | 548f1f47eb82 |
children | 0ca81354c4c7 |
comparison
equal
deleted
inserted
replaced
5076:d555581e3cba | 5077:d372b17f63ce |
---|---|
34 #include "glyphs.h" | 34 #include "glyphs.h" |
35 #include "redisplay.h" | 35 #include "redisplay.h" |
36 #include "window.h" | 36 #include "window.h" |
37 #include "gutter.h" | 37 #include "gutter.h" |
38 | 38 |
39 Lisp_Object Vgutter[4]; | 39 Lisp_Object Vgutter[NUM_EDGES]; |
40 Lisp_Object Vgutter_size[4]; | 40 Lisp_Object Vgutter_size[NUM_EDGES]; |
41 Lisp_Object Vgutter_visible_p[4]; | 41 Lisp_Object Vgutter_visible_p[NUM_EDGES]; |
42 Lisp_Object Vgutter_border_width[4]; | 42 Lisp_Object Vgutter_border_width[NUM_EDGES]; |
43 | 43 |
44 Lisp_Object Vdefault_gutter, Vdefault_gutter_visible_p; | 44 Lisp_Object Vdefault_gutter, Vdefault_gutter_visible_p; |
45 Lisp_Object Vdefault_gutter_width, Vdefault_gutter_height; | 45 Lisp_Object Vdefault_gutter_width, Vdefault_gutter_height; |
46 Lisp_Object Vdefault_gutter_border_width; | 46 Lisp_Object Vdefault_gutter_border_width; |
47 | 47 |
50 Lisp_Object Qgutter_size; | 50 Lisp_Object Qgutter_size; |
51 Lisp_Object Qgutter_visible; | 51 Lisp_Object Qgutter_visible; |
52 Lisp_Object Qdefault_gutter_position_changed_hook; | 52 Lisp_Object Qdefault_gutter_position_changed_hook; |
53 | 53 |
54 static void | 54 static void |
55 update_gutter_geometry (struct frame *f, enum gutter_pos pos); | 55 update_gutter_geometry (struct frame *f, enum edge_pos pos); |
56 | |
57 #define SET_GUTTER_WAS_VISIBLE_FLAG(frame, pos, flag) \ | |
58 do { \ | |
59 switch (pos) \ | |
60 { \ | |
61 case TOP_GUTTER: \ | |
62 (frame)->top_gutter_was_visible = flag; \ | |
63 break; \ | |
64 case BOTTOM_GUTTER: \ | |
65 (frame)->bottom_gutter_was_visible = flag; \ | |
66 break; \ | |
67 case LEFT_GUTTER: \ | |
68 (frame)->left_gutter_was_visible = flag; \ | |
69 break; \ | |
70 case RIGHT_GUTTER: \ | |
71 (frame)->right_gutter_was_visible = flag; \ | |
72 break; \ | |
73 default: \ | |
74 ABORT (); \ | |
75 } \ | |
76 } while (0) | |
77 | |
78 static int gutter_was_visible (struct frame* frame, enum gutter_pos pos) | |
79 { | |
80 switch (pos) | |
81 { | |
82 case TOP_GUTTER: | |
83 return frame->top_gutter_was_visible; | |
84 case BOTTOM_GUTTER: | |
85 return frame->bottom_gutter_was_visible; | |
86 case LEFT_GUTTER: | |
87 return frame->left_gutter_was_visible; | |
88 case RIGHT_GUTTER: | |
89 return frame->right_gutter_was_visible; | |
90 default: | |
91 ABORT (); | |
92 return 0; /* To keep the compiler happy */ | |
93 } | |
94 } | |
95 | 56 |
96 #if 0 | 57 #if 0 |
97 static Lisp_Object | 58 static Lisp_Object |
98 frame_topmost_window (struct frame *f) | 59 frame_topmost_window (struct frame *f) |
99 { | 60 { |
170 us the actual height, width and contents of the gutter, but if we | 131 us the actual height, width and contents of the gutter, but if we |
171 use this for calculating the gutter positions we run into trouble | 132 use this for calculating the gutter positions we run into trouble |
172 if it is not the window nearest the gutter. Instead we predetermine | 133 if it is not the window nearest the gutter. Instead we predetermine |
173 the nearest window and then use that.*/ | 134 the nearest window and then use that.*/ |
174 static void | 135 static void |
175 get_gutter_coords (struct frame *f, enum gutter_pos pos, int *x, int *y, | 136 get_gutter_coords (struct frame *f, enum edge_pos pos, int *x, int *y, |
176 int *width, int *height) | 137 int *width, int *height) |
177 { | 138 { |
178 struct window | 139 struct window |
179 * bot = XWINDOW (frame_bottommost_window (f)); | 140 * bot = XWINDOW (frame_bottommost_window (f)); |
180 /* The top and bottom gutters take precedence over the left and | 141 /* The top and bottom gutters take precedence over the left and |
181 right. */ | 142 right. */ |
182 switch (pos) | 143 switch (pos) |
183 { | 144 { |
184 case TOP_GUTTER: | 145 case TOP_EDGE: |
185 *x = FRAME_LEFT_BORDER_END (f); | 146 *x = FRAME_LEFT_BORDER_END (f); |
186 *y = FRAME_TOP_BORDER_END (f); | 147 *y = FRAME_TOP_BORDER_END (f); |
187 *width = FRAME_RIGHT_BORDER_START (f) | 148 *width = FRAME_RIGHT_BORDER_START (f) |
188 - FRAME_LEFT_BORDER_END (f); | 149 - FRAME_LEFT_BORDER_END (f); |
189 *height = FRAME_TOP_GUTTER_BOUNDS (f); | 150 *height = FRAME_TOP_GUTTER_BOUNDS (f); |
190 break; | 151 break; |
191 | 152 |
192 case BOTTOM_GUTTER: | 153 case BOTTOM_EDGE: |
193 *x = FRAME_LEFT_BORDER_END (f); | 154 *x = FRAME_LEFT_BORDER_END (f); |
194 *y = WINDOW_BOTTOM (bot); | 155 *y = WINDOW_BOTTOM (bot); |
195 *width = FRAME_RIGHT_BORDER_START (f) | 156 *width = FRAME_RIGHT_BORDER_START (f) |
196 - FRAME_LEFT_BORDER_END (f); | 157 - FRAME_LEFT_BORDER_END (f); |
197 *height = FRAME_BOTTOM_GUTTER_BOUNDS (f); | 158 *height = FRAME_BOTTOM_GUTTER_BOUNDS (f); |
198 break; | 159 break; |
199 | 160 |
200 case LEFT_GUTTER: | 161 case LEFT_EDGE: |
201 *x = FRAME_LEFT_BORDER_END (f); | 162 *x = FRAME_LEFT_BORDER_END (f); |
202 *y = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f); | 163 *y = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f); |
203 *width = FRAME_LEFT_GUTTER_BOUNDS (f); | 164 *width = FRAME_LEFT_GUTTER_BOUNDS (f); |
204 *height = WINDOW_BOTTOM (bot) | 165 *height = WINDOW_BOTTOM (bot) |
205 - (FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f)); | 166 - (FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f)); |
206 break; | 167 break; |
207 | 168 |
208 case RIGHT_GUTTER: | 169 case RIGHT_EDGE: |
209 *x = FRAME_RIGHT_BORDER_START (f) | 170 *x = FRAME_RIGHT_BORDER_START (f) |
210 - FRAME_RIGHT_GUTTER_BOUNDS (f); | 171 - FRAME_RIGHT_GUTTER_BOUNDS (f); |
211 *y = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f); | 172 *y = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f); |
212 *width = FRAME_RIGHT_GUTTER_BOUNDS (f); | 173 *width = FRAME_RIGHT_GUTTER_BOUNDS (f); |
213 *height = WINDOW_BOTTOM (bot) | 174 *height = WINDOW_BOTTOM (bot) |
228 window. 0 means the display_box is in the gutter but the | 189 window. 0 means the display_box is in the gutter but the |
229 display_glyph_area is not. */ | 190 display_glyph_area is not. */ |
230 int display_boxes_in_gutter_p (struct frame *f, struct display_box* db, | 191 int display_boxes_in_gutter_p (struct frame *f, struct display_box* db, |
231 struct display_glyph_area* dga) | 192 struct display_glyph_area* dga) |
232 { | 193 { |
233 enum gutter_pos pos; | 194 enum edge_pos pos; |
234 GUTTER_POS_LOOP (pos) | 195 EDGE_POS_LOOP (pos) |
235 { | 196 { |
236 if (FRAME_GUTTER_VISIBLE (f, pos)) | 197 if (FRAME_GUTTER_VISIBLE (f, pos)) |
237 { | 198 { |
238 int x, y, width, height; | 199 int x, y, width, height; |
239 get_gutter_coords (f, pos, &x, &y, &width, &height); | 200 get_gutter_coords (f, pos, &x, &y, &width, &height); |
255 } | 216 } |
256 | 217 |
257 /* Convert the gutter specifier into something we can actually | 218 /* Convert the gutter specifier into something we can actually |
258 display. */ | 219 display. */ |
259 static Lisp_Object construct_window_gutter_spec (struct window* w, | 220 static Lisp_Object construct_window_gutter_spec (struct window* w, |
260 enum gutter_pos pos) | 221 enum edge_pos pos) |
261 { | 222 { |
262 Lisp_Object rest, *args; | 223 Lisp_Object rest, *args; |
263 int nargs = 0; | 224 int nargs = 0; |
264 Lisp_Object gutter = RAW_WINDOW_GUTTER (w, pos); | 225 Lisp_Object gutter = RAW_WINDOW_GUTTER (w, pos); |
265 | 226 |
287 | 248 |
288 /* Sizing gutters is a pain so we try and help the user by determining | 249 /* Sizing gutters is a pain so we try and help the user by determining |
289 what height will accommodate all lines. This is useless on left and | 250 what height will accommodate all lines. This is useless on left and |
290 right gutters as we always have a maximal number of lines. */ | 251 right gutters as we always have a maximal number of lines. */ |
291 static int | 252 static int |
292 calculate_gutter_size_from_display_lines (enum gutter_pos pos, | 253 calculate_gutter_size_from_display_lines (enum edge_pos pos, |
293 display_line_dynarr* ddla) | 254 display_line_dynarr* ddla) |
294 { | 255 { |
295 int size = 0; | 256 int size = 0; |
296 struct display_line *dl; | 257 struct display_line *dl; |
297 | 258 |
298 /* For top and bottom the calculation is easy. */ | 259 /* For top and bottom the calculation is easy. */ |
299 if (pos == TOP_GUTTER || pos == BOTTOM_GUTTER) | 260 if (pos == TOP_EDGE || pos == BOTTOM_EDGE) |
300 { | 261 { |
301 /* grab coordinates of last line */ | 262 /* grab coordinates of last line */ |
302 if (Dynarr_length (ddla)) | 263 if (Dynarr_length (ddla)) |
303 { | 264 { |
304 dl = Dynarr_atp (ddla, Dynarr_length (ddla) - 1); | 265 dl = Dynarr_atp (ddla, Dynarr_length (ddla) - 1); |
331 | 292 |
332 return size; | 293 return size; |
333 } | 294 } |
334 | 295 |
335 static Lisp_Object | 296 static Lisp_Object |
336 calculate_gutter_size (struct window *w, enum gutter_pos pos) | 297 calculate_gutter_size (struct window *w, enum edge_pos pos) |
337 { | 298 { |
338 struct frame* f = XFRAME (WINDOW_FRAME (w)); | 299 struct frame* f = XFRAME (WINDOW_FRAME (w)); |
339 display_line_dynarr *ddla; | 300 display_line_dynarr *ddla; |
340 Lisp_Object ret = Qnil; | 301 Lisp_Object ret = Qnil; |
341 | 302 |
377 | 338 |
378 return ret; | 339 return ret; |
379 } | 340 } |
380 | 341 |
381 static void | 342 static void |
382 output_gutter (struct frame *f, enum gutter_pos pos, int force) | 343 output_gutter (struct frame *f, enum edge_pos pos, int force) |
383 { | 344 { |
384 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); | 345 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); |
385 struct device *d = XDEVICE (f->device); | 346 struct device *d = XDEVICE (f->device); |
386 struct window* w = XWINDOW (window); | 347 struct window* w = XWINDOW (window); |
387 int x, y, width, height, ypos; | 348 int x, y, width, height, ypos; |
424 cdla_len != Dynarr_length (ddla) || | 385 cdla_len != Dynarr_length (ddla) || |
425 (f->extents_changed && w->gutter_extent_modiff[pos])) | 386 (f->extents_changed && w->gutter_extent_modiff[pos])) |
426 { | 387 { |
427 #ifdef DEBUG_GUTTERS | 388 #ifdef DEBUG_GUTTERS |
428 stderr_out ("gutter redisplay [%s %dx%d@%d+%d] triggered by %s,\n", | 389 stderr_out ("gutter redisplay [%s %dx%d@%d+%d] triggered by %s,\n", |
429 pos == TOP_GUTTER ? "TOP" : | 390 pos == TOP_EDGE ? "TOP" : |
430 pos == BOTTOM_GUTTER ? "BOTTOM" : | 391 pos == BOTTOM_EDGE ? "BOTTOM" : |
431 pos == LEFT_GUTTER ? "LEFT" : "RIGHT", | 392 pos == LEFT_EDGE ? "LEFT" : "RIGHT", |
432 width, height, x, y, force ? "force" : | 393 width, height, x, y, force ? "force" : |
433 f->faces_changed ? "f->faces_changed" : | 394 f->faces_changed ? "f->faces_changed" : |
434 f->frame_changed ? "f->frame_changed" : | 395 f->frame_changed ? "f->frame_changed" : |
435 f->gutter_changed ? "f->gutter_changed" : | 396 f->gutter_changed ? "f->gutter_changed" : |
436 f->glyphs_changed ? "f->glyphs_changed" : | 397 f->glyphs_changed ? "f->glyphs_changed" : |
510 | 471 |
511 w->gutter_extent_modiff [pos] = 0; | 472 w->gutter_extent_modiff [pos] = 0; |
512 } | 473 } |
513 | 474 |
514 static void | 475 static void |
515 clear_gutter (struct frame *f, enum gutter_pos pos) | 476 clear_gutter (struct frame *f, enum edge_pos pos) |
516 { | 477 { |
517 int x, y, width, height; | 478 int x, y, width, height; |
518 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); | 479 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); |
519 face_index findex = get_builtin_face_cache_index (XWINDOW (window), | 480 face_index findex = get_builtin_face_cache_index (XWINDOW (window), |
520 Vwidget_face); | 481 Vwidget_face); |
521 get_gutter_coords (f, pos, &x, &y, &width, &height); | 482 get_gutter_coords (f, pos, &x, &y, &width, &height); |
522 | 483 |
523 SET_GUTTER_WAS_VISIBLE_FLAG (f, pos, 0); | 484 f->gutter_was_visible[pos] = 0; |
524 | 485 |
525 redisplay_clear_region (window, findex, x, y, width, height); | 486 redisplay_clear_region (window, findex, x, y, width, height); |
526 } | 487 } |
527 | 488 |
528 /* [[#### I don't currently believe that redisplay needs to mark the | 489 /* [[#### I don't currently believe that redisplay needs to mark the |
535 /* See the comment in image_instantiate_cache_result as to why marking | 496 /* See the comment in image_instantiate_cache_result as to why marking |
536 the glyph will also mark the image_instance. */ | 497 the glyph will also mark the image_instance. */ |
537 void | 498 void |
538 mark_gutters (struct frame *f) | 499 mark_gutters (struct frame *f) |
539 { | 500 { |
540 enum gutter_pos pos; | 501 enum edge_pos pos; |
541 GUTTER_POS_LOOP (pos) | 502 EDGE_POS_LOOP (pos) |
542 { | 503 { |
543 if (f->current_display_lines[pos]) | 504 if (f->current_display_lines[pos]) |
544 mark_redisplay_structs (f->current_display_lines[pos]); | 505 mark_redisplay_structs (f->current_display_lines[pos]); |
545 /* [[#### Do we really need to mark the desired lines?]] | 506 /* [[#### Do we really need to mark the desired lines?]] |
546 ALWAYS mark everything. --ben */ | 507 ALWAYS mark everything. --ben */ |
562 Lisp_Object frmcons, devcons, concons; | 523 Lisp_Object frmcons, devcons, concons; |
563 | 524 |
564 FRAME_LOOP_NO_BREAK (frmcons, devcons, concons) | 525 FRAME_LOOP_NO_BREAK (frmcons, devcons, concons) |
565 { | 526 { |
566 struct frame *f = XFRAME (XCAR (frmcons)); | 527 struct frame *f = XFRAME (XCAR (frmcons)); |
567 enum gutter_pos pos; | 528 enum edge_pos pos; |
568 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); | 529 Lisp_Object window = FRAME_LAST_NONMINIBUF_WINDOW (f); |
569 struct window* w = XWINDOW (window); | 530 struct window* w = XWINDOW (window); |
570 | 531 |
571 GUTTER_POS_LOOP (pos) | 532 EDGE_POS_LOOP (pos) |
572 { | 533 { |
573 if (EQ (WINDOW_GUTTER (w, pos), obj)) | 534 if (EQ (WINDOW_GUTTER (w, pos), obj)) |
574 { | 535 { |
575 w->gutter_extent_modiff[pos]++; | 536 w->gutter_extent_modiff[pos]++; |
576 } | 537 } |
579 } | 540 } |
580 | 541 |
581 /* We have to change the gutter geometry separately to the gutter | 542 /* We have to change the gutter geometry separately to the gutter |
582 update since it needs to occur outside of redisplay proper. */ | 543 update since it needs to occur outside of redisplay proper. */ |
583 static void | 544 static void |
584 update_gutter_geometry (struct frame *f, enum gutter_pos pos) | 545 update_gutter_geometry (struct frame *f, enum edge_pos pos) |
585 { | 546 { |
586 /* If the gutter geometry has changed then re-layout the | 547 /* If the gutter geometry has changed then re-layout the |
587 frame. If we are in display there is almost no point in doing | 548 frame. If we are in display there is almost no point in doing |
588 anything else since the frame size changes will be delayed | 549 anything else since the frame size changes will be delayed |
589 until we are out of redisplay proper. */ | 550 until we are out of redisplay proper. */ |
605 { | 566 { |
606 if (f->gutter_changed | 567 if (f->gutter_changed |
607 || f->frame_layout_changed | 568 || f->frame_layout_changed |
608 || f->windows_structure_changed) | 569 || f->windows_structure_changed) |
609 { | 570 { |
610 enum gutter_pos pos; | 571 enum edge_pos pos; |
611 | 572 |
612 /* If the gutter geometry has changed then re-layout the | 573 /* If the gutter geometry has changed then re-layout the |
613 frame. If we are in display there is almost no point in doing | 574 frame. If we are in display there is almost no point in doing |
614 anything else since the frame size changes will be delayed | 575 anything else since the frame size changes will be delayed |
615 until we are out of redisplay proper. */ | 576 until we are out of redisplay proper. */ |
616 GUTTER_POS_LOOP (pos) | 577 EDGE_POS_LOOP (pos) |
617 { | 578 { |
618 update_gutter_geometry (f, pos); | 579 update_gutter_geometry (f, pos); |
619 } | 580 } |
620 } | 581 } |
621 } | 582 } |
627 f->gutter_changed || f->glyphs_changed || | 588 f->gutter_changed || f->glyphs_changed || |
628 f->size_changed || f->subwindows_changed || | 589 f->size_changed || f->subwindows_changed || |
629 f->windows_changed || f->windows_structure_changed || | 590 f->windows_changed || f->windows_structure_changed || |
630 f->extents_changed || f->frame_layout_changed) | 591 f->extents_changed || f->frame_layout_changed) |
631 { | 592 { |
632 enum gutter_pos pos; | 593 enum edge_pos pos; |
633 | 594 |
634 /* We don't actually care about these when outputting the gutter | 595 /* We don't actually care about these when outputting the gutter |
635 so locally disable them. */ | 596 so locally disable them. */ |
636 int local_clip_changed = f->clip_changed; | 597 int local_clip_changed = f->clip_changed; |
637 int local_buffers_changed = f->buffers_changed; | 598 int local_buffers_changed = f->buffers_changed; |
638 f->clip_changed = 0; | 599 f->clip_changed = 0; |
639 f->buffers_changed = 0; | 600 f->buffers_changed = 0; |
640 | 601 |
641 /* and output */ | 602 /* and output */ |
642 GUTTER_POS_LOOP (pos) | 603 EDGE_POS_LOOP (pos) |
643 { | 604 { |
644 if (FRAME_GUTTER_VISIBLE (f, pos)) | 605 if (FRAME_GUTTER_VISIBLE (f, pos)) |
645 output_gutter (f, pos, 0); | 606 output_gutter (f, pos, 0); |
646 | 607 |
647 else if (gutter_was_visible (f, pos)) | 608 else if (f->gutter_was_visible[pos]) |
648 clear_gutter (f, pos); | 609 clear_gutter (f, pos); |
649 } | 610 } |
650 | 611 |
651 f->clip_changed = local_clip_changed; | 612 f->clip_changed = local_clip_changed; |
652 f->buffers_changed = local_buffers_changed; | 613 f->buffers_changed = local_buffers_changed; |
655 } | 616 } |
656 | 617 |
657 void | 618 void |
658 reset_gutter_display_lines (struct frame* f) | 619 reset_gutter_display_lines (struct frame* f) |
659 { | 620 { |
660 enum gutter_pos pos; | 621 enum edge_pos pos; |
661 GUTTER_POS_LOOP (pos) | 622 EDGE_POS_LOOP (pos) |
662 { | 623 { |
663 if (f->current_display_lines[pos]) | 624 if (f->current_display_lines[pos]) |
664 Dynarr_reset (f->current_display_lines[pos]); | 625 Dynarr_reset (f->current_display_lines[pos]); |
665 } | 626 } |
666 } | 627 } |
667 | 628 |
668 static void | 629 static void |
669 redraw_exposed_gutter (struct frame *f, enum gutter_pos pos, int x, int y, | 630 redraw_exposed_gutter (struct frame *f, enum edge_pos pos, int x, int y, |
670 int width, int height) | 631 int width, int height) |
671 { | 632 { |
672 int g_x, g_y, g_width, g_height; | 633 int g_x, g_y, g_width, g_height; |
673 | 634 |
674 get_gutter_coords (f, pos, &g_x, &g_y, &g_width, &g_height); | 635 get_gutter_coords (f, pos, &g_x, &g_y, &g_width, &g_height); |
695 | 656 |
696 void | 657 void |
697 redraw_exposed_gutters (struct frame *f, int x, int y, int width, | 658 redraw_exposed_gutters (struct frame *f, int x, int y, int width, |
698 int height) | 659 int height) |
699 { | 660 { |
700 enum gutter_pos pos; | 661 enum edge_pos pos; |
701 | 662 |
702 /* We are already inside the critical section -- our caller did that. */ | 663 /* We are already inside the critical section -- our caller did that. */ |
703 GUTTER_POS_LOOP (pos) | 664 EDGE_POS_LOOP (pos) |
704 { | 665 { |
705 if (FRAME_GUTTER_VISIBLE (f, pos)) | 666 if (FRAME_GUTTER_VISIBLE (f, pos)) |
706 redraw_exposed_gutter (f, pos, x, y, width, height); | 667 redraw_exposed_gutter (f, pos, x, y, width, height); |
707 } | 668 } |
708 } | 669 } |
709 | 670 |
710 void | 671 void |
711 free_frame_gutters (struct frame *f) | 672 free_frame_gutters (struct frame *f) |
712 { | 673 { |
713 enum gutter_pos pos; | 674 enum edge_pos pos; |
714 GUTTER_POS_LOOP (pos) | 675 EDGE_POS_LOOP (pos) |
715 { | 676 { |
716 if (f->current_display_lines[pos]) | 677 if (f->current_display_lines[pos]) |
717 { | 678 { |
718 free_display_lines (f->current_display_lines[pos]); | 679 free_display_lines (f->current_display_lines[pos]); |
719 f->current_display_lines[pos] = 0; | 680 f->current_display_lines[pos] = 0; |
724 f->desired_display_lines[pos] = 0; | 685 f->desired_display_lines[pos] = 0; |
725 } | 686 } |
726 } | 687 } |
727 } | 688 } |
728 | 689 |
729 static enum gutter_pos | 690 static enum edge_pos |
730 decode_gutter_position (Lisp_Object position) | 691 decode_gutter_position (Lisp_Object position) |
731 { | 692 { |
732 if (EQ (position, Qtop)) return TOP_GUTTER; | 693 if (EQ (position, Qtop)) return TOP_EDGE; |
733 if (EQ (position, Qbottom)) return BOTTOM_GUTTER; | 694 if (EQ (position, Qbottom)) return BOTTOM_EDGE; |
734 if (EQ (position, Qleft)) return LEFT_GUTTER; | 695 if (EQ (position, Qleft)) return LEFT_EDGE; |
735 if (EQ (position, Qright)) return RIGHT_GUTTER; | 696 if (EQ (position, Qright)) return RIGHT_EDGE; |
736 invalid_constant ("Invalid gutter position", position); | 697 invalid_constant ("Invalid gutter position", position); |
737 | 698 |
738 RETURN_NOT_REACHED (TOP_GUTTER); | 699 RETURN_NOT_REACHED (TOP_EDGE); |
739 } | 700 } |
740 | 701 |
741 DEFUN ("set-default-gutter-position", Fset_default_gutter_position, 1, 1, 0, /* | 702 DEFUN ("set-default-gutter-position", Fset_default_gutter_position, 1, 1, 0, /* |
742 Set the position that the `default-gutter' will be displayed at. | 703 Set the position that the `default-gutter' will be displayed at. |
743 Valid positions are `top', `bottom', `left' and `right'. | 704 Valid positions are `top', `bottom', `left' and `right'. |
744 See `default-gutter-position'. | 705 See `default-gutter-position'. |
745 */ | 706 */ |
746 (position)) | 707 (position)) |
747 { | 708 { |
748 enum gutter_pos cur = decode_gutter_position (Vdefault_gutter_position); | 709 enum edge_pos cur = decode_gutter_position (Vdefault_gutter_position); |
749 enum gutter_pos new_ = decode_gutter_position (position); | 710 enum edge_pos new_ = decode_gutter_position (position); |
750 | 711 |
751 if (cur != new_) | 712 if (cur != new_) |
752 { | 713 { |
753 /* The following calls will automatically cause the dirty | 714 /* The following calls will automatically cause the dirty |
754 flags to be set; we delay frame size changes to avoid | 715 flags to be set; we delay frame size changes to avoid |
758 | 719 |
759 set_specifier_fallback (Vgutter[cur], list1 (Fcons (Qnil, Qnil))); | 720 set_specifier_fallback (Vgutter[cur], list1 (Fcons (Qnil, Qnil))); |
760 set_specifier_fallback (Vgutter[new_], Vdefault_gutter); | 721 set_specifier_fallback (Vgutter[new_], Vdefault_gutter); |
761 set_specifier_fallback (Vgutter_size[cur], list1 (Fcons (Qnil, Qzero))); | 722 set_specifier_fallback (Vgutter_size[cur], list1 (Fcons (Qnil, Qzero))); |
762 set_specifier_fallback (Vgutter_size[new_], | 723 set_specifier_fallback (Vgutter_size[new_], |
763 new_ == TOP_GUTTER || new_ == BOTTOM_GUTTER | 724 new_ == TOP_EDGE || new_ == BOTTOM_EDGE |
764 ? Vdefault_gutter_height | 725 ? Vdefault_gutter_height |
765 : Vdefault_gutter_width); | 726 : Vdefault_gutter_width); |
766 set_specifier_fallback (Vgutter_border_width[cur], | 727 set_specifier_fallback (Vgutter_border_width[cur], |
767 list1 (Fcons (Qnil, Qzero))); | 728 list1 (Fcons (Qnil, Qzero))); |
768 set_specifier_fallback (Vgutter_border_width[new_], | 729 set_specifier_fallback (Vgutter_border_width[new_], |
795 the current window. | 756 the current window. |
796 */ | 757 */ |
797 (pos, locale)) | 758 (pos, locale)) |
798 { | 759 { |
799 int x, y, width, height; | 760 int x, y, width, height; |
800 enum gutter_pos p = TOP_GUTTER; | 761 enum edge_pos p = TOP_EDGE; |
801 struct frame *f = decode_frame (FW_FRAME (locale)); | 762 struct frame *f = decode_frame (FW_FRAME (locale)); |
802 | 763 |
803 if (NILP (pos)) | 764 if (NILP (pos)) |
804 pos = Vdefault_gutter_position; | 765 pos = Vdefault_gutter_position; |
805 p = decode_gutter_position (pos); | 766 p = decode_gutter_position (pos); |
816 the current window. | 777 the current window. |
817 */ | 778 */ |
818 (pos, locale)) | 779 (pos, locale)) |
819 { | 780 { |
820 int x, y, width, height; | 781 int x, y, width, height; |
821 enum gutter_pos p = TOP_GUTTER; | 782 enum edge_pos p = TOP_EDGE; |
822 struct frame *f = decode_frame (FW_FRAME (locale)); | 783 struct frame *f = decode_frame (FW_FRAME (locale)); |
823 | 784 |
824 if (NILP (pos)) | 785 if (NILP (pos)) |
825 pos = Vdefault_gutter_position; | 786 pos = Vdefault_gutter_position; |
826 p = decode_gutter_position (pos); | 787 p = decode_gutter_position (pos); |
878 /* | 839 /* |
879 Helper for invalidating the real specifier when default | 840 Helper for invalidating the real specifier when default |
880 specifier caching changes | 841 specifier caching changes |
881 */ | 842 */ |
882 static void | 843 static void |
883 recompute_overlaying_specifier (Lisp_Object real_one[4]) | 844 recompute_overlaying_specifier (Lisp_Object real_one[NUM_EDGES]) |
884 { | 845 { |
885 enum gutter_pos pos = decode_gutter_position (Vdefault_gutter_position); | 846 enum edge_pos pos = decode_gutter_position (Vdefault_gutter_position); |
886 Fset_specifier_dirty_flag (real_one[pos]); | 847 Fset_specifier_dirty_flag (real_one[pos]); |
887 } | 848 } |
888 | 849 |
889 static void gutter_specs_changed (Lisp_Object specifier, struct window *w, | 850 static void gutter_specs_changed (Lisp_Object specifier, struct window *w, |
890 Lisp_Object oldval, enum gutter_pos pos); | 851 Lisp_Object oldval, enum edge_pos pos); |
891 | 852 |
892 static void | 853 static void |
893 gutter_specs_changed_1 (Lisp_Object arg) | 854 gutter_specs_changed_1 (Lisp_Object arg) |
894 { | 855 { |
895 gutter_specs_changed (X1ST (arg), XWINDOW (X2ND (arg)), | 856 gutter_specs_changed (X1ST (arg), XWINDOW (X2ND (arg)), |
896 X3RD (arg), (enum gutter_pos) XINT (X4TH (arg))); | 857 X3RD (arg), (enum edge_pos) XINT (X4TH (arg))); |
897 free_list (arg); | 858 free_list (arg); |
898 } | 859 } |
899 | 860 |
900 static void | 861 static void |
901 gutter_specs_changed (Lisp_Object specifier, struct window *w, | 862 gutter_specs_changed (Lisp_Object specifier, struct window *w, |
902 Lisp_Object oldval, enum gutter_pos pos) | 863 Lisp_Object oldval, enum edge_pos pos) |
903 { | 864 { |
904 if (in_display) | 865 if (in_display) |
905 register_post_redisplay_action (gutter_specs_changed_1, | 866 register_post_redisplay_action (gutter_specs_changed_1, |
906 list4 (specifier, wrap_window (w), | 867 list4 (specifier, wrap_window (w), |
907 oldval, make_int (pos))); | 868 oldval, make_int (pos))); |
924 /* We define all of these so we can access which actual gutter changed. */ | 885 /* We define all of these so we can access which actual gutter changed. */ |
925 static void | 886 static void |
926 top_gutter_specs_changed (Lisp_Object specifier, struct window *w, | 887 top_gutter_specs_changed (Lisp_Object specifier, struct window *w, |
927 Lisp_Object oldval) | 888 Lisp_Object oldval) |
928 { | 889 { |
929 gutter_specs_changed (specifier, w, oldval, TOP_GUTTER); | 890 gutter_specs_changed (specifier, w, oldval, TOP_EDGE); |
930 } | 891 } |
931 | 892 |
932 static void | 893 static void |
933 bottom_gutter_specs_changed (Lisp_Object specifier, struct window *w, | 894 bottom_gutter_specs_changed (Lisp_Object specifier, struct window *w, |
934 Lisp_Object oldval) | 895 Lisp_Object oldval) |
935 { | 896 { |
936 gutter_specs_changed (specifier, w, oldval, BOTTOM_GUTTER); | 897 gutter_specs_changed (specifier, w, oldval, BOTTOM_EDGE); |
937 } | 898 } |
938 | 899 |
939 static void | 900 static void |
940 left_gutter_specs_changed (Lisp_Object specifier, struct window *w, | 901 left_gutter_specs_changed (Lisp_Object specifier, struct window *w, |
941 Lisp_Object oldval) | 902 Lisp_Object oldval) |
942 { | 903 { |
943 gutter_specs_changed (specifier, w, oldval, LEFT_GUTTER); | 904 gutter_specs_changed (specifier, w, oldval, LEFT_EDGE); |
944 } | 905 } |
945 | 906 |
946 static void | 907 static void |
947 right_gutter_specs_changed (Lisp_Object specifier, struct window *w, | 908 right_gutter_specs_changed (Lisp_Object specifier, struct window *w, |
948 Lisp_Object oldval) | 909 Lisp_Object oldval) |
949 { | 910 { |
950 gutter_specs_changed (specifier, w, oldval, RIGHT_GUTTER); | 911 gutter_specs_changed (specifier, w, oldval, RIGHT_EDGE); |
951 } | 912 } |
952 | 913 |
953 static void | 914 static void |
954 default_gutter_specs_changed (Lisp_Object UNUSED (specifier), | 915 default_gutter_specs_changed (Lisp_Object UNUSED (specifier), |
955 struct window *UNUSED (w), | 916 struct window *UNUSED (w), |
978 register_post_redisplay_action (gutter_geometry_changed_in_window_1, | 939 register_post_redisplay_action (gutter_geometry_changed_in_window_1, |
979 list3 (specifier, wrap_window (w), | 940 list3 (specifier, wrap_window (w), |
980 oldval)); | 941 oldval)); |
981 else | 942 else |
982 { | 943 { |
983 enum gutter_pos pos; | 944 enum edge_pos pos; |
984 GUTTER_POS_LOOP (pos) | 945 EDGE_POS_LOOP (pos) |
985 { | 946 { |
986 w->real_gutter_size[pos] = w->gutter_size[pos]; | 947 w->real_gutter_size[pos] = w->gutter_size[pos]; |
987 if (EQ (w->real_gutter_size[pos], Qautodetect) | 948 if (EQ (w->real_gutter_size[pos], Qautodetect) |
988 && !NILP (w->gutter_visible_p[pos])) | 949 && !NILP (w->gutter_visible_p[pos])) |
989 { | 950 { |
1150 } | 1111 } |
1151 | 1112 |
1152 void | 1113 void |
1153 init_frame_gutters (struct frame *f) | 1114 init_frame_gutters (struct frame *f) |
1154 { | 1115 { |
1155 enum gutter_pos pos; | 1116 enum edge_pos pos; |
1156 struct window* w = XWINDOW (FRAME_LAST_NONMINIBUF_WINDOW (f)); | 1117 struct window* w = XWINDOW (FRAME_LAST_NONMINIBUF_WINDOW (f)); |
1157 /* We are here as far in frame creation so cached specifiers are | 1118 /* We are here as far in frame creation so cached specifiers are |
1158 already recomputed, and possibly modified by resource | 1119 already recomputed, and possibly modified by resource |
1159 initialization. We need to recalculate autodetected gutters. */ | 1120 initialization. We need to recalculate autodetected gutters. */ |
1160 GUTTER_POS_LOOP (pos) | 1121 EDGE_POS_LOOP (pos) |
1161 { | 1122 { |
1162 w->real_gutter[pos] = construct_window_gutter_spec (w, pos); | 1123 w->real_gutter[pos] = construct_window_gutter_spec (w, pos); |
1163 w->real_gutter_size[pos] = w->gutter_size[pos]; | 1124 w->real_gutter_size[pos] = w->gutter_size[pos]; |
1164 if (EQ (w->gutter_size[pos], Qautodetect) | 1125 if (EQ (w->gutter_size[pos], Qautodetect) |
1165 && !NILP (w->gutter_visible_p[pos])) | 1126 && !NILP (w->gutter_visible_p[pos])) |
1169 MARK_WINDOWS_CHANGED (w); | 1130 MARK_WINDOWS_CHANGED (w); |
1170 } | 1131 } |
1171 } | 1132 } |
1172 | 1133 |
1173 /* Keep a record of the current sizes of things. */ | 1134 /* Keep a record of the current sizes of things. */ |
1174 GUTTER_POS_LOOP (pos) | 1135 EDGE_POS_LOOP (pos) |
1175 { | 1136 { |
1176 f->current_gutter_bounds[pos] = FRAME_GUTTER_BOUNDS (f, pos); | 1137 f->current_gutter_bounds[pos] = FRAME_GUTTER_BOUNDS (f, pos); |
1177 } | 1138 } |
1178 } | 1139 } |
1179 | 1140 |
1277 offsetof (struct window, default_gutter), | 1238 offsetof (struct window, default_gutter), |
1278 default_gutter_specs_changed, | 1239 default_gutter_specs_changed, |
1279 0, 0, 1); | 1240 0, 0, 1); |
1280 | 1241 |
1281 DEFVAR_SPECIFIER ("top-gutter", | 1242 DEFVAR_SPECIFIER ("top-gutter", |
1282 &Vgutter[TOP_GUTTER] /* | 1243 &Vgutter[TOP_EDGE] /* |
1283 Specifier for the gutter at the top of the frame. | 1244 Specifier for the gutter at the top of the frame. |
1284 Use `set-specifier' to change this. | 1245 Use `set-specifier' to change this. |
1285 See `default-gutter' for a description of a valid gutter instantiator. | 1246 See `default-gutter' for a description of a valid gutter instantiator. |
1286 */ ); | 1247 */ ); |
1287 Vgutter[TOP_GUTTER] = Fmake_specifier (Qgutter); | 1248 Vgutter[TOP_EDGE] = Fmake_specifier (Qgutter); |
1288 set_specifier_caching (Vgutter[TOP_GUTTER], | 1249 set_specifier_caching (Vgutter[TOP_EDGE], |
1289 offsetof (struct window, gutter[TOP_GUTTER]), | 1250 offsetof (struct window, gutter[TOP_EDGE]), |
1290 top_gutter_specs_changed, | 1251 top_gutter_specs_changed, |
1291 0, 0, 1); | 1252 0, 0, 1); |
1292 | 1253 |
1293 DEFVAR_SPECIFIER ("bottom-gutter", | 1254 DEFVAR_SPECIFIER ("bottom-gutter", |
1294 &Vgutter[BOTTOM_GUTTER] /* | 1255 &Vgutter[BOTTOM_EDGE] /* |
1295 Specifier for the gutter at the bottom of the frame. | 1256 Specifier for the gutter at the bottom of the frame. |
1296 Use `set-specifier' to change this. | 1257 Use `set-specifier' to change this. |
1297 See `default-gutter' for a description of a valid gutter instantiator. | 1258 See `default-gutter' for a description of a valid gutter instantiator. |
1298 | 1259 |
1299 Note that, unless the `default-gutter-position' is `bottom', by | 1260 Note that, unless the `default-gutter-position' is `bottom', by |
1300 default the height of the bottom gutter (controlled by | 1261 default the height of the bottom gutter (controlled by |
1301 `bottom-gutter-height') is 0; thus, a bottom gutter will not be | 1262 `bottom-gutter-height') is 0; thus, a bottom gutter will not be |
1302 displayed even if you provide a value for `bottom-gutter'. | 1263 displayed even if you provide a value for `bottom-gutter'. |
1303 */ ); | 1264 */ ); |
1304 Vgutter[BOTTOM_GUTTER] = Fmake_specifier (Qgutter); | 1265 Vgutter[BOTTOM_EDGE] = Fmake_specifier (Qgutter); |
1305 set_specifier_caching (Vgutter[BOTTOM_GUTTER], | 1266 set_specifier_caching (Vgutter[BOTTOM_EDGE], |
1306 offsetof (struct window, gutter[BOTTOM_GUTTER]), | 1267 offsetof (struct window, gutter[BOTTOM_EDGE]), |
1307 bottom_gutter_specs_changed, | 1268 bottom_gutter_specs_changed, |
1308 0, 0, 1); | 1269 0, 0, 1); |
1309 | 1270 |
1310 DEFVAR_SPECIFIER ("left-gutter", | 1271 DEFVAR_SPECIFIER ("left-gutter", |
1311 &Vgutter[LEFT_GUTTER] /* | 1272 &Vgutter[LEFT_EDGE] /* |
1312 Specifier for the gutter at the left edge of the frame. | 1273 Specifier for the gutter at the left edge of the frame. |
1313 Use `set-specifier' to change this. | 1274 Use `set-specifier' to change this. |
1314 See `default-gutter' for a description of a valid gutter instantiator. | 1275 See `default-gutter' for a description of a valid gutter instantiator. |
1315 | 1276 |
1316 Note that, unless the `default-gutter-position' is `left', by | 1277 Note that, unless the `default-gutter-position' is `left', by |
1317 default the height of the left gutter (controlled by | 1278 default the height of the left gutter (controlled by |
1318 `left-gutter-width') is 0; thus, a left gutter will not be | 1279 `left-gutter-width') is 0; thus, a left gutter will not be |
1319 displayed even if you provide a value for `left-gutter'. | 1280 displayed even if you provide a value for `left-gutter'. |
1320 */ ); | 1281 */ ); |
1321 Vgutter[LEFT_GUTTER] = Fmake_specifier (Qgutter); | 1282 Vgutter[LEFT_EDGE] = Fmake_specifier (Qgutter); |
1322 set_specifier_caching (Vgutter[LEFT_GUTTER], | 1283 set_specifier_caching (Vgutter[LEFT_EDGE], |
1323 offsetof (struct window, gutter[LEFT_GUTTER]), | 1284 offsetof (struct window, gutter[LEFT_EDGE]), |
1324 left_gutter_specs_changed, | 1285 left_gutter_specs_changed, |
1325 0, 0, 1); | 1286 0, 0, 1); |
1326 | 1287 |
1327 DEFVAR_SPECIFIER ("right-gutter", | 1288 DEFVAR_SPECIFIER ("right-gutter", |
1328 &Vgutter[RIGHT_GUTTER] /* | 1289 &Vgutter[RIGHT_EDGE] /* |
1329 Specifier for the gutter at the right edge of the frame. | 1290 Specifier for the gutter at the right edge of the frame. |
1330 Use `set-specifier' to change this. | 1291 Use `set-specifier' to change this. |
1331 See `default-gutter' for a description of a valid gutter instantiator. | 1292 See `default-gutter' for a description of a valid gutter instantiator. |
1332 | 1293 |
1333 Note that, unless the `default-gutter-position' is `right', by | 1294 Note that, unless the `default-gutter-position' is `right', by |
1334 default the height of the right gutter (controlled by | 1295 default the height of the right gutter (controlled by |
1335 `right-gutter-width') is 0; thus, a right gutter will not be | 1296 `right-gutter-width') is 0; thus, a right gutter will not be |
1336 displayed even if you provide a value for `right-gutter'. | 1297 displayed even if you provide a value for `right-gutter'. |
1337 */ ); | 1298 */ ); |
1338 Vgutter[RIGHT_GUTTER] = Fmake_specifier (Qgutter); | 1299 Vgutter[RIGHT_EDGE] = Fmake_specifier (Qgutter); |
1339 set_specifier_caching (Vgutter[RIGHT_GUTTER], | 1300 set_specifier_caching (Vgutter[RIGHT_EDGE], |
1340 offsetof (struct window, gutter[RIGHT_GUTTER]), | 1301 offsetof (struct window, gutter[RIGHT_EDGE]), |
1341 right_gutter_specs_changed, | 1302 right_gutter_specs_changed, |
1342 0, 0, 1); | 1303 0, 0, 1); |
1343 | 1304 |
1344 /* initially, top inherits from default; this can be | 1305 /* initially, top inherits from default; this can be |
1345 changed with `set-default-gutter-position'. */ | 1306 changed with `set-default-gutter-position'. */ |
1346 fb = list1 (Fcons (Qnil, Qnil)); | 1307 fb = list1 (Fcons (Qnil, Qnil)); |
1347 set_specifier_fallback (Vdefault_gutter, fb); | 1308 set_specifier_fallback (Vdefault_gutter, fb); |
1348 set_specifier_fallback (Vgutter[TOP_GUTTER], Vdefault_gutter); | 1309 set_specifier_fallback (Vgutter[TOP_EDGE], Vdefault_gutter); |
1349 set_specifier_fallback (Vgutter[BOTTOM_GUTTER], fb); | 1310 set_specifier_fallback (Vgutter[BOTTOM_EDGE], fb); |
1350 set_specifier_fallback (Vgutter[LEFT_GUTTER], fb); | 1311 set_specifier_fallback (Vgutter[LEFT_EDGE], fb); |
1351 set_specifier_fallback (Vgutter[RIGHT_GUTTER], fb); | 1312 set_specifier_fallback (Vgutter[RIGHT_EDGE], fb); |
1352 | 1313 |
1353 DEFVAR_SPECIFIER ("default-gutter-height", &Vdefault_gutter_height /* | 1314 DEFVAR_SPECIFIER ("default-gutter-height", &Vdefault_gutter_height /* |
1354 *Height of the default gutter, if it's oriented horizontally. | 1315 *Height of the default gutter, if it's oriented horizontally. |
1355 This is a specifier; use `set-specifier' to change it. | 1316 This is a specifier; use `set-specifier' to change it. |
1356 | 1317 |
1392 offsetof (struct window, default_gutter_width), | 1353 offsetof (struct window, default_gutter_width), |
1393 default_gutter_size_changed_in_window, | 1354 default_gutter_size_changed_in_window, |
1394 0, 0, 1); | 1355 0, 0, 1); |
1395 | 1356 |
1396 DEFVAR_SPECIFIER ("top-gutter-height", | 1357 DEFVAR_SPECIFIER ("top-gutter-height", |
1397 &Vgutter_size[TOP_GUTTER] /* | 1358 &Vgutter_size[TOP_EDGE] /* |
1398 *Height of the top gutter. | 1359 *Height of the top gutter. |
1399 This is a specifier; use `set-specifier' to change it. | 1360 This is a specifier; use `set-specifier' to change it. |
1400 | 1361 |
1401 See `default-gutter-height' for more information. | 1362 See `default-gutter-height' for more information. |
1402 */ ); | 1363 */ ); |
1403 Vgutter_size[TOP_GUTTER] = Fmake_specifier (Qgutter_size); | 1364 Vgutter_size[TOP_EDGE] = Fmake_specifier (Qgutter_size); |
1404 set_specifier_caching (Vgutter_size[TOP_GUTTER], | 1365 set_specifier_caching (Vgutter_size[TOP_EDGE], |
1405 offsetof (struct window, gutter_size[TOP_GUTTER]), | 1366 offsetof (struct window, gutter_size[TOP_EDGE]), |
1406 gutter_geometry_changed_in_window, 0, 0, 1); | 1367 gutter_geometry_changed_in_window, 0, 0, 1); |
1407 | 1368 |
1408 DEFVAR_SPECIFIER ("bottom-gutter-height", | 1369 DEFVAR_SPECIFIER ("bottom-gutter-height", |
1409 &Vgutter_size[BOTTOM_GUTTER] /* | 1370 &Vgutter_size[BOTTOM_EDGE] /* |
1410 *Height of the bottom gutter. | 1371 *Height of the bottom gutter. |
1411 This is a specifier; use `set-specifier' to change it. | 1372 This is a specifier; use `set-specifier' to change it. |
1412 | 1373 |
1413 See `default-gutter-height' for more information. | 1374 See `default-gutter-height' for more information. |
1414 */ ); | 1375 */ ); |
1415 Vgutter_size[BOTTOM_GUTTER] = Fmake_specifier (Qgutter_size); | 1376 Vgutter_size[BOTTOM_EDGE] = Fmake_specifier (Qgutter_size); |
1416 set_specifier_caching (Vgutter_size[BOTTOM_GUTTER], | 1377 set_specifier_caching (Vgutter_size[BOTTOM_EDGE], |
1417 offsetof (struct window, gutter_size[BOTTOM_GUTTER]), | 1378 offsetof (struct window, gutter_size[BOTTOM_EDGE]), |
1418 gutter_geometry_changed_in_window, 0, 0, 1); | 1379 gutter_geometry_changed_in_window, 0, 0, 1); |
1419 | 1380 |
1420 DEFVAR_SPECIFIER ("left-gutter-width", | 1381 DEFVAR_SPECIFIER ("left-gutter-width", |
1421 &Vgutter_size[LEFT_GUTTER] /* | 1382 &Vgutter_size[LEFT_EDGE] /* |
1422 *Width of left gutter. | 1383 *Width of left gutter. |
1423 This is a specifier; use `set-specifier' to change it. | 1384 This is a specifier; use `set-specifier' to change it. |
1424 | 1385 |
1425 See `default-gutter-height' for more information. | 1386 See `default-gutter-height' for more information. |
1426 */ ); | 1387 */ ); |
1427 Vgutter_size[LEFT_GUTTER] = Fmake_specifier (Qgutter_size); | 1388 Vgutter_size[LEFT_EDGE] = Fmake_specifier (Qgutter_size); |
1428 set_specifier_caching (Vgutter_size[LEFT_GUTTER], | 1389 set_specifier_caching (Vgutter_size[LEFT_EDGE], |
1429 offsetof (struct window, gutter_size[LEFT_GUTTER]), | 1390 offsetof (struct window, gutter_size[LEFT_EDGE]), |
1430 gutter_geometry_changed_in_window, 0, 0, 1); | 1391 gutter_geometry_changed_in_window, 0, 0, 1); |
1431 | 1392 |
1432 DEFVAR_SPECIFIER ("right-gutter-width", | 1393 DEFVAR_SPECIFIER ("right-gutter-width", |
1433 &Vgutter_size[RIGHT_GUTTER] /* | 1394 &Vgutter_size[RIGHT_EDGE] /* |
1434 *Width of right gutter. | 1395 *Width of right gutter. |
1435 This is a specifier; use `set-specifier' to change it. | 1396 This is a specifier; use `set-specifier' to change it. |
1436 | 1397 |
1437 See `default-gutter-height' for more information. | 1398 See `default-gutter-height' for more information. |
1438 */ ); | 1399 */ ); |
1439 Vgutter_size[RIGHT_GUTTER] = Fmake_specifier (Qgutter_size); | 1400 Vgutter_size[RIGHT_EDGE] = Fmake_specifier (Qgutter_size); |
1440 set_specifier_caching (Vgutter_size[RIGHT_GUTTER], | 1401 set_specifier_caching (Vgutter_size[RIGHT_EDGE], |
1441 offsetof (struct window, gutter_size[RIGHT_GUTTER]), | 1402 offsetof (struct window, gutter_size[RIGHT_EDGE]), |
1442 gutter_geometry_changed_in_window, 0, 0, 1); | 1403 gutter_geometry_changed_in_window, 0, 0, 1); |
1443 | 1404 |
1444 fb = Qnil; | 1405 fb = Qnil; |
1445 #ifdef HAVE_TTY | 1406 #ifdef HAVE_TTY |
1446 fb = Fcons (Fcons (list1 (Qtty), Qautodetect), fb); | 1407 fb = Fcons (Fcons (list1 (Qtty), Qautodetect), fb); |
1473 fb = Fcons (Fcons (list1 (Qmswindows), Qautodetect), fb); | 1434 fb = Fcons (Fcons (list1 (Qmswindows), Qautodetect), fb); |
1474 #endif | 1435 #endif |
1475 if (!NILP (fb)) | 1436 if (!NILP (fb)) |
1476 set_specifier_fallback (Vdefault_gutter_width, fb); | 1437 set_specifier_fallback (Vdefault_gutter_width, fb); |
1477 | 1438 |
1478 set_specifier_fallback (Vgutter_size[TOP_GUTTER], Vdefault_gutter_height); | 1439 set_specifier_fallback (Vgutter_size[TOP_EDGE], Vdefault_gutter_height); |
1479 fb = list1 (Fcons (Qnil, Qzero)); | 1440 fb = list1 (Fcons (Qnil, Qzero)); |
1480 set_specifier_fallback (Vgutter_size[BOTTOM_GUTTER], fb); | 1441 set_specifier_fallback (Vgutter_size[BOTTOM_EDGE], fb); |
1481 set_specifier_fallback (Vgutter_size[LEFT_GUTTER], fb); | 1442 set_specifier_fallback (Vgutter_size[LEFT_EDGE], fb); |
1482 set_specifier_fallback (Vgutter_size[RIGHT_GUTTER], fb); | 1443 set_specifier_fallback (Vgutter_size[RIGHT_EDGE], fb); |
1483 | 1444 |
1484 DEFVAR_SPECIFIER ("default-gutter-border-width", | 1445 DEFVAR_SPECIFIER ("default-gutter-border-width", |
1485 &Vdefault_gutter_border_width /* | 1446 &Vdefault_gutter_border_width /* |
1486 *Width of the border around the default gutter. | 1447 *Width of the border around the default gutter. |
1487 This is a specifier; use `set-specifier' to change it. | 1448 This is a specifier; use `set-specifier' to change it. |
1500 offsetof (struct window, default_gutter_border_width), | 1461 offsetof (struct window, default_gutter_border_width), |
1501 default_gutter_border_width_changed_in_window, | 1462 default_gutter_border_width_changed_in_window, |
1502 0, 0, 0); | 1463 0, 0, 0); |
1503 | 1464 |
1504 DEFVAR_SPECIFIER ("top-gutter-border-width", | 1465 DEFVAR_SPECIFIER ("top-gutter-border-width", |
1505 &Vgutter_border_width[TOP_GUTTER] /* | 1466 &Vgutter_border_width[TOP_EDGE] /* |
1506 *Border width of the top gutter. | 1467 *Border width of the top gutter. |
1507 This is a specifier; use `set-specifier' to change it. | 1468 This is a specifier; use `set-specifier' to change it. |
1508 | 1469 |
1509 See `default-gutter-height' for more information. | 1470 See `default-gutter-height' for more information. |
1510 */ ); | 1471 */ ); |
1511 Vgutter_border_width[TOP_GUTTER] = Fmake_specifier (Qnatnum); | 1472 Vgutter_border_width[TOP_EDGE] = Fmake_specifier (Qnatnum); |
1512 set_specifier_caching (Vgutter_border_width[TOP_GUTTER], | 1473 set_specifier_caching (Vgutter_border_width[TOP_EDGE], |
1513 offsetof (struct window, | 1474 offsetof (struct window, |
1514 gutter_border_width[TOP_GUTTER]), | 1475 gutter_border_width[TOP_EDGE]), |
1515 gutter_geometry_changed_in_window, 0, 0, 0); | 1476 gutter_geometry_changed_in_window, 0, 0, 0); |
1516 | 1477 |
1517 DEFVAR_SPECIFIER ("bottom-gutter-border-width", | 1478 DEFVAR_SPECIFIER ("bottom-gutter-border-width", |
1518 &Vgutter_border_width[BOTTOM_GUTTER] /* | 1479 &Vgutter_border_width[BOTTOM_EDGE] /* |
1519 *Border width of the bottom gutter. | 1480 *Border width of the bottom gutter. |
1520 This is a specifier; use `set-specifier' to change it. | 1481 This is a specifier; use `set-specifier' to change it. |
1521 | 1482 |
1522 See `default-gutter-height' for more information. | 1483 See `default-gutter-height' for more information. |
1523 */ ); | 1484 */ ); |
1524 Vgutter_border_width[BOTTOM_GUTTER] = Fmake_specifier (Qnatnum); | 1485 Vgutter_border_width[BOTTOM_EDGE] = Fmake_specifier (Qnatnum); |
1525 set_specifier_caching (Vgutter_border_width[BOTTOM_GUTTER], | 1486 set_specifier_caching (Vgutter_border_width[BOTTOM_EDGE], |
1526 offsetof (struct window, | 1487 offsetof (struct window, |
1527 gutter_border_width[BOTTOM_GUTTER]), | 1488 gutter_border_width[BOTTOM_EDGE]), |
1528 gutter_geometry_changed_in_window, 0, 0, 0); | 1489 gutter_geometry_changed_in_window, 0, 0, 0); |
1529 | 1490 |
1530 DEFVAR_SPECIFIER ("left-gutter-border-width", | 1491 DEFVAR_SPECIFIER ("left-gutter-border-width", |
1531 &Vgutter_border_width[LEFT_GUTTER] /* | 1492 &Vgutter_border_width[LEFT_EDGE] /* |
1532 *Border width of left gutter. | 1493 *Border width of left gutter. |
1533 This is a specifier; use `set-specifier' to change it. | 1494 This is a specifier; use `set-specifier' to change it. |
1534 | 1495 |
1535 See `default-gutter-height' for more information. | 1496 See `default-gutter-height' for more information. |
1536 */ ); | 1497 */ ); |
1537 Vgutter_border_width[LEFT_GUTTER] = Fmake_specifier (Qnatnum); | 1498 Vgutter_border_width[LEFT_EDGE] = Fmake_specifier (Qnatnum); |
1538 set_specifier_caching (Vgutter_border_width[LEFT_GUTTER], | 1499 set_specifier_caching (Vgutter_border_width[LEFT_EDGE], |
1539 offsetof (struct window, | 1500 offsetof (struct window, |
1540 gutter_border_width[LEFT_GUTTER]), | 1501 gutter_border_width[LEFT_EDGE]), |
1541 gutter_geometry_changed_in_window, 0, 0, 0); | 1502 gutter_geometry_changed_in_window, 0, 0, 0); |
1542 | 1503 |
1543 DEFVAR_SPECIFIER ("right-gutter-border-width", | 1504 DEFVAR_SPECIFIER ("right-gutter-border-width", |
1544 &Vgutter_border_width[RIGHT_GUTTER] /* | 1505 &Vgutter_border_width[RIGHT_EDGE] /* |
1545 *Border width of right gutter. | 1506 *Border width of right gutter. |
1546 This is a specifier; use `set-specifier' to change it. | 1507 This is a specifier; use `set-specifier' to change it. |
1547 | 1508 |
1548 See `default-gutter-height' for more information. | 1509 See `default-gutter-height' for more information. |
1549 */ ); | 1510 */ ); |
1550 Vgutter_border_width[RIGHT_GUTTER] = Fmake_specifier (Qnatnum); | 1511 Vgutter_border_width[RIGHT_EDGE] = Fmake_specifier (Qnatnum); |
1551 set_specifier_caching (Vgutter_border_width[RIGHT_GUTTER], | 1512 set_specifier_caching (Vgutter_border_width[RIGHT_EDGE], |
1552 offsetof (struct window, | 1513 offsetof (struct window, |
1553 gutter_border_width[RIGHT_GUTTER]), | 1514 gutter_border_width[RIGHT_EDGE]), |
1554 gutter_geometry_changed_in_window, 0, 0, 0); | 1515 gutter_geometry_changed_in_window, 0, 0, 0); |
1555 | 1516 |
1556 fb = Qnil; | 1517 fb = Qnil; |
1557 #ifdef HAVE_TTY | 1518 #ifdef HAVE_TTY |
1558 fb = Fcons (Fcons (list1 (Qtty), Qzero), fb); | 1519 fb = Fcons (Fcons (list1 (Qtty), Qzero), fb); |
1565 fb = Fcons (Fcons (list1 (Qmswindows), make_int (DEFAULT_GUTTER_BORDER_WIDTH)), fb); | 1526 fb = Fcons (Fcons (list1 (Qmswindows), make_int (DEFAULT_GUTTER_BORDER_WIDTH)), fb); |
1566 #endif | 1527 #endif |
1567 if (!NILP (fb)) | 1528 if (!NILP (fb)) |
1568 set_specifier_fallback (Vdefault_gutter_border_width, fb); | 1529 set_specifier_fallback (Vdefault_gutter_border_width, fb); |
1569 | 1530 |
1570 set_specifier_fallback (Vgutter_border_width[TOP_GUTTER], Vdefault_gutter_border_width); | 1531 set_specifier_fallback (Vgutter_border_width[TOP_EDGE], Vdefault_gutter_border_width); |
1571 fb = list1 (Fcons (Qnil, Qzero)); | 1532 fb = list1 (Fcons (Qnil, Qzero)); |
1572 set_specifier_fallback (Vgutter_border_width[BOTTOM_GUTTER], fb); | 1533 set_specifier_fallback (Vgutter_border_width[BOTTOM_EDGE], fb); |
1573 set_specifier_fallback (Vgutter_border_width[LEFT_GUTTER], fb); | 1534 set_specifier_fallback (Vgutter_border_width[LEFT_EDGE], fb); |
1574 set_specifier_fallback (Vgutter_border_width[RIGHT_GUTTER], fb); | 1535 set_specifier_fallback (Vgutter_border_width[RIGHT_EDGE], fb); |
1575 | 1536 |
1576 DEFVAR_SPECIFIER ("default-gutter-visible-p", &Vdefault_gutter_visible_p /* | 1537 DEFVAR_SPECIFIER ("default-gutter-visible-p", &Vdefault_gutter_visible_p /* |
1577 *Whether the default gutter is visible. | 1538 *Whether the default gutter is visible. |
1578 This is a specifier; use `set-specifier' to change it. | 1539 This is a specifier; use `set-specifier' to change it. |
1579 | 1540 |
1594 default_gutter_visible_p), | 1555 default_gutter_visible_p), |
1595 default_gutter_visible_p_changed_in_window, | 1556 default_gutter_visible_p_changed_in_window, |
1596 0, 0, 0); | 1557 0, 0, 0); |
1597 | 1558 |
1598 DEFVAR_SPECIFIER ("top-gutter-visible-p", | 1559 DEFVAR_SPECIFIER ("top-gutter-visible-p", |
1599 &Vgutter_visible_p[TOP_GUTTER] /* | 1560 &Vgutter_visible_p[TOP_EDGE] /* |
1600 *Whether the top gutter is visible. | 1561 *Whether the top gutter is visible. |
1601 This is a specifier; use `set-specifier' to change it. | 1562 This is a specifier; use `set-specifier' to change it. |
1602 | 1563 |
1603 See `default-gutter-visible-p' for more information. | 1564 See `default-gutter-visible-p' for more information. |
1604 */ ); | 1565 */ ); |
1605 Vgutter_visible_p[TOP_GUTTER] = Fmake_specifier (Qgutter_visible); | 1566 Vgutter_visible_p[TOP_EDGE] = Fmake_specifier (Qgutter_visible); |
1606 set_specifier_caching (Vgutter_visible_p[TOP_GUTTER], | 1567 set_specifier_caching (Vgutter_visible_p[TOP_EDGE], |
1607 offsetof (struct window, | 1568 offsetof (struct window, |
1608 gutter_visible_p[TOP_GUTTER]), | 1569 gutter_visible_p[TOP_EDGE]), |
1609 top_gutter_specs_changed, 0, 0, 0); | 1570 top_gutter_specs_changed, 0, 0, 0); |
1610 | 1571 |
1611 DEFVAR_SPECIFIER ("bottom-gutter-visible-p", | 1572 DEFVAR_SPECIFIER ("bottom-gutter-visible-p", |
1612 &Vgutter_visible_p[BOTTOM_GUTTER] /* | 1573 &Vgutter_visible_p[BOTTOM_EDGE] /* |
1613 *Whether the bottom gutter is visible. | 1574 *Whether the bottom gutter is visible. |
1614 This is a specifier; use `set-specifier' to change it. | 1575 This is a specifier; use `set-specifier' to change it. |
1615 | 1576 |
1616 See `default-gutter-visible-p' for more information. | 1577 See `default-gutter-visible-p' for more information. |
1617 */ ); | 1578 */ ); |
1618 Vgutter_visible_p[BOTTOM_GUTTER] = Fmake_specifier (Qgutter_visible); | 1579 Vgutter_visible_p[BOTTOM_EDGE] = Fmake_specifier (Qgutter_visible); |
1619 set_specifier_caching (Vgutter_visible_p[BOTTOM_GUTTER], | 1580 set_specifier_caching (Vgutter_visible_p[BOTTOM_EDGE], |
1620 offsetof (struct window, | 1581 offsetof (struct window, |
1621 gutter_visible_p[BOTTOM_GUTTER]), | 1582 gutter_visible_p[BOTTOM_EDGE]), |
1622 bottom_gutter_specs_changed, 0, 0, 0); | 1583 bottom_gutter_specs_changed, 0, 0, 0); |
1623 | 1584 |
1624 DEFVAR_SPECIFIER ("left-gutter-visible-p", | 1585 DEFVAR_SPECIFIER ("left-gutter-visible-p", |
1625 &Vgutter_visible_p[LEFT_GUTTER] /* | 1586 &Vgutter_visible_p[LEFT_EDGE] /* |
1626 *Whether the left gutter is visible. | 1587 *Whether the left gutter is visible. |
1627 This is a specifier; use `set-specifier' to change it. | 1588 This is a specifier; use `set-specifier' to change it. |
1628 | 1589 |
1629 See `default-gutter-visible-p' for more information. | 1590 See `default-gutter-visible-p' for more information. |
1630 */ ); | 1591 */ ); |
1631 Vgutter_visible_p[LEFT_GUTTER] = Fmake_specifier (Qgutter_visible); | 1592 Vgutter_visible_p[LEFT_EDGE] = Fmake_specifier (Qgutter_visible); |
1632 set_specifier_caching (Vgutter_visible_p[LEFT_GUTTER], | 1593 set_specifier_caching (Vgutter_visible_p[LEFT_EDGE], |
1633 offsetof (struct window, | 1594 offsetof (struct window, |
1634 gutter_visible_p[LEFT_GUTTER]), | 1595 gutter_visible_p[LEFT_EDGE]), |
1635 left_gutter_specs_changed, 0, 0, 0); | 1596 left_gutter_specs_changed, 0, 0, 0); |
1636 | 1597 |
1637 DEFVAR_SPECIFIER ("right-gutter-visible-p", | 1598 DEFVAR_SPECIFIER ("right-gutter-visible-p", |
1638 &Vgutter_visible_p[RIGHT_GUTTER] /* | 1599 &Vgutter_visible_p[RIGHT_EDGE] /* |
1639 *Whether the right gutter is visible. | 1600 *Whether the right gutter is visible. |
1640 This is a specifier; use `set-specifier' to change it. | 1601 This is a specifier; use `set-specifier' to change it. |
1641 | 1602 |
1642 See `default-gutter-visible-p' for more information. | 1603 See `default-gutter-visible-p' for more information. |
1643 */ ); | 1604 */ ); |
1644 Vgutter_visible_p[RIGHT_GUTTER] = Fmake_specifier (Qgutter_visible); | 1605 Vgutter_visible_p[RIGHT_EDGE] = Fmake_specifier (Qgutter_visible); |
1645 set_specifier_caching (Vgutter_visible_p[RIGHT_GUTTER], | 1606 set_specifier_caching (Vgutter_visible_p[RIGHT_EDGE], |
1646 offsetof (struct window, | 1607 offsetof (struct window, |
1647 gutter_visible_p[RIGHT_GUTTER]), | 1608 gutter_visible_p[RIGHT_EDGE]), |
1648 right_gutter_specs_changed, 0, 0, 0); | 1609 right_gutter_specs_changed, 0, 0, 0); |
1649 | 1610 |
1650 /* initially, top inherits from default; this can be | 1611 /* initially, top inherits from default; this can be |
1651 changed with `set-default-gutter-position'. */ | 1612 changed with `set-default-gutter-position'. */ |
1652 fb = list1 (Fcons (Qnil, Qt)); | 1613 fb = list1 (Fcons (Qnil, Qt)); |
1653 set_specifier_fallback (Vdefault_gutter_visible_p, fb); | 1614 set_specifier_fallback (Vdefault_gutter_visible_p, fb); |
1654 set_specifier_fallback (Vgutter_visible_p[TOP_GUTTER], | 1615 set_specifier_fallback (Vgutter_visible_p[TOP_EDGE], |
1655 Vdefault_gutter_visible_p); | 1616 Vdefault_gutter_visible_p); |
1656 set_specifier_fallback (Vgutter_visible_p[BOTTOM_GUTTER], fb); | 1617 set_specifier_fallback (Vgutter_visible_p[BOTTOM_EDGE], fb); |
1657 set_specifier_fallback (Vgutter_visible_p[LEFT_GUTTER], fb); | 1618 set_specifier_fallback (Vgutter_visible_p[LEFT_EDGE], fb); |
1658 set_specifier_fallback (Vgutter_visible_p[RIGHT_GUTTER], fb); | 1619 set_specifier_fallback (Vgutter_visible_p[RIGHT_EDGE], fb); |
1659 } | 1620 } |