comparison src/frame.c @ 406:b8cc9ab3f761 r21-2-33

Import from CVS: tag r21-2-33
author cvs
date Mon, 13 Aug 2007 11:17:09 +0200
parents 2f8bb876ab1d
children 501cfd01ee6d
comparison
equal deleted inserted replaced
405:0e08f63c74d2 406:b8cc9ab3f761
2262 2262
2263 width Width of the frame, in characters. 2263 width Width of the frame, in characters.
2264 2264
2265 minibuffer Gives the minibuffer behavior for this frame. Either 2265 minibuffer Gives the minibuffer behavior for this frame. Either
2266 t (frame has its own minibuffer), `only' (frame is 2266 t (frame has its own minibuffer), `only' (frame is
2267 a minibuffer-only frame), or a window (frame uses that 2267 a minibuffer-only frame), `none' (frame has no minibuffer)
2268 window, which is on another frame, as the minibuffer). 2268 or a window (frame uses that window, which is on another
2269 frame, as the minibuffer).
2269 2270
2270 unsplittable If non-nil, frame cannot be split by `display-buffer'. 2271 unsplittable If non-nil, frame cannot be split by `display-buffer'.
2271 2272
2272 current-display-table, menubar-visible-p, left-margin-width, 2273 current-display-table, menubar-visible-p, left-margin-width,
2273 right-margin-width, minimum-line-ascent, minimum-line-descent, 2274 right-margin-width, minimum-line-ascent, minimum-line-descent,
2277 bottom-toolbar-height, left-toolbar-width, right-toolbar-width, 2278 bottom-toolbar-height, left-toolbar-width, right-toolbar-width,
2278 default-toolbar-visible-p, top-toolbar-visible-p, bottom-toolbar-visible-p, 2279 default-toolbar-visible-p, top-toolbar-visible-p, bottom-toolbar-visible-p,
2279 left-toolbar-visible-p, right-toolbar-visible-p, toolbar-buttons-captioned-p, 2280 left-toolbar-visible-p, right-toolbar-visible-p, toolbar-buttons-captioned-p,
2280 top-toolbar-border-width, bottom-toolbar-border-width, 2281 top-toolbar-border-width, bottom-toolbar-border-width,
2281 left-toolbar-border-width, right-toolbar-border-width, 2282 left-toolbar-border-width, right-toolbar-border-width,
2282 modeline-shadow-thickness, has-modeline-p 2283 modeline-shadow-thickness, has-modeline-p,
2284 default-gutter, top-gutter, bottom-gutter, left-gutter, right-gutter,
2285 default-gutter-height, default-gutter-width, top-gutter-height,
2286 bottom-gutter-height, left-gutter-width, right-gutter-width,
2287 default-gutter-visible-p, top-gutter-visible-p, bottom-gutter-visible-p,
2288 left-gutter-visible-p, right-gutter-visible-p, top-gutter-border-width,
2289 bottom-gutter-border-width, left-gutter-border-width, right-gutter-border-width,
2283 [Giving the name of any built-in specifier variable is 2290 [Giving the name of any built-in specifier variable is
2284 equivalent to calling `set-specifier' on the specifier, 2291 equivalent to calling `set-specifier' on the specifier,
2285 with a locale of FRAME. Giving the name to `frame-property' 2292 with a locale of FRAME. Giving the name to `frame-property'
2286 calls `specifier-instance' on the specifier.] 2293 calls `specifier-instance' on the specifier.]
2287 2294
2869 + FRAME_THEORETICAL_BOTTOM_TOOLBAR_HEIGHT (f) 2876 + FRAME_THEORETICAL_BOTTOM_TOOLBAR_HEIGHT (f)
2870 + 2 * FRAME_THEORETICAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f) 2877 + 2 * FRAME_THEORETICAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f)
2871 - FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f) 2878 - FRAME_REAL_BOTTOM_TOOLBAR_HEIGHT (f)
2872 - 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f); 2879 - 2 * FRAME_REAL_BOTTOM_TOOLBAR_BORDER_WIDTH (f);
2873 2880
2874 new_pixheight -=
2875 (FRAME_TOP_GUTTER_BOUNDS (f) + FRAME_BOTTOM_GUTTER_BOUNDS (f));
2876
2877 new_pixwidth += 2881 new_pixwidth +=
2878 + FRAME_THEORETICAL_LEFT_TOOLBAR_WIDTH (f) 2882 + FRAME_THEORETICAL_LEFT_TOOLBAR_WIDTH (f)
2879 + 2 * FRAME_THEORETICAL_LEFT_TOOLBAR_BORDER_WIDTH (f) 2883 + 2 * FRAME_THEORETICAL_LEFT_TOOLBAR_BORDER_WIDTH (f)
2880 - FRAME_REAL_LEFT_TOOLBAR_WIDTH (f) 2884 - FRAME_REAL_LEFT_TOOLBAR_WIDTH (f)
2881 - 2 * FRAME_REAL_LEFT_TOOLBAR_BORDER_WIDTH (f); 2885 - 2 * FRAME_REAL_LEFT_TOOLBAR_BORDER_WIDTH (f);
2883 new_pixwidth += 2887 new_pixwidth +=
2884 + FRAME_THEORETICAL_RIGHT_TOOLBAR_WIDTH (f) 2888 + FRAME_THEORETICAL_RIGHT_TOOLBAR_WIDTH (f)
2885 + 2 * FRAME_THEORETICAL_RIGHT_TOOLBAR_BORDER_WIDTH (f) 2889 + 2 * FRAME_THEORETICAL_RIGHT_TOOLBAR_BORDER_WIDTH (f)
2886 - FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f) 2890 - FRAME_REAL_RIGHT_TOOLBAR_WIDTH (f)
2887 - 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f); 2891 - 2 * FRAME_REAL_RIGHT_TOOLBAR_BORDER_WIDTH (f);
2888
2889 new_pixwidth -=
2890 (FRAME_LEFT_GUTTER_BOUNDS (f) + FRAME_RIGHT_GUTTER_BOUNDS (f));
2891 2892
2892 /* Adjust the width for the end glyph which may be a different width 2893 /* Adjust the width for the end glyph which may be a different width
2893 than the default character width. */ 2894 than the default character width. */
2894 { 2895 {
2895 int adjustment, trunc_width, cont_width; 2896 int adjustment, trunc_width, cont_width;
2908 if (!new_pixheight && !new_pixwidth) 2909 if (!new_pixheight && !new_pixwidth)
2909 return; 2910 return;
2910 2911
2911 if (new_pixheight) 2912 if (new_pixheight)
2912 { 2913 {
2914 /* Adjust for gutters here so that we always get set
2915 properly. */
2916 new_pixheight -=
2917 (FRAME_TOP_GUTTER_BOUNDS (f)
2918 + FRAME_BOTTOM_GUTTER_BOUNDS (f));
2919
2913 XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_top 2920 XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_top
2914 = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f); 2921 = FRAME_TOP_BORDER_END (f) + FRAME_TOP_GUTTER_BOUNDS (f);
2915 2922
2916 if (FRAME_HAS_MINIBUF_P (f) 2923 if (FRAME_HAS_MINIBUF_P (f)
2917 && ! FRAME_MINIBUF_ONLY_P (f)) 2924 && ! FRAME_MINIBUF_ONLY_P (f))
2953 f->pixheight = newheight; 2960 f->pixheight = newheight;
2954 } 2961 }
2955 2962
2956 if (new_pixwidth) 2963 if (new_pixwidth)
2957 { 2964 {
2965 /* Adjust for gutters here so that we always get set
2966 properly. */
2967 new_pixwidth -=
2968 (FRAME_LEFT_GUTTER_BOUNDS (f)
2969 + FRAME_RIGHT_GUTTER_BOUNDS (f));
2970
2958 XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_left = 2971 XWINDOW (FRAME_ROOT_WINDOW (f))->pixel_left =
2959 FRAME_LEFT_BORDER_END (f) + FRAME_LEFT_GUTTER_BOUNDS (f); 2972 FRAME_LEFT_BORDER_END (f) + FRAME_LEFT_GUTTER_BOUNDS (f);
2960 set_window_pixwidth (FRAME_ROOT_WINDOW (f), new_pixwidth, 0); 2973 set_window_pixwidth (FRAME_ROOT_WINDOW (f), new_pixwidth, 0);
2961 2974
2962 if (FRAME_HAS_MINIBUF_P (f)) 2975 if (FRAME_HAS_MINIBUF_P (f))