Commit 43281ee3 authored by Gerd Moellmann's avatar Gerd Moellmann
Browse files

(x_estimate_mode_line_height): If `mode-line' face

hasn't a font, use that of the frame, as drawing glyphs
does.
parent 4dd4cc14
......@@ -2326,7 +2326,7 @@ x_estimate_mode_line_height (f, face_id)
struct frame *f;
enum face_id face_id;
{
int height = 1;
int height = FONT_HEIGHT (FRAME_FONT (f));
/* This function is called so early when Emacs starts that the face
cache and mode line face are not yet initialized. */
......@@ -2334,7 +2334,11 @@ x_estimate_mode_line_height (f, face_id)
{
struct face *face = FACE_FROM_ID (f, face_id);
if (face)
height = FONT_HEIGHT (face->font) + 2 * face->box_line_width;
{
if (face->font)
height = FONT_HEIGHT (face->font);
height += 2 * face->box_line_width;
}
}
return height;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment