From: Eli Zaretskii <eliz@gnu.org>
To: Lars Magne Ingebrigtsen <larsi@gnus.org>
Cc: emacs-devel@gnu.org
Subject: Re: Errors in redisplay in eww
Date: Mon, 04 Jan 2016 21:09:40 +0200 [thread overview]
Message-ID: <83vb795fgr.fsf@gnu.org> (raw)
In-Reply-To: <m3io3bf2a3.fsf@gnus.org> (message from Lars Magne Ingebrigtsen on Sun, 03 Jan 2016 10:19:48 +0100)
> From: Lars Magne Ingebrigtsen <larsi@gnus.org>
> Cc: emacs-devel@gnu.org
> Date: Sun, 03 Jan 2016 10:19:48 +0100
>
> Eli Zaretskii <eliz@gnu.org> writes:
>
> >> > Hope you will be able to tell, or at least ask some questions that
> >> > will allow me to find that out.
> >>
> >> Is the `variable-pitch' face valid for you?
> >
> > Yes, both before and after visiting that URL.
>
> shr adds the colours (mostly) by using `add-face-text-property'. Could
> there be a bug somewhere in that code?
No, add-face-text-property and shr-colorize-region are not the
culprit, at least they don't seem to be. The problem is here:
(dolist (line lines)
(end-of-line)
(let ((start (point)))
(insert
line
(propertize " "
'display `(space :align-to (,pixel-align))
'face (and (> (length line) 0)
(shr-face-background
(get-text-property
(1- (length line)) 'face line)))
'shr-table-indent shr-table-id)
shr-table-vertical-line)
(shr-colorize-region
start (1- (point)) (nth 5 column) (nth 6 column)))
(forward-line 1))
shr-face-background returns nil when get-text-property returns just
variable-pitch, so we get 'face nil' in the properties, and the rest
is history.
Can you tell how come get-text-property returns something else in your
case? Where do the colors in the line's face come from? If they come
from shr-colorize-region, then I never see any fg color but nil there,
and bg is almost always nil, except when it's (:background "#ffffff").
HTH
next prev parent reply other threads:[~2016-01-04 19:09 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-12-29 15:52 Errors in redisplay in eww Eli Zaretskii
2015-12-29 16:16 ` Lars Ingebrigtsen
2015-12-29 17:53 ` Eli Zaretskii
2015-12-30 11:24 ` Lars Magne Ingebrigtsen
2015-12-30 16:06 ` Eli Zaretskii
2016-01-02 5:54 ` Lars Magne Ingebrigtsen
2016-01-02 8:41 ` Eli Zaretskii
2016-01-03 9:19 ` Lars Magne Ingebrigtsen
2016-01-04 19:09 ` Eli Zaretskii [this message]
2016-01-09 9:13 ` Lars Magne Ingebrigtsen
2016-01-09 9:46 ` Eli Zaretskii
2016-01-09 11:59 ` Lars Magne Ingebrigtsen
2016-02-04 3:25 ` Lars Ingebrigtsen
2015-12-30 14:00 ` Ivan Shmakov
2015-12-30 18:08 ` Eli Zaretskii
2016-01-02 23:40 ` Ivan Shmakov
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=83vb795fgr.fsf@gnu.org \
--to=eliz@gnu.org \
--cc=emacs-devel@gnu.org \
--cc=larsi@gnus.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 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.