From: Katsumi Yamaoka <yamaoka@jpl.org>
To: Richard Stallman <rms@gnu.org>
Cc: 21557@debbugs.gnu.org
Subject: bug#21557: 25.0.50; HTML renders text invisible
Date: Mon, 28 Sep 2015 15:43:16 +0900 [thread overview]
Message-ID: <b4mlhbrm4cb.fsf@jpl.org> (raw)
In-Reply-To: <E1ZfON4-0000Wr-HL@fencepost.gnu.org>
On Fri, 25 Sep 2015 04:28:46 -0400, Richard Stallman wrote:
> I received a message whose text was rendered as invisible when I
> viewed it in Rmail. I think it is because of 'color:#000'.
I tried this with the form below and found no problem. Increasing
the value of shr-color-visible-luminance-min raises the contrast.
> I think that if HTML specifies the same color for foreground and
> background, rendering should use different colors so that the text
> can be seen.
shr-color.el should do that. But if you have the fg color of
the variable-pitch face set (to #000), it will have no effect.
Because the new color that shr-color.el chooses is appended, not
prepended to the existing one:
(defun shr-colorize-region (start end fg &optional bg)
[...]
(add-face-text-property start end
(list :foreground (cadr new-colors))
t))
----------------------------------^
I'm not sure whether changing it to nil causes another problem.
My recipe:
emacs -Q -fg white -bg black
(let ((tmp (get-buffer-create "*tmp*")))
(require 'rmailmm)
(with-current-buffer tmp
(erase-buffer)
(insert (quoted-printable-decode-string "\
<html><body><span style=3D\"font-family:Verdana; color:#000; font-size:10pt;=
\"><div>Hi Jeanne</div><div><br></div><div>I know I gave you an address for =
the books to be sent. I am sending you an address at Kent for the books to =
be sent. It makes more sense for the books to be sent there:<br></div><div>=
<br></div></span></body></html>
"))
(insert (prog1
(with-temp-buffer
(rmail-mime-render-html-shr tmp)
(buffer-string))
(erase-buffer)))
(display-buffer tmp)))
next prev parent reply other threads:[~2015-09-28 6:43 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-25 8:28 bug#21557: 25.0.50; HTML renders text invisible Richard Stallman
2015-09-28 6:43 ` Katsumi Yamaoka [this message]
2015-09-28 7:31 ` Eli Zaretskii
2015-09-28 8:04 ` Katsumi Yamaoka
2015-09-28 8:40 ` Eli Zaretskii
2015-09-28 10:37 ` Katsumi Yamaoka
2015-09-28 13:14 ` Eli Zaretskii
2015-09-28 19:09 ` Richard Stallman
2015-09-29 2:02 ` Katsumi Yamaoka
2015-09-28 23:02 ` Katsumi Yamaoka
2015-09-29 5:10 ` Eli Zaretskii
2015-09-29 6:32 ` Katsumi Yamaoka
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=b4mlhbrm4cb.fsf@jpl.org \
--to=yamaoka@jpl.org \
--cc=21557@debbugs.gnu.org \
--cc=rms@gnu.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.