emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: master f1baa15: Fix display when a font claims large values of ascen


From: Glenn Morris
Subject: Re: master f1baa15: Fix display when a font claims large values of ascent and descent
Date: Mon, 08 Jun 2015 13:44:40 -0400
User-agent: Gnus (www.gnus.org), GNU Emacs (www.gnu.org/software/emacs/)

Eli Zaretskii wrote:

> branch: master
> commit f1baa156503f089d6627171e0e9ad73bbdbb7268
[...]
> @@ -19188,6 +19200,23 @@ append_space_for_newline (struct it *it, bool 
> default_face_p)
>  
>         PRODUCE_GLYPHS (it);
>  
> +       /* Make sure this space glyph has the right ascent and
> +          descent values, or else cursor at end of line will look
> +          funny.  */
> +       g = it->glyph_row->glyphs[TEXT_AREA] + n;
> +       struct font *font = face->font ? face->font : FRAME_FONT (it->f);
> +       if (n == 0 || it->glyph_row->height < font->pixel_size)
> +         {
> +           normal_char_ascent_descent (font, -1, &it->ascent, &it->descent);
> +           it->max_ascent = it->ascent;
> +           it->max_descent = it->descent;
> +           /* Make sure compute_line_metrics recomputes the row height.  */
> +           it->glyph_row->height = 0;
> +         }
> +
> +       g->ascent = it->max_ascent;
> +       g->descent = it->max_descent;
> +

This bit causes a warning in without-x builds, eg
http://hydra.nixos.org/build/23007744/log/raw

xdisp.c:19210:8: warning: implicit declaration of function
'normal_char_ascent_descent' [-Wimplicit-function-declaration]
        normal_char_ascent_descent (font, -1, &it->ascent, &it->descent);



reply via email to

[Prev in Thread] Current Thread [Next in Thread]