The AsciiDoc 'themes' feature has been around for a while but has largely gone unnoticed. The neat thing about themes (once they've been written) is that they completely restyle your document with zero effort -- it's quite magical.
The lastest release has kindled a flurry of interest in AsciiDoc themes and revealed that the feature is being used: for example see Ryan Tomayko's AsciiDoc themes page http://tomayko.com/src/adoc-themes/ Now is probably a good time formalize, update and document themes. - The new 'flask' theme was implemented by adding (overriding) rules to the default 'asciidoc' theme, you don't get optimal CSS but it makes for easy incremental development. The same file works with both xhtml11 and html5 backends -- I should document this in a themes 'how-to'. - A separate `<theme>-manpage.css` file should not be mandatory. Most of the time a separate `<theme>-manpage.css` is unnecessary and (in the currently shipped themes they are just place holders to suppress warnings). This could be achived by implementing an include2::[] macro: identical to include1::[] but no warnings if the file does not exist. - Future changes to existing markup, id and class attributes emitted by xhtml11 and html5 outputs would need to be minimized to avoid backward theme incompatibilities. For the time being I don't want to get to fancy, but there are a couple of additions that I think bear merit: - An optional `<theme>.js` file for theme based scripting. - A themes directory structure: the theme files would reside in a configuration directory named `themes/<theme>/`. When generating outputs with embedded CSS AsciiDoc would load `<theme>.css` and (optionally) `<theme>.js` from that location; if a directory named `themes/<theme>/icons` exists and the 'data-uri' was defined then set the 'iconsdir' attribute to that directory. - The above directory-per-theme arrangement would lend itself to zip based theme plugins managed by a '--theme' command-line option (cf filters plugins and the '--filter' command-line option). This would make the distribution of new themes easy and take the onus of theme management out of the core AsciiDoc distribution. Comments and suggestions welcomed. 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.
