Christian Moe <m...@christianmoe.com> wrote: > Hi, > > Only partly. > > On 11/14/10 12:24 AM, Sébastien Vauban wrote: > > Hello, > > > > A quick (but not easy?) question about the Org publish to HTML and CSS: I > > would like to make the 3 different timestamps stand out with different > > backgrounds. > > > > Is it possible with CSS? I have the impression that it currently is not, > > but... > > > > This is some sample output in HTML: > > > > #+begin_src html > > <p><span class="timestamp-wrapper"> <span class="timestamp">2010-11-13 > > Sat</span></span><br/> > > <span class="timestamp-wrapper"><span > > class="timestamp-kwd">SCHEDULED:</span> <span class="timestamp">2010-11-15 > > Mon</span></span><br/> > > <span class="timestamp-wrapper"><span > > class="timestamp-kwd">DEADLINE:</span> <span class="timestamp">2010-11-20 > > Sat</span></span><br/> > > </p> > > #+end_src > > > > Best regards, > > Seb > > > > You can distinguish between timestamps with and without a keyword. The > following will set a red background on SCHEDULED and DEADLINE > timestamps (sorry for the noise if this was clear to you already). > > #+STYLE: <style>.timestamp-kwd + .timestamp {background-color: > red}</style> > > But you cannot distinguish between different keywords -- no CSS > selector works on text content. You could use Javascript. >
Perhaps it'd be possible to (optionally) add an "id" selector to the timestamp <span> elements and use that for CSS manipulation, tied to an org-mode ID or some other unique id? Or perhaps just postprocess the HTML output to add such ids. Nick _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode