From: Avdi Grimm <firstname.lastname@example.org>
To: emacs-orgmode <email@example.com>
Subject: Re: HTML Syntax Highlighting Questions
Date: Wed, 8 Jun 2011 21:45:25 -0400 [thread overview]
Message-ID: <BANLkTi=AUJy8YLXLde7Xu3JsX7JZz8hwBw@mail.gmail.com> (raw)
On Sun, May 29, 2011 at 8:50 PM, Avdi Grimm <firstname.lastname@example.org> wrote:
> How do I control syntax highlighting in HTML export? Specifically, how can I:
> A. Disable syntax highlighting entirely
> B. Switch from inline colors to semantic tagging that I can style with
> a stylesheet? I could swear that I've seen instructions about this
> somewhere in the past.
Aha! I revisited this question, and I found the relevant setting:
From the docs:
Output type to be used by htmlize when formatting code snippets.
Choices are `css', to export the CSS selectors only, or `inline-css', to
export the CSS attribute values inline in the HTML. We use as default
`inline-css', in order to make the resulting HTML self-containing.
However, this will fail when using Emacs in batch mode for export, because
then no rich font definitions are in place. It will also not be good if
people with different Emacs setup contribute HTML files to a website,
because the fonts will represent the individual setups. In these cases,
it is much better to let Org/Htmlize assign classes only, and to use
a style file to define the look of these classes.
To get a start for your css file, start Emacs session and make sure that
all the faces you are interested in are defined, for example by loading files
in all modes you want. Then, use the command
M-x org-export-htmlize-generate-css to extract class definitions.
prev parent reply other threads:[~2011-06-09 1:45 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-30 0:50 HTML Syntax Highlighting Questions Avdi Grimm
2011-05-30 1:32 ` Jambunathan K
2011-05-30 2:25 ` Avdi Grimm
2011-05-30 3:20 ` Jambunathan K
2011-05-30 4:47 ` Puneeth Chaganti
2011-06-09 1:45 ` Avdi Grimm [this message]
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:
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
* 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
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).