#include "window.h"
#include "elhash.h"
#include "commands.h"
+#include "gutter.h"
Lisp_Object Qwindowp, Qwindow_live_p, Qwindow_configurationp;
Lisp_Object Qscroll_up, Qscroll_down, Qdisplay_buffer;
return window_is_leftmost (w) && window_is_rightmost (w);
}
-static int
+int
window_is_highest (struct window *w)
{
Lisp_Object parent, current_ancestor, window;
return 0;
}
-static int
+int
window_is_lowest (struct window *w)
{
Lisp_Object parent, current_ancestor, window;
return margin_width_internal (w, 0);
}
-static int
-window_top_toolbar_height (struct window *w)
-{
- /* #### implement this shit. */
- return 0;
-}
-
-/* #### Currently used in scrollbar.c. Does it actually need to be? */
-int
-window_bottom_toolbar_height (struct window *w)
-{
- return 0;
-}
-
-static int
-window_left_toolbar_width (struct window *w)
-{
- return 0;
-}
-
-static int
-window_right_toolbar_width (struct window *w)
-{
- return 0;
-}
-
/*****************************************************************************
Window Gutters
int
window_top_gutter_height (struct window *w)
{
- int toolbar_height = window_top_toolbar_height (w);
+ int gutter = WINDOW_REAL_TOP_GUTTER_BOUNDS (w);
if (!NILP (w->hchild) || !NILP (w->vchild))
return 0;
#ifdef HAVE_SCROLLBARS
if (!NILP (w->scrollbar_on_top_p))
- return window_scrollbar_height (w) + toolbar_height;
+ return window_scrollbar_height (w) + gutter;
else
#endif
- return toolbar_height;
+ return gutter;
}
int
window_bottom_gutter_height (struct window *w)
{
- int other_height;
+ int gutter = WINDOW_REAL_BOTTOM_GUTTER_BOUNDS (w);
if (!NILP (w->hchild) || !NILP (w->vchild))
return 0;
- else
- other_height =
- window_modeline_height (w) + window_bottom_toolbar_height (w);
+
+ gutter += window_modeline_height (w);
#ifdef HAVE_SCROLLBARS
if (NILP (w->scrollbar_on_top_p))
- return window_scrollbar_height (w) + other_height;
+ return window_scrollbar_height (w) + gutter;
else
#endif
- return other_height;
+ return gutter;
}
int
window_left_gutter_width (struct window *w, int modeline)
{
- int gutter = window_left_toolbar_width (w);
+ int gutter = WINDOW_REAL_LEFT_GUTTER_BOUNDS (w);
if (!NILP (w->hchild) || !NILP (w->vchild))
return 0;
-
#ifdef HAVE_SCROLLBARS
if (!modeline && !NILP (w->scrollbar_on_left_p))
gutter += window_scrollbar_width (w);
int
window_right_gutter_width (struct window *w, int modeline)
{
- int gutter = window_right_toolbar_width (w);
+ int gutter = WINDOW_REAL_RIGHT_GUTTER_BOUNDS (w);
if (!NILP (w->hchild) || !NILP (w->vchild))
return 0;
SET_LAST_MODIFIED (w, 0);
SET_LAST_FACECHANGE (w);
MARK_FRAME_WINDOWS_STRUCTURE_CHANGED (f);
+ /* overkill maybe, but better to be correct */
+ MARK_FRAME_GUTTERS_CHANGED (f);
}
#undef MINSIZE
#undef CURBEG