On 14/02/12 01:47, Dag Wieers wrote:
On Mon, 13 Feb 2012, Stuart Rackham wrote:

I assume you mean in the Plugins table 1 in
http://www.methods.co.nz/asciidoc/plugins.html
If so could you package it as a plugin so it can be downloaded and installed
using the asciidoc backend install command e.g.

asciidoc --backend install odt-0.1.zip

I am already stuck :-)

As far as I understood, everything goes into a single ZIP file and is unpacked
in the backend (or themes) directory in its own directory. But how can I
distribute ODF specific themes together with the ODF backend ?

What I currently have put in place are:

/etc/asciidoc/odp.conf
/etc/asciidoc/odt.conf
/etc/asciidoc/stylesheets/asciidoc.odp.styles
/etc/asciidoc/stylesheets/asciidoc.odt.styles
/etc/asciidoc/themes/cv/cv.odt.styles
/etc/asciidoc/themes/hp/hp.odt.styles

If I understand it correctly, I would need to create 4 different ZIP files, one
for odt, one for odp, one for the 'cv' theme and one for the 'hp' theme ? And
put the default odp/odt styles into their backend directory (and reference it
there).

odt-backend-0.1.zip

/etc/asciidoc/backends/odt/odt.conf
/etc/asciidoc/backends/odt/default-odt.styles

odp-backend-0.1.zip

/etc/asciidoc/backends/odp/odp.conf
/etc/asciidoc/backends/odp/default-odp.styles

cv-theme-0.1.zip

/etc/asciidoc/themes/cv/cv-odt.styles

hp-theme-0.1.zip

/etc/asciidoc/themes/hp/hp-odp.styles
/etc/asciidoc/themes/hp/hp-odt.styles

I was hoping for something more advanced so the ODF backend would provide both
odp and odt, and the styles and example themes.

Also, in the future I can imagine people to provide a single theme that provides
css and odf styles. I guess that is possible like the above enables both odp and
odt themes, right ? So if we want to also provide nice HP html output, we could
just add this to the current HP theme.

Thanks for your insights :)

One plugin zip file per backend is what we're stuck with, but the generation of odt-1.0.zip, odp-1.0.zip would be automated by the makefile so it's probably not as bad as it appears.

Re 'cv' and 'hp' themes, I don't understand ODF themes but, couldn't they be built into the ODF backends handled by passing them in the a2x --backend-opts option which passes it on to the a2x-backend.py? e.g.

  a2x --backend odt --backend-opts="--theme=cv" mydoc.txt

I wonder if --theme is sufficiently general for it to be added to a2x (which would then passed to a2x-backend.py as self.theme) -- the above example command would become:

  a2x --backend odt --theme=cv mydoc.txt

This would do away with the need for separate 'theme' zip files (the AsciiDoc themes are specific to HTML (html5 and xhtml11 backends)).


Cheers, Stuart

--
You received this message because you are subscribed to the Google Groups 
"asciidoc" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/asciidoc?hl=en.

Reply via email to