unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Fabrice Niessen <fni-news@pirilampo.org>
Cc: 20510@debbugs.gnu.org
Subject: bug#20510: 25.0.50; Underscore hidden by underline
Date: Wed, 06 May 2015 22:21:31 +0300	[thread overview]
Message-ID: <83k2wlqzpg.fsf@gnu.org> (raw)
In-Reply-To: <86r3qtcz0f.fsf@example.com>

> From: Fabrice Niessen <fni-news@pirilampo.org>
> Cc: 20510@debbugs.gnu.org
> Date: Wed, 06 May 2015 21:00:16 +0200
> 
> I mean: can't the hl-line-mode code be written in a way that the
> underline goes in the background of the character, that is that every
> pixel of every character gets written "over" the underline line?

hl-line-mode cannot control that, and nothing on the Lisp level can.

When hl-line-mode puts its overlay on a line, the characters of that
line have the hl-line face merged with their face, with the result
that each character of that line will have the underline face in the
color you specify.  That's all Lisp can do; then along comes the
display engine and redraws the characters in this new merged face.
The C code which draws characters is written so that we first draw the
background, then the characters, then the underline.

So what you are actually asking is that the order of drawing the
underline (and also overline, strike-through, etc.) is changed so that
these attributes are drawn _before_ the characters.  That should be
possible by changing the order in the C code, but I have no idea what
that will do in other situations.  It's probably not TRT at least when
we draw images and other similar stuff instead of characters.

Perhaps someone who knows more than I do about GUI display back-end
could tell if this is a safe change.





  reply	other threads:[~2015-05-06 19:21 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-05-05 20:13 bug#20510: 25.0.50; Underscore hidden by underline Fabrice Niessen
2015-05-06 17:13 ` Eli Zaretskii
     [not found]   ` <83mw1hr5nc.fsf-mXXj517/zsQ@public.gmane.org>
2015-05-06 19:00     ` Fabrice Niessen
2015-05-06 19:21       ` Eli Zaretskii [this message]
2019-09-30  0:10 ` Stefan Kangas
2019-09-30  6:39   ` Eli Zaretskii

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

  List information: https://www.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83k2wlqzpg.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=20510@debbugs.gnu.org \
    --cc=fni-news@pirilampo.org \
    /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 public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).