GNU bug report logs -
#30553
26.0.91; underline appears beneath line-spacing rather than beneath text
Previous Next
Reported by: Aaron Jensen <aaronjensen <at> gmail.com>
Date: Tue, 20 Feb 2018 18:18:02 UTC
Severity: minor
Found in version 26.0.91
Done: Eli Zaretskii <eliz <at> gnu.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
> From: Aaron Jensen <aaronjensen <at> gmail.com>
> Date: Tue, 27 Feb 2018 06:19:00 -0800
> Cc: Alp Aker <alptekin.aker <at> gmail.com>, 30553 <at> debbugs.gnu.org
>
> Patch for buffer local underline position variables. I ended up making
> underline-minimum-offset buffer local capable as well.
Does that mean that underline-minimum-offset allows you to avoid
problems with underline overwriting the descents?
> + unsigned long minimum_offset =
> + buffer_local_value (Qunderline_minimum_offset, s->w->contents);
This isn't right. buffer_local_value returns a Lisp object, not an
integer, so you need to convert it to an integer (or a boolean for
other variables). And it can also return the symbol Qunbound, in
which case we need a fallback. So we need something like
Lisp_Object val = buffer_local_value (Qunderline_minimum_offset,
s->w->contents);
if (INTEGERP (val))
minimum_offset = XFASTINT (val);
else
minimum_offset = 1;
and similarly with other variables (except that a boolean variable
will return a value of Qt or Qnil, not a number).
> + DEFSYM (Qunderline_minimum_offset, "underline-minimum-offset");
I think this symbol should be in xdisp.c, where the variable is
defined.
This bug report was last modified 7 years and 77 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.