Enhance docbook man:[] macro with stuff from git's gitlink:[] macro
[elinks.git] / doc / asciidoc.conf
blob7f49e94089cac4958ccefc3dc18c305e97e42820
1 # AsciiDoc configuration file
2 # Copyright (c) Jonas Fonseca <fonseca@diku.dk>, 2006
4 # This file sets the following ELinks specific AsciiDoc macros:
6 # General purpose:
7 # - man:page[section]: which is used for linking between ELinks manpages.
9 # API Doc:
10 # - id:[]
11 # - enum:[]
12 # - func:[]
13 # - struct:[]
14 # - macro:[]
15 # - typedef:[]
16 # - ref:[]
18 # Some macros can have optional {0} value, that is what
19 # the {0%...} and {0#...} handles.
21 #############################################################################
22 # DocBook
24 ifdef::backend-docbook[]
26 # No interlinking between elinks manpages
27 [man-inlinemacro]
28 {0%{target}}
29 {0#<citerefentry>}
30 {0#<refentrytitle>{target}</refentrytitle><manvolnum>{0}</manvolnum>}
31 {0#</citerefentry>}
33 # For manpages use less verbose linking
34 ifdef::doctype-manpage[]
35 [link-inlinemacro]
36 {0%&lt;{target}&gt;}
37 {0#{0} &lt;{target}&gt;}
39 [http-inlinemacro]
40 {0%&lt;http:{target}&gt;}
41 {0#{0} &lt;http:{target}&gt;}
43 [mailto-inlinemacro]
44 &lt;{target}&gt;
46 endif::doctype-manpage[]
47 endif::backend-docbook[]
49 #############################################################################
50 # XHTML11
52 ifdef::backend-xhtml11[]
54 # Use the man:[] macro to link between elinks manpages
55 [man-inlinemacro]
56 <a href="{target}.{0}.html">{target}({0})</a>
58 # API Doc macros
60 [id-inlinemacro]
61 <a id="{0}" href="#{0}">{0}</a>
63 [enum-inlinemacro]
64 <a id="{target}">enum {target}: {0}</a>
66 [func-inlinemacro]
67 <a id="{target}">{target}(): {0}</a>
69 [struct-inlinemacro]
70 <a id="{target}">struct {target}: {0}</a>
72 [macro-inlinemacro]
73 <a id="{target}">struct {target}: {0}</a>
75 [typedef-inlinemacro]
76 <a id="{target}">typedef {target}: {0}</a>
78 [ref-inlinemacro]
79 <a href="{target}#{0}">{0}</a>
81 endif::backend-xhtml11[]