From: a machine of awareness <machine.of.awareness@gmail.com>
To: emacs-orgmode@gnu.org
Subject: how export highlight code
Date: Sun, 18 Sep 2011 10:20:41 +0800 [thread overview]
Message-ID: <874o0awpza.fsf@gmail.com> (raw)
I'm using org-mode v7.01g.
I've tried to export a code block like this:
#+BEGIN_SRC c -n
static void doData()
{
if (_pStatus->switchChange>0x00)
{
_pStatus->switchChange = 0x00;
_pStatus->workStatus = DATABASE_PRO_WOR_WAIT;
return;
}
...
}
#+END_SRC
The result html doesn't highlight the code. Instead it gives me:
<pre class="example"><span class="linenr"> 1: </span>
<span class="linenr"> 2: </span>static void doData()
<span class="linenr"> 3: </span>{
<span class="linenr"> 5: </span> if (_pStatus->switchChange>0x00)
<span class="linenr"> 6: </span> {
<span class="linenr"> 7: </span> _pStatus->switchChange = 0x00;
<span class="linenr"> 9: </span> _pStatus->workStatus = DATABASE_PRO_WOR_WAIT;
<span class="linenr">10: </span> return;
<span class="linenr">11: </span> }
<span class="linenr">12: </span> ...
<span class="linenr">13: </span>}
</pre>
And I have not changed any option related to org-babel or the exporting function.
So how can I make the syntax highlighting work for exporting to html?
--
a machine of awareness
Debian、Emacs+Gnus
next reply other threads:[~2011-09-18 2:30 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-18 2:20 a machine of awareness [this message]
2011-09-18 2:35 ` how export highlight code Jambunathan K
2011-09-20 13:33 ` a machine of awareness
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=874o0awpza.fsf@gmail.com \
--to=machine.of.awareness@gmail.com \
--cc=emacs-orgmode@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.