From: raman@google.com (T.V Raman)
To: vibhavp@gmail.com
Cc: emacs-devel@gnu.org, raman@google.com
Subject: Re: EWW/SHR Feature Request
Date: Fri, 21 Mar 2014 11:36:43 -0700 [thread overview]
Message-ID: <21292.34491.425345.339570@retriever.mtv.corp.google.com> (raw)
In-Reply-To: <CA+T2Sh0pzuP=hmn8+eCRDKbBtWrjvryT4ON1S9CmcXsXw4kSCg@mail.gmail.com>
I mean the following:
(shr-format-html-string "<bo>Strong</b>")
Returns a string with the font face set to 'bold or whatever else
shr chooses to use.
Here is the code I have in emacspeak:
(defun emacspeak-webutils-html-string (html-string)
"Return formatted string."
(or (require 'shr) (error "Need emacs 24.4"))
(with-temp-buffer "*html-format*"
(setq buffer-undo-list t)
(insert html-string)
(shr-render-region (point-min) (point-max))
(buffer-string)))
Vibhav Pant writes:
> On Fri, Mar 21, 2014 at 9:14 PM, T. V. Raman <raman@google.com> wrote:
> > Now that we have shr and eww, it would be nice to have a function
> > that takes an html string and returns a formatted representation
> > (replete with properties etc.) something like
> > (shr-format-html-string html-string) -> Return: Formatted string
> > suitable for insertion into a buffer.
>
> By formatted string, do you mean the entire content of the page to
> which the address redirects too, or the webpage title?
>
> --
> Vibhav Pant
> vibhavp@gmail.com
next prev parent reply other threads:[~2014-03-21 18:36 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-21 15:44 EWW/SHR Feature Request T. V. Raman
2014-03-21 16:48 ` Nicolas Richard
2014-03-21 18:04 ` Vibhav Pant
2014-03-21 18:36 ` T.V Raman [this message]
2014-03-21 21:03 ` Lars Magne Ingebrigtsen
2014-03-22 10:22 ` Willem Rein Oudshoorn
2016-07-14 2:44 ` raman
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=21292.34491.425345.339570@retriever.mtv.corp.google.com \
--to=raman@google.com \
--cc=emacs-devel@gnu.org \
--cc=vibhavp@gmail.com \
/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).