From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rick Frankel Subject: Re: colorize html output when batch exporting Date: Wed, 15 Jan 2014 09:39:53 -0500 Message-ID: References: <456aae79ec3109523d0d19759b73b0eb@mail.rickster.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:43348) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W3RdP-0004ND-Cp for emacs-orgmode@gnu.org; Wed, 15 Jan 2014 09:40:05 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1W3RdJ-0008VQ-C3 for emacs-orgmode@gnu.org; Wed, 15 Jan 2014 09:39:59 -0500 Received: from mail.rickster.com ([204.62.15.78]:54254) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1W3RdJ-0008VL-81 for emacs-orgmode@gnu.org; Wed, 15 Jan 2014 09:39:53 -0500 In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Alan Schmitt Cc: emacs-orgmode On 2014-01-15 03:04, Alan Schmitt wrote: > Quick summary: I'm now able to generate the css, but I don't understand > how it can change the colors. > However, I still find there is a problem. Here is the html source > generated from a snippet of the file: > > #+BEGIN_SRC html >
> >
Inductive expr :=
> | expr_this : expr
> | expr_identifier : string -> expr
> | expr_literal : literal -> expr
> | expr_object : list (propname * propbody) -> expr
> | expr_function : option string -> list string -> funcbody -> 
> expr
> | expr_access : expr -> expr -> expr
> | expr_member : expr -> string -> expr
> | expr_new : expr -> list expr -> expr
> | expr_call : expr -> list expr -> expr
> | expr_unary_op : unary_op -> expr -> expr
> | expr_binary_op : expr -> binary_op -> expr -> expr
> | expr_conditional : expr -> expr -> expr -> expr
> | expr_assign : expr -> option binary_op -> expr -> expr
> 
>
> #+END_SRC > > I don't understand how things are supposed to be colorized, as there is > no mention in the html of span elements to put color on. For instance, > "Inductive" is a keyword, and in a coq buffer it has face > "font-lock-keyword-face". Shouldn't it have class "org-keyword" in the > generated html? Yes, it should. Something is not right with your output. I'm not familiar with coq, and i don't have coq-mode.el, but from the above it looks like a BNF grammar. Are you sure coq-mode was loaded when you did the export? Could you try a simple example? Here's a mimimal org file #+BEGIN_SRC org ,#+OPTIONS: html-postamble:nil html-preamble:nil html-scripts:nil html-style:nil ,#+HTML_HEAD_EXTRA: ,#+HTML_DOCTYPE: xhtml5 ,* Test htmlize ,*Note:* =org-html-htmlize-output-type= is ~css~ ,#+BEGIN_SRC perl :exports code print "foo\n"; ,#+END_SRC #+END_SRC and the results i get: #+BEGIN_HTML html

html

Table of Contents

Test htmlize

Note: org-html-htmlize-output-type is css

print "foo\n";
#+END_HTML