Lionel wrote:
Great, I already guessed the first part, thanks for the remaining one.
I was considering using the original <ol> for the calllout list, and
append a class name to items, i.e
<ol class="calloutlist">
<li class="colist-1">...</li>
<li class="colist-2">...</li>
<li class="colist-3">...</li>
</ol>
then using CSS to redefine list-type:
ol.calloutlist li.colist-1 { list-style-image: url('./callouts/
1.png'); }
ol.calloutlist li.colist-2 { list-style-image: url('./callouts/
2.png'); }
ol.calloutlist li.colist-3 { list-style-image: url('./callouts/
3.png'); }
I don't know if it's better, but I'd rather avoid tables if not
necessary. ascciidoc xhtml backend nicely uses <ol> for now, why not
keep it ?
CSS hardwires the image path -- we need to set it dynamically using the AsciiDoc
iconsdir attribute (I didn't get round to that in the example I posted). Also
missing is that the use of icons should be conditional on the AsciiDoc icons
attribute.
I've committed the completed patch:
http://code.google.com/p/asciidoc/source/detail?r=1de6d41c76463615c8b5dac756be3d37e37fafb0
Cheers, Stuart
Lionel
On 22 fév, 09:53, Stuart Rackham <[email protected]> wrote:
Lionel wrote:
I am using the source-highlight filter and the xhtml backend of
asciidoc to output the single-page html version of the documentation,
because the highlighted source looks great.
source-highlight, in that case, outputs html directly, which is
included then by asciidoc in the final doc.
I was wondering if it's possible to filter the html once again after
the source-highlight pass, and replace a pattern corresponding to the
generated html for the callout numbers, by the html to display the
same callout pictures used with the docbook backend (black circles) ?
It would greatly improve the look and feel of the callout lists with
the xhtml backend.
Any ideas of the best way to do that ? on my machine (but I suppose
this is specific to the configuration and version of source-
highlight), the callout numbers generate the following html code (to
be replaced):
<span style="color: #990000"><</span><span style="color:
#993399">1</span><span style="color: #990000">></span>
I'd like this to be changed to:
<img src="./callouts/1.png" alt="1" border="0" />
And even better, later, i'd try to make the cross-reference links
between the callout and the callout-list definition work.
You could redefine the callout-inlinemacro template in xhtml11.conf as:
[callout-inlinemacro]
<img src="./callouts/{index}.png" alt="{index}" border="0" />
To place callout icons in the list item bullets something like this:
[listtags-callout]
list=<div class="colist{style? {style}}"{id? id="{id}"}>{title?<div
class="title">{title}</div>}<table>|</table></div>
item=<tr><td style="padding-right:0.5em;"><img src="./callouts/{listindex}.png"
alt="{listindex}" /></td><td>|</td></tr>
text=|
I'll look at putting this into the trunk.
Cheers, Stuart
Thanks for hints,
Lionel
--
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.