From: Eli Zaretskii <eliz@gnu.org>
To: Lars Ingebrigtsen <larsi@gnus.org>
Cc: rpluim@gmail.com, emacs-devel@gnu.org
Subject: Re: Crash with --enable-checking and some glyphs
Date: Fri, 26 Nov 2021 17:00:29 +0200 [thread overview]
Message-ID: <838rxb2c8i.fsf@gnu.org> (raw)
In-Reply-To: <87mtlrt2ei.fsf@gnus.org> (message from Lars Ingebrigtsen on Fri, 26 Nov 2021 15:30:45 +0100)
> From: Lars Ingebrigtsen <larsi@gnus.org>
> Cc: rpluim@gmail.com, emacs-devel@gnu.org
> Date: Fri, 26 Nov 2021 15:30:45 +0100
>
> (gdb) p it->what
> $1 = IT_CHARACTER
> (gdb) p/x it->c
> $2 = 0xace0
> (gdb) pgrowx it->glyph_row
> TEXT: 2 glyphs
> 0 0: CHAR[^] pos=1 blev=0,btyp=L w=22 a+d=35+9 MB
> 1 22: CHAR[0xace0] pos=2 blev=0,btyp=L w=24 a+d=25+-1 face=21 MB
OK, so the glyph for this character, U+ACE0, comes out with a negative
descent value of -1.
Please run Emacs again, under GDB, with a breakpoint like this:
(gdb) break xdisp.c:30866 if it->c == 0xace0
The breakpoint should be on the line shown with "<<<<" below:
void
gui_produce_glyphs (struct it *it)
{
int extra_line_spacing = it->extra_line_spacing;
it->glyph_not_available_p = false;
if (it->what == IT_CHARACTER)
{
unsigned char2b;
struct face *face = FACE_FROM_ID (it->f, it->face_id);
struct font *font = face->font;
struct font_metrics *pcm = NULL;
int boff; /* Baseline offset. */
if (font == NULL) <<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
{
/* When no suitable font is found, display this character by
the method specified in the first extra slot of
Vglyphless_char_display. */
Lisp_Object acronym = lookup_glyphless_char_display (-1, it);
Then step with the "next" command through the code there, and see
where it->descent gets its negative value. In particular, when you
get to this part:
if (get_char_glyph_code (it->char_to_display, font, &char2b))
{
pcm = get_per_char_metric (font, &char2b);
if (pcm->width == 0
&& pcm->rbearing == 0 && pcm->lbearing == 0)
pcm = NULL;
}
if (pcm)
{
it->phys_ascent = pcm->ascent + boff;
it->phys_descent = pcm->descent - boff;
it->pixel_width = pcm->width;
please tell what are the values of pcm->ascent and pcm->descent.
I want to know whether the font is the culprit or some code of ours
overrides the value from the font. Then we can devise the solution.
Thanks.
next prev parent reply other threads:[~2021-11-26 15:00 UTC|newest]
Thread overview: 130+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-11-24 13:53 Proportional fonts in the mode line (one month test) Lars Ingebrigtsen
2021-11-24 13:54 ` Lars Ingebrigtsen
2021-11-24 14:12 ` Lars Ingebrigtsen
2021-11-24 14:16 ` Lars Ingebrigtsen
2021-11-24 14:42 ` Eli Zaretskii
2021-11-24 14:46 ` Lars Ingebrigtsen
2021-11-24 14:54 ` Eli Zaretskii
2021-11-24 15:00 ` Lars Ingebrigtsen
2021-11-24 15:12 ` Lars Ingebrigtsen
2021-11-24 17:01 ` Crash with --enable-checking and some glyphs Lars Ingebrigtsen
2021-11-24 17:55 ` Robert Pluim
2021-11-25 12:51 ` Lars Ingebrigtsen
2021-11-25 13:09 ` Andreas Schwab
2021-11-25 13:39 ` Lars Ingebrigtsen
2021-11-25 14:36 ` Robert Pluim
2021-11-25 14:39 ` Lars Ingebrigtsen
2021-11-25 14:51 ` Lars Ingebrigtsen
2021-11-25 15:02 ` Gregory Heytings
2021-11-25 15:11 ` Lars Ingebrigtsen
2021-11-25 15:36 ` Gregory Heytings
2021-11-25 16:03 ` Lars Ingebrigtsen
2021-11-25 16:18 ` Gregory Heytings
2021-11-26 12:14 ` Lars Ingebrigtsen
2021-11-25 15:14 ` Eli Zaretskii
2021-11-26 12:18 ` Lars Ingebrigtsen
2021-11-26 12:50 ` Eli Zaretskii
2021-11-26 14:30 ` Lars Ingebrigtsen
2021-11-26 15:00 ` Eli Zaretskii [this message]
2021-11-26 15:04 ` Lars Ingebrigtsen
2021-11-26 16:27 ` Eli Zaretskii
2021-11-27 8:37 ` Eli Zaretskii
2021-11-27 14:04 ` Lars Ingebrigtsen
2021-11-27 15:12 ` Eli Zaretskii
2021-11-27 15:25 ` Lars Ingebrigtsen
2021-11-28 0:41 ` Po Lu
2021-11-27 21:28 ` Gregory Heytings
2021-11-27 21:31 ` Lars Ingebrigtsen
2021-11-27 22:01 ` Gregory Heytings
2021-11-28 7:21 ` Eli Zaretskii
2021-11-29 13:55 ` Gregory Heytings
2021-11-29 14:01 ` Lars Ingebrigtsen
2021-11-25 15:23 ` Óscar Fuentes
2021-11-25 21:29 ` Gregor Zattler
2021-11-26 13:01 ` Po Lu
2021-11-27 0:18 ` Po Lu
2021-11-24 18:49 ` Proportional fonts in the mode line (one month test) Uwe Brauer
2021-11-24 19:12 ` Lars Ingebrigtsen
2021-11-24 19:44 ` Eli Zaretskii
2021-11-25 0:52 ` Po Lu
2021-11-25 12:42 ` Lars Ingebrigtsen
2021-11-25 12:41 ` Lars Ingebrigtsen
2021-11-25 1:01 ` Po Lu
2021-11-24 14:40 ` Eli Zaretskii
2021-11-24 14:44 ` Manuel Uberti
2021-11-24 16:25 ` Yuri D'Elia
2021-11-24 16:38 ` Óscar Fuentes
2021-11-24 16:50 ` Yuan Fu
2021-11-24 17:09 ` Óscar Fuentes
2021-11-24 17:18 ` Lars Ingebrigtsen
2021-11-24 17:26 ` Yuan Fu
2021-11-24 17:18 ` Yuan Fu
2021-11-24 16:49 ` Yuan Fu
2021-11-24 16:55 ` Lars Ingebrigtsen
2021-11-24 17:32 ` Yuan Fu
2021-11-24 16:51 ` Dmitry Gutov
2021-11-24 16:58 ` Yuan Fu
2021-11-24 17:22 ` Eli Zaretskii
2021-11-24 17:26 ` Lars Ingebrigtsen
2021-11-24 17:54 ` Eli Zaretskii
2021-11-24 17:58 ` Lars Ingebrigtsen
2021-11-24 18:42 ` Eli Zaretskii
2021-11-25 12:37 ` Lars Ingebrigtsen
2021-11-25 13:15 ` Eli Zaretskii
2021-11-24 17:55 ` Lars Ingebrigtsen
2021-11-24 18:57 ` Manuel Uberti
2021-11-25 12:39 ` Lars Ingebrigtsen
2021-11-25 14:04 ` Manuel Uberti
2021-11-25 22:20 ` Tim Cross
2021-11-24 19:20 ` Dmitry Gutov
2021-11-24 16:51 ` Filipp Gunbin
2021-11-24 17:36 ` [External] : " Drew Adams
2021-11-24 17:39 ` Lars Ingebrigtsen
2021-11-25 0:18 ` Po Lu
2021-11-25 0:39 ` Po Lu
2021-11-25 1:48 ` Jim Porter
2021-11-25 13:29 ` Lars Ingebrigtsen
2021-11-25 14:03 ` Eli Zaretskii
2021-11-25 19:41 ` Jim Porter
2021-11-25 23:04 ` Kévin Le Gouguec
2021-11-26 2:44 ` Jim Porter
2021-11-26 17:07 ` Yuan Fu
2021-11-27 0:18 ` Po Lu
2021-11-26 4:53 ` Yuri Khan
2021-11-26 5:04 ` Po Lu
2021-11-26 12:35 ` Lars Ingebrigtsen
2021-11-27 21:50 ` Jim Porter
2021-11-25 7:45 ` Eli Zaretskii
2021-11-25 7:59 ` Po Lu
2021-11-25 13:28 ` Lars Ingebrigtsen
2021-11-25 13:34 ` Eli Zaretskii
2021-11-25 14:05 ` Lars Ingebrigtsen
2021-11-26 13:19 ` Lars Ingebrigtsen
2021-11-25 6:26 ` Protesilaos Stavrou
2021-11-25 8:03 ` Eli Zaretskii
2021-11-25 9:00 ` Gregory Heytings
2021-11-25 13:33 ` Lars Ingebrigtsen
2021-11-25 9:06 ` Simen Heggestøyl
2021-11-25 13:33 ` Lars Ingebrigtsen
2021-11-25 14:17 ` Lars Ingebrigtsen
2021-11-29 14:52 ` Michael Welsh Duggan
2021-11-29 15:03 ` Eli Zaretskii
2021-11-29 15:11 ` Lars Ingebrigtsen
2021-12-01 5:59 ` Jim Porter
2021-12-01 8:26 ` Davide Masserut
2021-12-01 12:30 ` Eric S Fraga
2021-12-01 13:41 ` Lars Ingebrigtsen
2021-12-01 13:46 ` Eric S Fraga
2021-12-01 13:54 ` Lars Ingebrigtsen
2021-12-01 14:19 ` Eric S Fraga
2021-12-01 14:40 ` Eli Zaretskii
2021-12-01 14:45 ` Eric S Fraga
2021-12-03 3:09 ` João Pedro de Amorim Paula
2021-12-03 11:45 ` Eric S Fraga
2021-12-04 5:41 ` Richard Stallman
2021-12-04 6:24 ` Po Lu
2021-12-05 13:04 ` Eric S Fraga
2021-12-05 20:46 ` James Cloos
2021-12-05 22:06 ` João Pedro de Amorim Paula
2021-12-01 15:00 ` Yuri Khan
2021-12-01 15:08 ` Eric S Fraga
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=838rxb2c8i.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=larsi@gnus.org \
--cc=rpluim@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.