* Syntax highlighting in published output
@ 2009-01-25 15:16 Jan Seeger
2009-01-25 15:59 ` Eric Schulte
0 siblings, 1 reply; 2+ messages in thread
From: Jan Seeger @ 2009-01-25 15:16 UTC (permalink / raw)
To: Org Mode List
Hello List!
I was just wondering if org-mode can do (programming language) syntax highlighting like muse
when publishing to HTML or similar. If yes, how?
Greetings,
Jan
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Syntax highlighting in published output
2009-01-25 15:16 Syntax highlighting in published output Jan Seeger
@ 2009-01-25 15:59 ` Eric Schulte
0 siblings, 0 replies; 2+ messages in thread
From: Eric Schulte @ 2009-01-25 15:59 UTC (permalink / raw)
To: Jan Seeger; +Cc: Org Mode List
Jan Seeger <jan.seeger@thenybble.de> writes:
> Hello List!
>
> I was just wondering if org-mode can do (programming language) syntax highlighting like muse
> when publishing to HTML or similar. If yes, how?
>
Hi Jan,
If you would like to include an entire file as highlighted html you can
use the include directive as described here
http://orgmode.org/manual/Include-files.html
If you just want to highlight a small snippet of code you can place the
code in a source code block as follows
--8<---------------cut here---------------start------------->8---
#+begin_src emacs-lisp
(defun foo (a b)
(if (> a b)
(* a b)
(foo (foo (- b a) a) (- a b))))
#+end_src
--8<---------------cut here---------------end--------------->8---
Best -- Eric
>
> Greetings,
> Jan
>
>
> _______________________________________________
> Emacs-orgmode mailing list
> Remember: use `Reply All' to send replies to the list.
> Emacs-orgmode@gnu.org
> http://lists.gnu.org/mailman/listinfo/emacs-orgmode
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2009-01-25 15:59 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-01-25 15:16 Syntax highlighting in published output Jan Seeger
2009-01-25 15:59 ` Eric Schulte
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.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).