Subject: Re: bug#30609: 26.0.91; underline should be drawn behind text

From: Aaron Jensen <[email-masked]>
Date: Mon, 26 Feb 2018 13:10:06 -0800

On Mon, Feb 26, 2018 at 7:46 AM, Eli Zaretskii <[email-masked]> wrote:
> Yes, this is what I feared, and that's why I think simply switching
> the order will not give good results.

I may be able to move the text decoration code to the font drawing,
but text decoration is done for more than fonts, so that could result
in some duplication or nsterm referencing nsfont which would then
reference nsterm. If that's ok, I can look into that.

The other option would be to move the background drawing code out of
the font rendering. I don't know all of the places that it is done, so
that may be cumbersome.

One other, completely different idea that may not work or may be
really slow would be to do a color replacement--only replacing pixels
that match the background color with the underline color. I have no
idea if reading from the canvas in this way is slow. This would end up
giving a similar effect to text-decoration-skip.