> > Hi, I have this minimal asciidoc.conf:
>
> > ----8<----
> > [macros]
> > (?su)(?P<name>longtxt):(?P<target>[^:]+):=
> > (?su)(?P<name>strong|em):(?P<target>[^:]+):=
>
> > # for DocBook
> > ifdef::backend-docbook[]
> > [strong-inlinemacro]
> > <emphasis role="strong">{target}</emphasis>
> > [em-inlinemacro]
> > <emphasis>{target}</emphasis>
> > endif::backend-docbook[]
>
> > # for HTML
> > ifdef::backend-xhtml11[]
> > [strong-inlinemacro]
> > <{name}>{target}</{name}>
> > [em-inlinemacro]
> > <{name}>{target}</{name}>
> > endif::backend-xhtml11[]
>
> > [longtxt-inlinemacro]
> > # this does not work: **The quick brown fox** jumps over __{target}__
> > strong:The quick brown fox: jumps over em:{target}:
> > ----8<----
>
> > The longtext macro is invoked like this: longtxt:the lazy dog:
>
> > Since markup does not work inside the macros I wonder if it is
> > possible to access the standard tags without defining the extra
> > definitions strong:: and em::?
>
> Hi,
>
> Markup template sections are intended for defining output markup, they
> are not scanned for input markup so that most text can be used
> unescaped.  So very little markup is recognised and cannot be extended
> without risking backward compatibility with existing configuration
> files.

I suspected something like that already, but thanks for explaining the
reasons.

> The only things that are guaranteed to work are defined 
> herehttp://www.methods.co.nz/asciidoc/userguide.html#_markup_template_sec...
>
> That does not include user macros, so the fact that your defined
> macros actually work might actually be considered a bug, since some
> constructs might need escaping in the output text but that fact isn't
> documented.

Now I'm lost. Maybe I'll put my question different: 1. I know that
macros are intended for output markup. 2. I assume standard markup
templates (strong, em, etc.) for different backends must be already
defined somewhere. 3. How do use these existing templates in a user
macro without rewriting them from scratch again like I did in the
example.

cheers
recryn

-- 
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