Mercurial > hg > xemacs-beta
comparison src/toolbar.c @ 5128:7be849cb8828 ben-lisp-object
merge
author | Ben Wing <ben@xemacs.org> |
---|---|
date | Sun, 07 Mar 2010 02:09:59 -0600 |
parents | a9c41067dd88 0ca81354c4c7 |
children | 308d34e9f07d |
comparison
equal
deleted
inserted
replaced
5127:a9c41067dd88 | 5128:7be849cb8828 |
---|---|
35 #include "glyphs.h" | 35 #include "glyphs.h" |
36 #include "redisplay.h" | 36 #include "redisplay.h" |
37 #include "toolbar.h" | 37 #include "toolbar.h" |
38 #include "window.h" | 38 #include "window.h" |
39 | 39 |
40 Lisp_Object Vtoolbar[4]; | 40 Lisp_Object Vtoolbar[NUM_EDGES]; |
41 Lisp_Object Vtoolbar_size[4]; | 41 Lisp_Object Vtoolbar_size[NUM_EDGES]; |
42 Lisp_Object Vtoolbar_visible_p[4]; | 42 Lisp_Object Vtoolbar_visible_p[NUM_EDGES]; |
43 Lisp_Object Vtoolbar_border_width[4]; | 43 Lisp_Object Vtoolbar_border_width[NUM_EDGES]; |
44 | 44 |
45 Lisp_Object Vdefault_toolbar, Vdefault_toolbar_visible_p; | 45 Lisp_Object Vdefault_toolbar, Vdefault_toolbar_visible_p; |
46 Lisp_Object Vdefault_toolbar_width, Vdefault_toolbar_height; | 46 Lisp_Object Vdefault_toolbar_width, Vdefault_toolbar_height; |
47 Lisp_Object Vdefault_toolbar_border_width; | 47 Lisp_Object Vdefault_toolbar_border_width; |
48 Lisp_Object Vtoolbar_shadow_thickness; | 48 Lisp_Object Vtoolbar_shadow_thickness; |
254 | 254 |
255 return glyph; | 255 return glyph; |
256 } | 256 } |
257 | 257 |
258 | 258 |
259 static enum toolbar_pos | 259 static enum edge_pos |
260 decode_toolbar_position (Lisp_Object position) | 260 decode_toolbar_position (Lisp_Object position) |
261 { | 261 { |
262 if (EQ (position, Qtop)) return TOP_TOOLBAR; | 262 if (EQ (position, Qtop)) return TOP_EDGE; |
263 if (EQ (position, Qbottom)) return BOTTOM_TOOLBAR; | 263 if (EQ (position, Qbottom)) return BOTTOM_EDGE; |
264 if (EQ (position, Qleft)) return LEFT_TOOLBAR; | 264 if (EQ (position, Qleft)) return LEFT_EDGE; |
265 if (EQ (position, Qright)) return RIGHT_TOOLBAR; | 265 if (EQ (position, Qright)) return RIGHT_EDGE; |
266 invalid_constant ("Invalid toolbar position", position); | 266 invalid_constant ("Invalid toolbar position", position); |
267 | 267 |
268 RETURN_NOT_REACHED (TOP_TOOLBAR); | 268 RETURN_NOT_REACHED (TOP_EDGE); |
269 } | 269 } |
270 | 270 |
271 DEFUN ("set-default-toolbar-position", Fset_default_toolbar_position, 1, 1, 0, /* | 271 DEFUN ("set-default-toolbar-position", Fset_default_toolbar_position, 1, 1, 0, /* |
272 Set the position that the `default-toolbar' will be displayed at. | 272 Set the position that the `default-toolbar' will be displayed at. |
273 Valid positions are `top', `bottom', `left' and `right'. | 273 Valid positions are `top', `bottom', `left' and `right'. |
274 See `default-toolbar-position'. | 274 See `default-toolbar-position'. |
275 */ | 275 */ |
276 (position)) | 276 (position)) |
277 { | 277 { |
278 enum toolbar_pos cur = decode_toolbar_position (Vdefault_toolbar_position); | 278 enum edge_pos cur = decode_toolbar_position (Vdefault_toolbar_position); |
279 enum toolbar_pos new_ = decode_toolbar_position (position); | 279 enum edge_pos new_ = decode_toolbar_position (position); |
280 | 280 |
281 if (cur != new_) | 281 if (cur != new_) |
282 { | 282 { |
283 /* The following calls will automatically cause the dirty | 283 /* The following calls will automatically cause the dirty |
284 flags to be set; we delay frame size changes to avoid | 284 flags to be set; we delay frame size changes to avoid |
286 int depth = begin_hold_frame_size_changes (); | 286 int depth = begin_hold_frame_size_changes (); |
287 set_specifier_fallback (Vtoolbar[cur], list1 (Fcons (Qnil, Qnil))); | 287 set_specifier_fallback (Vtoolbar[cur], list1 (Fcons (Qnil, Qnil))); |
288 set_specifier_fallback (Vtoolbar[new_], Vdefault_toolbar); | 288 set_specifier_fallback (Vtoolbar[new_], Vdefault_toolbar); |
289 set_specifier_fallback (Vtoolbar_size[cur], list1 (Fcons (Qnil, Qzero))); | 289 set_specifier_fallback (Vtoolbar_size[cur], list1 (Fcons (Qnil, Qzero))); |
290 set_specifier_fallback (Vtoolbar_size[new_], | 290 set_specifier_fallback (Vtoolbar_size[new_], |
291 new_ == TOP_TOOLBAR || new_ == BOTTOM_TOOLBAR | 291 new_ == TOP_EDGE || new_ == BOTTOM_EDGE |
292 ? Vdefault_toolbar_height | 292 ? Vdefault_toolbar_height |
293 : Vdefault_toolbar_width); | 293 : Vdefault_toolbar_width); |
294 set_specifier_fallback (Vtoolbar_border_width[cur], | 294 set_specifier_fallback (Vtoolbar_border_width[cur], |
295 list1 (Fcons (Qnil, Qzero))); | 295 list1 (Fcons (Qnil, Qzero))); |
296 set_specifier_fallback (Vtoolbar_border_width[new_], | 296 set_specifier_fallback (Vtoolbar_border_width[new_], |
592 UNGCPRO; | 592 UNGCPRO; |
593 return retval; | 593 return retval; |
594 } | 594 } |
595 | 595 |
596 void | 596 void |
597 mark_frame_toolbar_buttons_dirty (struct frame *f, enum toolbar_pos pos) | 597 mark_frame_toolbar_buttons_dirty (struct frame *f, enum edge_pos pos) |
598 { | 598 { |
599 Lisp_Object button = FRAME_TOOLBAR_BUTTONS (f, pos); | 599 Lisp_Object button = FRAME_TOOLBAR_BUTTONS (f, pos); |
600 | 600 |
601 while (!NILP (button)) | 601 while (!NILP (button)) |
602 { | 602 { |
606 } | 606 } |
607 return; | 607 return; |
608 } | 608 } |
609 | 609 |
610 static Lisp_Object | 610 static Lisp_Object |
611 compute_frame_toolbar_buttons (struct frame *f, enum toolbar_pos pos, | 611 compute_frame_toolbar_buttons (struct frame *f, enum edge_pos pos, |
612 Lisp_Object toolbar) | 612 Lisp_Object toolbar) |
613 { | 613 { |
614 Lisp_Object buttons, prev_button, first_button; | 614 Lisp_Object buttons, prev_button, first_button; |
615 Lisp_Object orig_toolbar = toolbar; | 615 Lisp_Object orig_toolbar = toolbar; |
616 int pushright_seen = 0; | 616 int pushright_seen = 0; |
715 UNGCPRO; | 715 UNGCPRO; |
716 return first_button; | 716 return first_button; |
717 } | 717 } |
718 | 718 |
719 static void | 719 static void |
720 set_frame_toolbar (struct frame *f, enum toolbar_pos pos) | 720 set_frame_toolbar (struct frame *f, enum edge_pos pos) |
721 { | 721 { |
722 struct window *w = XWINDOW (FRAME_LAST_NONMINIBUF_WINDOW (f)); | 722 struct window *w = XWINDOW (FRAME_LAST_NONMINIBUF_WINDOW (f)); |
723 Lisp_Object toolbar = w->toolbar[pos]; | 723 Lisp_Object toolbar = w->toolbar[pos]; |
724 f->toolbar_buttons[pos] = (FRAME_REAL_TOOLBAR_VISIBLE (f, pos) | 724 f->toolbar_buttons[pos] = (FRAME_REAL_TOOLBAR_VISIBLE (f, pos) |
725 ? compute_frame_toolbar_buttons (f, pos, toolbar) | 725 ? compute_frame_toolbar_buttons (f, pos, toolbar) |
727 } | 727 } |
728 | 728 |
729 static void | 729 static void |
730 compute_frame_toolbars_data (struct frame *f) | 730 compute_frame_toolbars_data (struct frame *f) |
731 { | 731 { |
732 set_frame_toolbar (f, TOP_TOOLBAR); | 732 set_frame_toolbar (f, TOP_EDGE); |
733 set_frame_toolbar (f, BOTTOM_TOOLBAR); | 733 set_frame_toolbar (f, BOTTOM_EDGE); |
734 set_frame_toolbar (f, LEFT_TOOLBAR); | 734 set_frame_toolbar (f, LEFT_EDGE); |
735 set_frame_toolbar (f, RIGHT_TOOLBAR); | 735 set_frame_toolbar (f, RIGHT_EDGE); |
736 } | 736 } |
737 | 737 |
738 /* Update the toolbar geometry separately from actually displaying the | 738 /* Update the toolbar geometry separately from actually displaying the |
739 toolbar. This is necessary because both the gutter and the toolbar | 739 toolbar. This is necessary because both the gutter and the toolbar |
740 are competing for redisplay cycles and, unfortunately, gutter | 740 are competing for redisplay cycles and, unfortunately, gutter |
764 necessitate this layout, as it is outside any windows. We | 764 necessitate this layout, as it is outside any windows. We |
765 take care not to change size if toolbar geometry is really | 765 take care not to change size if toolbar geometry is really |
766 unchanged, as it will hose windows whose pixsizes are not | 766 unchanged, as it will hose windows whose pixsizes are not |
767 multiple of character sizes. */ | 767 multiple of character sizes. */ |
768 | 768 |
769 for (pos = 0; pos < 4; pos++) | 769 EDGE_POS_LOOP (pos) |
770 if (FRAME_REAL_TOOLBAR_SIZE (f, pos) | 770 if (FRAME_REAL_TOOLBAR_SIZE (f, pos) |
771 != FRAME_CURRENT_TOOLBAR_SIZE (f, pos)) | 771 != FRAME_CURRENT_TOOLBAR_SIZE (f, pos)) |
772 frame_size_changed = 1; | 772 frame_size_changed = 1; |
773 | 773 |
774 for (pos = 0; pos < 4; pos++) { | 774 EDGE_POS_LOOP (pos) |
775 f->current_toolbar_size[pos] = FRAME_REAL_TOOLBAR_SIZE (f, pos); | 775 { |
776 } | 776 f->current_toolbar_size[pos] = FRAME_REAL_TOOLBAR_SIZE (f, pos); |
777 } | |
777 | 778 |
778 /* Removed the check for the minibuffer here. We handle this | 779 /* Removed the check for the minibuffer here. We handle this |
779 more correctly now by consistently using | 780 more correctly now by consistently using |
780 FRAME_LAST_NONMINIBUF_WINDOW instead of FRAME_SELECTED_WINDOW | 781 FRAME_LAST_NONMINIBUF_WINDOW instead of FRAME_SELECTED_WINDOW |
781 throughout the toolbar code. */ | 782 throughout the toolbar code. */ |
782 compute_frame_toolbars_data (f); | 783 compute_frame_toolbars_data (f); |
784 | |
785 /* #### GEOM! Turning the toolbar on and off repeatedly causes the | |
786 frame to steadily shrink. Basically, turning it on doesn't | |
787 increase the frame size, while turning it off does reduce the | |
788 frame size. The cause has something to do with the combination | |
789 of this maybe questionable code here, plus the fact that toolbars | |
790 are included in the displayable area, and the difference between | |
791 real and theoretical toolbar sizes, and exactly when the various | |
792 computations happen w.r.t. the specifiers or whatever that control | |
793 whether toolbars are visible and hence whether their thickness is | |
794 greater than zero. --ben */ | |
783 | 795 |
784 if (frame_size_changed) | 796 if (frame_size_changed) |
785 { | 797 { |
786 int width, height; | 798 int width, height; |
787 pixel_to_frame_unit_size (f, FRAME_PIXWIDTH (f), FRAME_PIXHEIGHT (f), | 799 pixel_to_frame_unit_size (f, FRAME_PIXWIDTH (f), FRAME_PIXHEIGHT (f), |
835 | 847 |
836 /* We are here as far in frame creation so cached specifiers are | 848 /* We are here as far in frame creation so cached specifiers are |
837 already recomputed, and possibly modified by resource | 849 already recomputed, and possibly modified by resource |
838 initialization. Remember current toolbar geometry so next | 850 initialization. Remember current toolbar geometry so next |
839 redisplay will not needlessly relayout toolbars. */ | 851 redisplay will not needlessly relayout toolbars. */ |
840 for (pos = 0; pos < 4; pos++) | 852 EDGE_POS_LOOP (pos) |
841 f->current_toolbar_size[pos] = FRAME_REAL_TOOLBAR_SIZE (f, pos); | 853 f->current_toolbar_size[pos] = FRAME_REAL_TOOLBAR_SIZE (f, pos); |
842 } | 854 } |
843 } | 855 } |
844 | 856 |
845 void | 857 void |
870 | 882 |
871 MAYBE_FRAMEMETH (f, free_frame_toolbars, (f)); | 883 MAYBE_FRAMEMETH (f, free_frame_toolbars, (f)); |
872 } | 884 } |
873 | 885 |
874 void | 886 void |
875 get_toolbar_coords (struct frame *f, enum toolbar_pos pos, int *x, int *y, | 887 get_toolbar_coords (struct frame *f, enum edge_pos pos, int *x, int *y, |
876 int *width, int *height, int *vert, int for_layout) | 888 int *width, int *height, int *vert, int for_layout) |
877 { | 889 { |
878 int visible_top_toolbar_height, visible_bottom_toolbar_height; | 890 int visible_top_toolbar_height, visible_bottom_toolbar_height; |
879 int adjust = (for_layout ? 1 : 0); | 891 int adjust = (for_layout ? 1 : 0); |
880 | 892 |
894 at the outside edges. However, when we are simply determining | 906 at the outside edges. However, when we are simply determining |
895 toolbar location we don't want to do that. */ | 907 toolbar location we don't want to do that. */ |
896 | 908 |
897 switch (pos) | 909 switch (pos) |
898 { | 910 { |
899 case TOP_TOOLBAR: | 911 case TOP_EDGE: |
900 *x = 1; | 912 *x = 1; |
901 *y = 0; /* #### should be 1 if no menubar */ | 913 *y = 0; /* #### should be 1 if no menubar */ |
902 *width = FRAME_PIXWIDTH (f) - 2; | 914 *width = FRAME_PIXWIDTH (f) - 2; |
903 *height = FRAME_REAL_TOP_TOOLBAR_HEIGHT (f) + | 915 *height = FRAME_REAL_TOP_TOOLBAR_HEIGHT (f) + |
904 2 * FRAME_REAL_TOP_TOOLBAR_BORDER_WIDTH (f) - adjust; | 916 2 * FRAME_REAL_TOP_TOOLBAR_BORDER_WIDTH (f) - adjust; |
905 *vert = 0; | 917 *vert = 0; |
906 break; | 918 break; |
907 case BOTTOM_TOOLBAR: | 919 case BOTTOM_EDGE: |
908 *x = 1; | 920 *x = 1; |
909 *y = FRAME_PIXHEIGHT (f) - FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f) - | 921 *y = FRAME_PIXHEIGHT (f) - FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f) - |
910 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f); | 922 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f); |
911 *width = FRAME_PIXWIDTH (f) - 2; | 923 *width = FRAME_PIXWIDTH (f) - 2; |
912 *height = FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f) + | 924 *height = FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f) + |
913 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f) - adjust; | 925 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f) - adjust; |
914 *vert = 0; | 926 *vert = 0; |
915 break; | 927 break; |
916 case LEFT_TOOLBAR: | 928 case LEFT_EDGE: |
917 *x = 1; | 929 *x = 1; |
918 *y = visible_top_toolbar_height; | 930 *y = visible_top_toolbar_height; |
919 *width = FRAME_REAL_LEFT_TOOLBAR_WIDTH (f) + | 931 *width = FRAME_REAL_LEFT_TOOLBAR_WIDTH (f) + |
920 2 * FRAME_REAL_LEFT_TOOLBAR_BORDER_WIDTH (f) - adjust; | 932 2 * FRAME_REAL_LEFT_TOOLBAR_BORDER_WIDTH (f) - adjust; |
921 *height = (FRAME_PIXHEIGHT (f) - visible_top_toolbar_height - | 933 *height = (FRAME_PIXHEIGHT (f) - visible_top_toolbar_height - |
922 visible_bottom_toolbar_height - 1); | 934 visible_bottom_toolbar_height - 1); |
923 *vert = 1; | 935 *vert = 1; |
924 break; | 936 break; |
925 case RIGHT_TOOLBAR: | 937 case RIGHT_EDGE: |
926 *x = FRAME_PIXWIDTH (f) - FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f) - | 938 *x = FRAME_PIXWIDTH (f) - FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f) - |
927 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f); | 939 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f); |
928 *y = visible_top_toolbar_height; | 940 *y = visible_top_toolbar_height; |
929 *width = FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f) + | 941 *width = FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f) + |
930 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f) - adjust; | 942 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f) - adjust; |
936 ABORT (); | 948 ABORT (); |
937 } | 949 } |
938 } | 950 } |
939 | 951 |
940 #define CHECK_TOOLBAR(pos) do { \ | 952 #define CHECK_TOOLBAR(pos) do { \ |
941 if (FRAME_REAL_##pos##_VISIBLE (f)) \ | 953 if (FRAME_REAL_TOOLBAR_VISIBLE (f, pos)) \ |
942 { \ | 954 { \ |
943 int x, y, width, height, vert; \ | 955 int x, y, width, height, vert; \ |
944 \ | 956 \ |
945 get_toolbar_coords (f, pos, &x, &y, &width, &height, &vert, 0); \ | 957 get_toolbar_coords (f, pos, &x, &y, &width, &height, &vert, 0); \ |
946 if ((x_coord >= x) && (x_coord < (x + width))) \ | 958 if ((x_coord >= x) && (x_coord < (x + width))) \ |
952 } while (0) | 964 } while (0) |
953 | 965 |
954 static Lisp_Object | 966 static Lisp_Object |
955 toolbar_buttons_at_pixpos (struct frame *f, int x_coord, int y_coord) | 967 toolbar_buttons_at_pixpos (struct frame *f, int x_coord, int y_coord) |
956 { | 968 { |
957 CHECK_TOOLBAR (TOP_TOOLBAR); | 969 CHECK_TOOLBAR (TOP_EDGE); |
958 CHECK_TOOLBAR (BOTTOM_TOOLBAR); | 970 CHECK_TOOLBAR (BOTTOM_EDGE); |
959 CHECK_TOOLBAR (LEFT_TOOLBAR); | 971 CHECK_TOOLBAR (LEFT_EDGE); |
960 CHECK_TOOLBAR (RIGHT_TOOLBAR); | 972 CHECK_TOOLBAR (RIGHT_EDGE); |
961 | 973 |
962 return Qnil; | 974 return Qnil; |
963 } | 975 } |
964 #undef CHECK_TOOLBAR | 976 #undef CHECK_TOOLBAR |
965 | 977 |
999 /* Toolbar specifier type */ | 1011 /* Toolbar specifier type */ |
1000 /************************************************************************/ | 1012 /************************************************************************/ |
1001 | 1013 |
1002 DEFINE_SPECIFIER_TYPE (toolbar); | 1014 DEFINE_SPECIFIER_TYPE (toolbar); |
1003 | 1015 |
1004 #define CTB_ERROR(msg) do { \ | 1016 #define CTB_ERROR(msg) do { \ |
1005 maybe_signal_error (Qinvalid_argument, msg, button, Qtoolbar, errb); \ | 1017 maybe_signal_error (Qinvalid_argument, msg, button, Qtoolbar, errb); \ |
1006 RETURN_SANS_WARNINGS Qnil; \ | 1018 RETURN_SANS_WARNINGS Qnil; \ |
1007 } while (0) | 1019 } while (0) |
1008 | 1020 |
1009 /* Returns Q_style if key was :style, Qt if ok otherwise, Qnil if error. */ | 1021 /* Returns Q_style if key was :style, Qt if ok otherwise, Qnil if error. */ |
1010 static Lisp_Object | 1022 static Lisp_Object |
1011 check_toolbar_button_keywords (Lisp_Object button, Lisp_Object key, | 1023 check_toolbar_button_keywords (Lisp_Object button, Lisp_Object key, |
1218 /* | 1230 /* |
1219 Helper for invalidating the real specifier when default | 1231 Helper for invalidating the real specifier when default |
1220 specifier caching changes | 1232 specifier caching changes |
1221 */ | 1233 */ |
1222 static void | 1234 static void |
1223 recompute_overlaying_specifier (Lisp_Object real_one[4]) | 1235 recompute_overlaying_specifier (Lisp_Object real_one[NUM_EDGES]) |
1224 { | 1236 { |
1225 enum toolbar_pos pos = decode_toolbar_position (Vdefault_toolbar_position); | 1237 enum edge_pos pos = decode_toolbar_position (Vdefault_toolbar_position); |
1226 Fset_specifier_dirty_flag (real_one[pos]); | 1238 Fset_specifier_dirty_flag (real_one[pos]); |
1227 } | 1239 } |
1228 | 1240 |
1229 static void | 1241 static void |
1230 toolbar_specs_changed (Lisp_Object UNUSED (specifier), | 1242 toolbar_specs_changed (Lisp_Object UNUSED (specifier), |
1503 offsetof (struct window, default_toolbar), | 1515 offsetof (struct window, default_toolbar), |
1504 default_toolbar_specs_changed, | 1516 default_toolbar_specs_changed, |
1505 0, 0, 0); | 1517 0, 0, 0); |
1506 | 1518 |
1507 DEFVAR_SPECIFIER ("top-toolbar", | 1519 DEFVAR_SPECIFIER ("top-toolbar", |
1508 &Vtoolbar[TOP_TOOLBAR] /* | 1520 &Vtoolbar[TOP_EDGE] /* |
1509 Specifier for the toolbar at the top of the frame. | 1521 Specifier for the toolbar at the top of the frame. |
1510 Use `set-specifier' to change this. | 1522 Use `set-specifier' to change this. |
1511 See `default-toolbar' for a description of a valid toolbar instantiator. | 1523 See `default-toolbar' for a description of a valid toolbar instantiator. |
1512 */ ); | 1524 */ ); |
1513 Vtoolbar[TOP_TOOLBAR] = Fmake_specifier (Qtoolbar); | 1525 Vtoolbar[TOP_EDGE] = Fmake_specifier (Qtoolbar); |
1514 set_specifier_caching (Vtoolbar[TOP_TOOLBAR], | 1526 set_specifier_caching (Vtoolbar[TOP_EDGE], |
1515 offsetof (struct window, toolbar[TOP_TOOLBAR]), | 1527 offsetof (struct window, toolbar[TOP_EDGE]), |
1516 toolbar_specs_changed, | 1528 toolbar_specs_changed, |
1517 0, 0, 0); | 1529 0, 0, 0); |
1518 | 1530 |
1519 DEFVAR_SPECIFIER ("bottom-toolbar", | 1531 DEFVAR_SPECIFIER ("bottom-toolbar", |
1520 &Vtoolbar[BOTTOM_TOOLBAR] /* | 1532 &Vtoolbar[BOTTOM_EDGE] /* |
1521 Specifier for the toolbar at the bottom of the frame. | 1533 Specifier for the toolbar at the bottom of the frame. |
1522 Use `set-specifier' to change this. | 1534 Use `set-specifier' to change this. |
1523 See `default-toolbar' for a description of a valid toolbar instantiator. | 1535 See `default-toolbar' for a description of a valid toolbar instantiator. |
1524 | 1536 |
1525 Note that, unless the `default-toolbar-position' is `bottom', by | 1537 Note that, unless the `default-toolbar-position' is `bottom', by |
1526 default the height of the bottom toolbar (controlled by | 1538 default the height of the bottom toolbar (controlled by |
1527 `bottom-toolbar-height') is 0; thus, a bottom toolbar will not be | 1539 `bottom-toolbar-height') is 0; thus, a bottom toolbar will not be |
1528 displayed even if you provide a value for `bottom-toolbar'. | 1540 displayed even if you provide a value for `bottom-toolbar'. |
1529 */ ); | 1541 */ ); |
1530 Vtoolbar[BOTTOM_TOOLBAR] = Fmake_specifier (Qtoolbar); | 1542 Vtoolbar[BOTTOM_EDGE] = Fmake_specifier (Qtoolbar); |
1531 set_specifier_caching (Vtoolbar[BOTTOM_TOOLBAR], | 1543 set_specifier_caching (Vtoolbar[BOTTOM_EDGE], |
1532 offsetof (struct window, toolbar[BOTTOM_TOOLBAR]), | 1544 offsetof (struct window, toolbar[BOTTOM_EDGE]), |
1533 toolbar_specs_changed, | 1545 toolbar_specs_changed, |
1534 0, 0, 0); | 1546 0, 0, 0); |
1535 | 1547 |
1536 DEFVAR_SPECIFIER ("left-toolbar", | 1548 DEFVAR_SPECIFIER ("left-toolbar", |
1537 &Vtoolbar[LEFT_TOOLBAR] /* | 1549 &Vtoolbar[LEFT_EDGE] /* |
1538 Specifier for the toolbar at the left edge of the frame. | 1550 Specifier for the toolbar at the left edge of the frame. |
1539 Use `set-specifier' to change this. | 1551 Use `set-specifier' to change this. |
1540 See `default-toolbar' for a description of a valid toolbar instantiator. | 1552 See `default-toolbar' for a description of a valid toolbar instantiator. |
1541 | 1553 |
1542 Note that, unless the `default-toolbar-position' is `left', by | 1554 Note that, unless the `default-toolbar-position' is `left', by |
1543 default the height of the left toolbar (controlled by | 1555 default the height of the left toolbar (controlled by |
1544 `left-toolbar-width') is 0; thus, a left toolbar will not be | 1556 `left-toolbar-width') is 0; thus, a left toolbar will not be |
1545 displayed even if you provide a value for `left-toolbar'. | 1557 displayed even if you provide a value for `left-toolbar'. |
1546 */ ); | 1558 */ ); |
1547 Vtoolbar[LEFT_TOOLBAR] = Fmake_specifier (Qtoolbar); | 1559 Vtoolbar[LEFT_EDGE] = Fmake_specifier (Qtoolbar); |
1548 set_specifier_caching (Vtoolbar[LEFT_TOOLBAR], | 1560 set_specifier_caching (Vtoolbar[LEFT_EDGE], |
1549 offsetof (struct window, toolbar[LEFT_TOOLBAR]), | 1561 offsetof (struct window, toolbar[LEFT_EDGE]), |
1550 toolbar_specs_changed, | 1562 toolbar_specs_changed, |
1551 0, 0, 0); | 1563 0, 0, 0); |
1552 | 1564 |
1553 DEFVAR_SPECIFIER ("right-toolbar", | 1565 DEFVAR_SPECIFIER ("right-toolbar", |
1554 &Vtoolbar[RIGHT_TOOLBAR] /* | 1566 &Vtoolbar[RIGHT_EDGE] /* |
1555 Specifier for the toolbar at the right edge of the frame. | 1567 Specifier for the toolbar at the right edge of the frame. |
1556 Use `set-specifier' to change this. | 1568 Use `set-specifier' to change this. |
1557 See `default-toolbar' for a description of a valid toolbar instantiator. | 1569 See `default-toolbar' for a description of a valid toolbar instantiator. |
1558 | 1570 |
1559 Note that, unless the `default-toolbar-position' is `right', by | 1571 Note that, unless the `default-toolbar-position' is `right', by |
1560 default the height of the right toolbar (controlled by | 1572 default the height of the right toolbar (controlled by |
1561 `right-toolbar-width') is 0; thus, a right toolbar will not be | 1573 `right-toolbar-width') is 0; thus, a right toolbar will not be |
1562 displayed even if you provide a value for `right-toolbar'. | 1574 displayed even if you provide a value for `right-toolbar'. |
1563 */ ); | 1575 */ ); |
1564 Vtoolbar[RIGHT_TOOLBAR] = Fmake_specifier (Qtoolbar); | 1576 Vtoolbar[RIGHT_EDGE] = Fmake_specifier (Qtoolbar); |
1565 set_specifier_caching (Vtoolbar[RIGHT_TOOLBAR], | 1577 set_specifier_caching (Vtoolbar[RIGHT_EDGE], |
1566 offsetof (struct window, toolbar[RIGHT_TOOLBAR]), | 1578 offsetof (struct window, toolbar[RIGHT_EDGE]), |
1567 toolbar_specs_changed, | 1579 toolbar_specs_changed, |
1568 0, 0, 0); | 1580 0, 0, 0); |
1569 | 1581 |
1570 /* initially, top inherits from default; this can be | 1582 /* initially, top inherits from default; this can be |
1571 changed with `set-default-toolbar-position'. */ | 1583 changed with `set-default-toolbar-position'. */ |
1572 fb = list1 (Fcons (Qnil, Qnil)); | 1584 fb = list1 (Fcons (Qnil, Qnil)); |
1573 set_specifier_fallback (Vdefault_toolbar, fb); | 1585 set_specifier_fallback (Vdefault_toolbar, fb); |
1574 set_specifier_fallback (Vtoolbar[TOP_TOOLBAR], Vdefault_toolbar); | 1586 set_specifier_fallback (Vtoolbar[TOP_EDGE], Vdefault_toolbar); |
1575 set_specifier_fallback (Vtoolbar[BOTTOM_TOOLBAR], fb); | 1587 set_specifier_fallback (Vtoolbar[BOTTOM_EDGE], fb); |
1576 set_specifier_fallback (Vtoolbar[LEFT_TOOLBAR], fb); | 1588 set_specifier_fallback (Vtoolbar[LEFT_EDGE], fb); |
1577 set_specifier_fallback (Vtoolbar[RIGHT_TOOLBAR], fb); | 1589 set_specifier_fallback (Vtoolbar[RIGHT_EDGE], fb); |
1578 | 1590 |
1579 DEFVAR_SPECIFIER ("default-toolbar-height", &Vdefault_toolbar_height /* | 1591 DEFVAR_SPECIFIER ("default-toolbar-height", &Vdefault_toolbar_height /* |
1580 *Height of the default toolbar, if it's oriented horizontally. | 1592 *Height of the default toolbar, if it's oriented horizontally. |
1581 This is a specifier; use `set-specifier' to change it. | 1593 This is a specifier; use `set-specifier' to change it. |
1582 | 1594 |
1634 default_toolbar_size_changed_in_window, | 1646 default_toolbar_size_changed_in_window, |
1635 offsetof (struct frame, default_toolbar_width), | 1647 offsetof (struct frame, default_toolbar_width), |
1636 default_toolbar_size_changed_in_frame, 0); | 1648 default_toolbar_size_changed_in_frame, 0); |
1637 | 1649 |
1638 DEFVAR_SPECIFIER ("top-toolbar-height", | 1650 DEFVAR_SPECIFIER ("top-toolbar-height", |
1639 &Vtoolbar_size[TOP_TOOLBAR] /* | 1651 &Vtoolbar_size[TOP_EDGE] /* |
1640 *Height of the top toolbar. | 1652 *Height of the top toolbar. |
1641 This is a specifier; use `set-specifier' to change it. | 1653 This is a specifier; use `set-specifier' to change it. |
1642 | 1654 |
1643 See `default-toolbar-height' for more information. | 1655 See `default-toolbar-height' for more information. |
1644 */ ); | 1656 */ ); |
1645 Vtoolbar_size[TOP_TOOLBAR] = Fmake_specifier (Qnatnum); | 1657 Vtoolbar_size[TOP_EDGE] = Fmake_specifier (Qnatnum); |
1646 set_specifier_caching (Vtoolbar_size[TOP_TOOLBAR], | 1658 set_specifier_caching (Vtoolbar_size[TOP_EDGE], |
1647 offsetof (struct window, toolbar_size[TOP_TOOLBAR]), | 1659 offsetof (struct window, toolbar_size[TOP_EDGE]), |
1648 toolbar_geometry_changed_in_window, | 1660 toolbar_geometry_changed_in_window, |
1649 offsetof (struct frame, toolbar_size[TOP_TOOLBAR]), | 1661 offsetof (struct frame, toolbar_size[TOP_EDGE]), |
1650 frame_size_slipped, 0); | 1662 frame_size_slipped, 0); |
1651 | 1663 |
1652 DEFVAR_SPECIFIER ("bottom-toolbar-height", | 1664 DEFVAR_SPECIFIER ("bottom-toolbar-height", |
1653 &Vtoolbar_size[BOTTOM_TOOLBAR] /* | 1665 &Vtoolbar_size[BOTTOM_EDGE] /* |
1654 *Height of the bottom toolbar. | 1666 *Height of the bottom toolbar. |
1655 This is a specifier; use `set-specifier' to change it. | 1667 This is a specifier; use `set-specifier' to change it. |
1656 | 1668 |
1657 See `default-toolbar-height' for more information. | 1669 See `default-toolbar-height' for more information. |
1658 */ ); | 1670 */ ); |
1659 Vtoolbar_size[BOTTOM_TOOLBAR] = Fmake_specifier (Qnatnum); | 1671 Vtoolbar_size[BOTTOM_EDGE] = Fmake_specifier (Qnatnum); |
1660 set_specifier_caching (Vtoolbar_size[BOTTOM_TOOLBAR], | 1672 set_specifier_caching (Vtoolbar_size[BOTTOM_EDGE], |
1661 offsetof (struct window, toolbar_size[BOTTOM_TOOLBAR]), | 1673 offsetof (struct window, toolbar_size[BOTTOM_EDGE]), |
1662 toolbar_geometry_changed_in_window, | 1674 toolbar_geometry_changed_in_window, |
1663 offsetof (struct frame, toolbar_size[BOTTOM_TOOLBAR]), | 1675 offsetof (struct frame, toolbar_size[BOTTOM_EDGE]), |
1664 frame_size_slipped, 0); | 1676 frame_size_slipped, 0); |
1665 | 1677 |
1666 DEFVAR_SPECIFIER ("left-toolbar-width", | 1678 DEFVAR_SPECIFIER ("left-toolbar-width", |
1667 &Vtoolbar_size[LEFT_TOOLBAR] /* | 1679 &Vtoolbar_size[LEFT_EDGE] /* |
1668 *Width of left toolbar. | 1680 *Width of left toolbar. |
1669 This is a specifier; use `set-specifier' to change it. | 1681 This is a specifier; use `set-specifier' to change it. |
1670 | 1682 |
1671 See `default-toolbar-height' for more information. | 1683 See `default-toolbar-height' for more information. |
1672 */ ); | 1684 */ ); |
1673 Vtoolbar_size[LEFT_TOOLBAR] = Fmake_specifier (Qnatnum); | 1685 Vtoolbar_size[LEFT_EDGE] = Fmake_specifier (Qnatnum); |
1674 set_specifier_caching (Vtoolbar_size[LEFT_TOOLBAR], | 1686 set_specifier_caching (Vtoolbar_size[LEFT_EDGE], |
1675 offsetof (struct window, toolbar_size[LEFT_TOOLBAR]), | 1687 offsetof (struct window, toolbar_size[LEFT_EDGE]), |
1676 toolbar_geometry_changed_in_window, | 1688 toolbar_geometry_changed_in_window, |
1677 offsetof (struct frame, toolbar_size[LEFT_TOOLBAR]), | 1689 offsetof (struct frame, toolbar_size[LEFT_EDGE]), |
1678 frame_size_slipped, 0); | 1690 frame_size_slipped, 0); |
1679 | 1691 |
1680 DEFVAR_SPECIFIER ("right-toolbar-width", | 1692 DEFVAR_SPECIFIER ("right-toolbar-width", |
1681 &Vtoolbar_size[RIGHT_TOOLBAR] /* | 1693 &Vtoolbar_size[RIGHT_EDGE] /* |
1682 *Width of right toolbar. | 1694 *Width of right toolbar. |
1683 This is a specifier; use `set-specifier' to change it. | 1695 This is a specifier; use `set-specifier' to change it. |
1684 | 1696 |
1685 See `default-toolbar-height' for more information. | 1697 See `default-toolbar-height' for more information. |
1686 */ ); | 1698 */ ); |
1687 Vtoolbar_size[RIGHT_TOOLBAR] = Fmake_specifier (Qnatnum); | 1699 Vtoolbar_size[RIGHT_EDGE] = Fmake_specifier (Qnatnum); |
1688 set_specifier_caching (Vtoolbar_size[RIGHT_TOOLBAR], | 1700 set_specifier_caching (Vtoolbar_size[RIGHT_EDGE], |
1689 offsetof (struct window, toolbar_size[RIGHT_TOOLBAR]), | 1701 offsetof (struct window, toolbar_size[RIGHT_EDGE]), |
1690 toolbar_geometry_changed_in_window, | 1702 toolbar_geometry_changed_in_window, |
1691 offsetof (struct frame, toolbar_size[RIGHT_TOOLBAR]), | 1703 offsetof (struct frame, toolbar_size[RIGHT_EDGE]), |
1692 frame_size_slipped, 0); | 1704 frame_size_slipped, 0); |
1693 | 1705 |
1694 DEFVAR_SPECIFIER ("toolbar-shadow-thickness", | 1706 DEFVAR_SPECIFIER ("toolbar-shadow-thickness", |
1695 &Vtoolbar_shadow_thickness /* | 1707 &Vtoolbar_shadow_thickness /* |
1696 *Width of shadows around toolbar buttons. | 1708 *Width of shadows around toolbar buttons. |
1752 make_int (MSWINDOWS_DEFAULT_TOOLBAR_WIDTH)), fb); | 1764 make_int (MSWINDOWS_DEFAULT_TOOLBAR_WIDTH)), fb); |
1753 #endif | 1765 #endif |
1754 if (!NILP (fb)) | 1766 if (!NILP (fb)) |
1755 set_specifier_fallback (Vdefault_toolbar_width, fb); | 1767 set_specifier_fallback (Vdefault_toolbar_width, fb); |
1756 | 1768 |
1757 set_specifier_fallback (Vtoolbar_size[TOP_TOOLBAR], Vdefault_toolbar_height); | 1769 set_specifier_fallback (Vtoolbar_size[TOP_EDGE], Vdefault_toolbar_height); |
1758 fb = list1 (Fcons (Qnil, Qzero)); | 1770 fb = list1 (Fcons (Qnil, Qzero)); |
1759 set_specifier_fallback (Vtoolbar_size[BOTTOM_TOOLBAR], fb); | 1771 set_specifier_fallback (Vtoolbar_size[BOTTOM_EDGE], fb); |
1760 set_specifier_fallback (Vtoolbar_size[LEFT_TOOLBAR], fb); | 1772 set_specifier_fallback (Vtoolbar_size[LEFT_EDGE], fb); |
1761 set_specifier_fallback (Vtoolbar_size[RIGHT_TOOLBAR], fb); | 1773 set_specifier_fallback (Vtoolbar_size[RIGHT_EDGE], fb); |
1762 | 1774 |
1763 DEFVAR_SPECIFIER ("default-toolbar-border-width", | 1775 DEFVAR_SPECIFIER ("default-toolbar-border-width", |
1764 &Vdefault_toolbar_border_width /* | 1776 &Vdefault_toolbar_border_width /* |
1765 *Width of the border around the default toolbar. | 1777 *Width of the border around the default toolbar. |
1766 This is a specifier; use `set-specifier' to change it. | 1778 This is a specifier; use `set-specifier' to change it. |
1788 default_toolbar_border_width_changed_in_window, | 1800 default_toolbar_border_width_changed_in_window, |
1789 offsetof (struct frame, default_toolbar_border_width), | 1801 offsetof (struct frame, default_toolbar_border_width), |
1790 default_toolbar_border_width_changed_in_frame, 0); | 1802 default_toolbar_border_width_changed_in_frame, 0); |
1791 | 1803 |
1792 DEFVAR_SPECIFIER ("top-toolbar-border-width", | 1804 DEFVAR_SPECIFIER ("top-toolbar-border-width", |
1793 &Vtoolbar_border_width[TOP_TOOLBAR] /* | 1805 &Vtoolbar_border_width[TOP_EDGE] /* |
1794 *Border width of the top toolbar. | 1806 *Border width of the top toolbar. |
1795 This is a specifier; use `set-specifier' to change it. | 1807 This is a specifier; use `set-specifier' to change it. |
1796 | 1808 |
1797 See `default-toolbar-height' for more information. | 1809 See `default-toolbar-height' for more information. |
1798 */ ); | 1810 */ ); |
1799 Vtoolbar_border_width[TOP_TOOLBAR] = Fmake_specifier (Qnatnum); | 1811 Vtoolbar_border_width[TOP_EDGE] = Fmake_specifier (Qnatnum); |
1800 set_specifier_caching (Vtoolbar_border_width[TOP_TOOLBAR], | 1812 set_specifier_caching (Vtoolbar_border_width[TOP_EDGE], |
1801 offsetof (struct window, | 1813 offsetof (struct window, |
1802 toolbar_border_width[TOP_TOOLBAR]), | 1814 toolbar_border_width[TOP_EDGE]), |
1803 toolbar_geometry_changed_in_window, | 1815 toolbar_geometry_changed_in_window, |
1804 offsetof (struct frame, | 1816 offsetof (struct frame, |
1805 toolbar_border_width[TOP_TOOLBAR]), | 1817 toolbar_border_width[TOP_EDGE]), |
1806 frame_size_slipped, 0); | 1818 frame_size_slipped, 0); |
1807 | 1819 |
1808 DEFVAR_SPECIFIER ("bottom-toolbar-border-width", | 1820 DEFVAR_SPECIFIER ("bottom-toolbar-border-width", |
1809 &Vtoolbar_border_width[BOTTOM_TOOLBAR] /* | 1821 &Vtoolbar_border_width[BOTTOM_EDGE] /* |
1810 *Border width of the bottom toolbar. | 1822 *Border width of the bottom toolbar. |
1811 This is a specifier; use `set-specifier' to change it. | 1823 This is a specifier; use `set-specifier' to change it. |
1812 | 1824 |
1813 See `default-toolbar-height' for more information. | 1825 See `default-toolbar-height' for more information. |
1814 */ ); | 1826 */ ); |
1815 Vtoolbar_border_width[BOTTOM_TOOLBAR] = Fmake_specifier (Qnatnum); | 1827 Vtoolbar_border_width[BOTTOM_EDGE] = Fmake_specifier (Qnatnum); |
1816 set_specifier_caching (Vtoolbar_border_width[BOTTOM_TOOLBAR], | 1828 set_specifier_caching (Vtoolbar_border_width[BOTTOM_EDGE], |
1817 offsetof (struct window, | 1829 offsetof (struct window, |
1818 toolbar_border_width[BOTTOM_TOOLBAR]), | 1830 toolbar_border_width[BOTTOM_EDGE]), |
1819 toolbar_geometry_changed_in_window, | 1831 toolbar_geometry_changed_in_window, |
1820 offsetof (struct frame, | 1832 offsetof (struct frame, |
1821 toolbar_border_width[BOTTOM_TOOLBAR]), | 1833 toolbar_border_width[BOTTOM_EDGE]), |
1822 frame_size_slipped, 0); | 1834 frame_size_slipped, 0); |
1823 | 1835 |
1824 DEFVAR_SPECIFIER ("left-toolbar-border-width", | 1836 DEFVAR_SPECIFIER ("left-toolbar-border-width", |
1825 &Vtoolbar_border_width[LEFT_TOOLBAR] /* | 1837 &Vtoolbar_border_width[LEFT_EDGE] /* |
1826 *Border width of left toolbar. | 1838 *Border width of left toolbar. |
1827 This is a specifier; use `set-specifier' to change it. | 1839 This is a specifier; use `set-specifier' to change it. |
1828 | 1840 |
1829 See `default-toolbar-height' for more information. | 1841 See `default-toolbar-height' for more information. |
1830 */ ); | 1842 */ ); |
1831 Vtoolbar_border_width[LEFT_TOOLBAR] = Fmake_specifier (Qnatnum); | 1843 Vtoolbar_border_width[LEFT_EDGE] = Fmake_specifier (Qnatnum); |
1832 set_specifier_caching (Vtoolbar_border_width[LEFT_TOOLBAR], | 1844 set_specifier_caching (Vtoolbar_border_width[LEFT_EDGE], |
1833 offsetof (struct window, | 1845 offsetof (struct window, |
1834 toolbar_border_width[LEFT_TOOLBAR]), | 1846 toolbar_border_width[LEFT_EDGE]), |
1835 toolbar_geometry_changed_in_window, | 1847 toolbar_geometry_changed_in_window, |
1836 offsetof (struct frame, | 1848 offsetof (struct frame, |
1837 toolbar_border_width[LEFT_TOOLBAR]), | 1849 toolbar_border_width[LEFT_EDGE]), |
1838 frame_size_slipped, 0); | 1850 frame_size_slipped, 0); |
1839 | 1851 |
1840 DEFVAR_SPECIFIER ("right-toolbar-border-width", | 1852 DEFVAR_SPECIFIER ("right-toolbar-border-width", |
1841 &Vtoolbar_border_width[RIGHT_TOOLBAR] /* | 1853 &Vtoolbar_border_width[RIGHT_EDGE] /* |
1842 *Border width of right toolbar. | 1854 *Border width of right toolbar. |
1843 This is a specifier; use `set-specifier' to change it. | 1855 This is a specifier; use `set-specifier' to change it. |
1844 | 1856 |
1845 See `default-toolbar-height' for more information. | 1857 See `default-toolbar-height' for more information. |
1846 */ ); | 1858 */ ); |
1847 Vtoolbar_border_width[RIGHT_TOOLBAR] = Fmake_specifier (Qnatnum); | 1859 Vtoolbar_border_width[RIGHT_EDGE] = Fmake_specifier (Qnatnum); |
1848 set_specifier_caching (Vtoolbar_border_width[RIGHT_TOOLBAR], | 1860 set_specifier_caching (Vtoolbar_border_width[RIGHT_EDGE], |
1849 offsetof (struct window, | 1861 offsetof (struct window, |
1850 toolbar_border_width[RIGHT_TOOLBAR]), | 1862 toolbar_border_width[RIGHT_EDGE]), |
1851 toolbar_geometry_changed_in_window, | 1863 toolbar_geometry_changed_in_window, |
1852 offsetof (struct frame, | 1864 offsetof (struct frame, |
1853 toolbar_border_width[RIGHT_TOOLBAR]), | 1865 toolbar_border_width[RIGHT_EDGE]), |
1854 frame_size_slipped, 0); | 1866 frame_size_slipped, 0); |
1855 | 1867 |
1856 fb = Qnil; | 1868 fb = Qnil; |
1857 #ifdef HAVE_TTY | 1869 #ifdef HAVE_TTY |
1858 fb = Fcons (Fcons (list1 (Qtty), Qzero), fb); | 1870 fb = Fcons (Fcons (list1 (Qtty), Qzero), fb); |
1867 fb = Fcons (Fcons (list1 (Qmswindows), make_int (MSWINDOWS_DEFAULT_TOOLBAR_BORDER_WIDTH)), fb); | 1879 fb = Fcons (Fcons (list1 (Qmswindows), make_int (MSWINDOWS_DEFAULT_TOOLBAR_BORDER_WIDTH)), fb); |
1868 #endif | 1880 #endif |
1869 if (!NILP (fb)) | 1881 if (!NILP (fb)) |
1870 set_specifier_fallback (Vdefault_toolbar_border_width, fb); | 1882 set_specifier_fallback (Vdefault_toolbar_border_width, fb); |
1871 | 1883 |
1872 set_specifier_fallback (Vtoolbar_border_width[TOP_TOOLBAR], Vdefault_toolbar_border_width); | 1884 set_specifier_fallback (Vtoolbar_border_width[TOP_EDGE], Vdefault_toolbar_border_width); |
1873 fb = list1 (Fcons (Qnil, Qzero)); | 1885 fb = list1 (Fcons (Qnil, Qzero)); |
1874 set_specifier_fallback (Vtoolbar_border_width[BOTTOM_TOOLBAR], fb); | 1886 set_specifier_fallback (Vtoolbar_border_width[BOTTOM_EDGE], fb); |
1875 set_specifier_fallback (Vtoolbar_border_width[LEFT_TOOLBAR], fb); | 1887 set_specifier_fallback (Vtoolbar_border_width[LEFT_EDGE], fb); |
1876 set_specifier_fallback (Vtoolbar_border_width[RIGHT_TOOLBAR], fb); | 1888 set_specifier_fallback (Vtoolbar_border_width[RIGHT_EDGE], fb); |
1877 | 1889 |
1878 DEFVAR_SPECIFIER ("default-toolbar-visible-p", &Vdefault_toolbar_visible_p /* | 1890 DEFVAR_SPECIFIER ("default-toolbar-visible-p", &Vdefault_toolbar_visible_p /* |
1879 *Whether the default toolbar is visible. | 1891 *Whether the default toolbar is visible. |
1880 This is a specifier; use `set-specifier' to change it. | 1892 This is a specifier; use `set-specifier' to change it. |
1881 | 1893 |
1901 default_toolbar_visible_p_changed_in_window, | 1913 default_toolbar_visible_p_changed_in_window, |
1902 offsetof (struct frame, default_toolbar_visible_p), | 1914 offsetof (struct frame, default_toolbar_visible_p), |
1903 default_toolbar_visible_p_changed_in_frame, 0); | 1915 default_toolbar_visible_p_changed_in_frame, 0); |
1904 | 1916 |
1905 DEFVAR_SPECIFIER ("top-toolbar-visible-p", | 1917 DEFVAR_SPECIFIER ("top-toolbar-visible-p", |
1906 &Vtoolbar_visible_p[TOP_TOOLBAR] /* | 1918 &Vtoolbar_visible_p[TOP_EDGE] /* |
1907 *Whether the top toolbar is visible. | 1919 *Whether the top toolbar is visible. |
1908 This is a specifier; use `set-specifier' to change it. | 1920 This is a specifier; use `set-specifier' to change it. |
1909 | 1921 |
1910 See `default-toolbar-visible-p' for more information. | 1922 See `default-toolbar-visible-p' for more information. |
1911 */ ); | 1923 */ ); |
1912 Vtoolbar_visible_p[TOP_TOOLBAR] = Fmake_specifier (Qboolean); | 1924 Vtoolbar_visible_p[TOP_EDGE] = Fmake_specifier (Qboolean); |
1913 set_specifier_caching (Vtoolbar_visible_p[TOP_TOOLBAR], | 1925 set_specifier_caching (Vtoolbar_visible_p[TOP_EDGE], |
1914 offsetof (struct window, | 1926 offsetof (struct window, |
1915 toolbar_visible_p[TOP_TOOLBAR]), | 1927 toolbar_visible_p[TOP_EDGE]), |
1916 toolbar_geometry_changed_in_window, | 1928 toolbar_geometry_changed_in_window, |
1917 offsetof (struct frame, | 1929 offsetof (struct frame, |
1918 toolbar_visible_p[TOP_TOOLBAR]), | 1930 toolbar_visible_p[TOP_EDGE]), |
1919 frame_size_slipped, 0); | 1931 frame_size_slipped, 0); |
1920 | 1932 |
1921 DEFVAR_SPECIFIER ("bottom-toolbar-visible-p", | 1933 DEFVAR_SPECIFIER ("bottom-toolbar-visible-p", |
1922 &Vtoolbar_visible_p[BOTTOM_TOOLBAR] /* | 1934 &Vtoolbar_visible_p[BOTTOM_EDGE] /* |
1923 *Whether the bottom toolbar is visible. | 1935 *Whether the bottom toolbar is visible. |
1924 This is a specifier; use `set-specifier' to change it. | 1936 This is a specifier; use `set-specifier' to change it. |
1925 | 1937 |
1926 See `default-toolbar-visible-p' for more information. | 1938 See `default-toolbar-visible-p' for more information. |
1927 */ ); | 1939 */ ); |
1928 Vtoolbar_visible_p[BOTTOM_TOOLBAR] = Fmake_specifier (Qboolean); | 1940 Vtoolbar_visible_p[BOTTOM_EDGE] = Fmake_specifier (Qboolean); |
1929 set_specifier_caching (Vtoolbar_visible_p[BOTTOM_TOOLBAR], | 1941 set_specifier_caching (Vtoolbar_visible_p[BOTTOM_EDGE], |
1930 offsetof (struct window, | 1942 offsetof (struct window, |
1931 toolbar_visible_p[BOTTOM_TOOLBAR]), | 1943 toolbar_visible_p[BOTTOM_EDGE]), |
1932 toolbar_geometry_changed_in_window, | 1944 toolbar_geometry_changed_in_window, |
1933 offsetof (struct frame, | 1945 offsetof (struct frame, |
1934 toolbar_visible_p[BOTTOM_TOOLBAR]), | 1946 toolbar_visible_p[BOTTOM_EDGE]), |
1935 frame_size_slipped, 0); | 1947 frame_size_slipped, 0); |
1936 | 1948 |
1937 DEFVAR_SPECIFIER ("left-toolbar-visible-p", | 1949 DEFVAR_SPECIFIER ("left-toolbar-visible-p", |
1938 &Vtoolbar_visible_p[LEFT_TOOLBAR] /* | 1950 &Vtoolbar_visible_p[LEFT_EDGE] /* |
1939 *Whether the left toolbar is visible. | 1951 *Whether the left toolbar is visible. |
1940 This is a specifier; use `set-specifier' to change it. | 1952 This is a specifier; use `set-specifier' to change it. |
1941 | 1953 |
1942 See `default-toolbar-visible-p' for more information. | 1954 See `default-toolbar-visible-p' for more information. |
1943 */ ); | 1955 */ ); |
1944 Vtoolbar_visible_p[LEFT_TOOLBAR] = Fmake_specifier (Qboolean); | 1956 Vtoolbar_visible_p[LEFT_EDGE] = Fmake_specifier (Qboolean); |
1945 set_specifier_caching (Vtoolbar_visible_p[LEFT_TOOLBAR], | 1957 set_specifier_caching (Vtoolbar_visible_p[LEFT_EDGE], |
1946 offsetof (struct window, | 1958 offsetof (struct window, |
1947 toolbar_visible_p[LEFT_TOOLBAR]), | 1959 toolbar_visible_p[LEFT_EDGE]), |
1948 toolbar_geometry_changed_in_window, | 1960 toolbar_geometry_changed_in_window, |
1949 offsetof (struct frame, | 1961 offsetof (struct frame, |
1950 toolbar_visible_p[LEFT_TOOLBAR]), | 1962 toolbar_visible_p[LEFT_EDGE]), |
1951 frame_size_slipped, 0); | 1963 frame_size_slipped, 0); |
1952 | 1964 |
1953 DEFVAR_SPECIFIER ("right-toolbar-visible-p", | 1965 DEFVAR_SPECIFIER ("right-toolbar-visible-p", |
1954 &Vtoolbar_visible_p[RIGHT_TOOLBAR] /* | 1966 &Vtoolbar_visible_p[RIGHT_EDGE] /* |
1955 *Whether the right toolbar is visible. | 1967 *Whether the right toolbar is visible. |
1956 This is a specifier; use `set-specifier' to change it. | 1968 This is a specifier; use `set-specifier' to change it. |
1957 | 1969 |
1958 See `default-toolbar-visible-p' for more information. | 1970 See `default-toolbar-visible-p' for more information. |
1959 */ ); | 1971 */ ); |
1960 Vtoolbar_visible_p[RIGHT_TOOLBAR] = Fmake_specifier (Qboolean); | 1972 Vtoolbar_visible_p[RIGHT_EDGE] = Fmake_specifier (Qboolean); |
1961 set_specifier_caching (Vtoolbar_visible_p[RIGHT_TOOLBAR], | 1973 set_specifier_caching (Vtoolbar_visible_p[RIGHT_EDGE], |
1962 offsetof (struct window, | 1974 offsetof (struct window, |
1963 toolbar_visible_p[RIGHT_TOOLBAR]), | 1975 toolbar_visible_p[RIGHT_EDGE]), |
1964 toolbar_geometry_changed_in_window, | 1976 toolbar_geometry_changed_in_window, |
1965 offsetof (struct frame, | 1977 offsetof (struct frame, |
1966 toolbar_visible_p[RIGHT_TOOLBAR]), | 1978 toolbar_visible_p[RIGHT_EDGE]), |
1967 frame_size_slipped, 0); | 1979 frame_size_slipped, 0); |
1968 | 1980 |
1969 /* initially, top inherits from default; this can be | 1981 /* initially, top inherits from default; this can be |
1970 changed with `set-default-toolbar-position'. */ | 1982 changed with `set-default-toolbar-position'. */ |
1971 fb = list1 (Fcons (Qnil, Qt)); | 1983 fb = list1 (Fcons (Qnil, Qt)); |
1972 set_specifier_fallback (Vdefault_toolbar_visible_p, fb); | 1984 set_specifier_fallback (Vdefault_toolbar_visible_p, fb); |
1973 set_specifier_fallback (Vtoolbar_visible_p[TOP_TOOLBAR], | 1985 set_specifier_fallback (Vtoolbar_visible_p[TOP_EDGE], |
1974 Vdefault_toolbar_visible_p); | 1986 Vdefault_toolbar_visible_p); |
1975 set_specifier_fallback (Vtoolbar_visible_p[BOTTOM_TOOLBAR], fb); | 1987 set_specifier_fallback (Vtoolbar_visible_p[BOTTOM_EDGE], fb); |
1976 set_specifier_fallback (Vtoolbar_visible_p[LEFT_TOOLBAR], fb); | 1988 set_specifier_fallback (Vtoolbar_visible_p[LEFT_EDGE], fb); |
1977 set_specifier_fallback (Vtoolbar_visible_p[RIGHT_TOOLBAR], fb); | 1989 set_specifier_fallback (Vtoolbar_visible_p[RIGHT_EDGE], fb); |
1978 | 1990 |
1979 DEFVAR_SPECIFIER ("toolbar-buttons-captioned-p", | 1991 DEFVAR_SPECIFIER ("toolbar-buttons-captioned-p", |
1980 &Vtoolbar_buttons_captioned_p /* | 1992 &Vtoolbar_buttons_captioned_p /* |
1981 *Whether the toolbar buttons are captioned. | 1993 *Whether the toolbar buttons are captioned. |
1982 This will only have a visible effect for those toolbar buttons which had | 1994 This will only have a visible effect for those toolbar buttons which had |