Using external namespaces with mallard-site-tool

Tobias Rapp <yahuxo at gmx.de>
Sat Mar 30 16:38:12 EDT 2013

Am 26.03.2013 15:23, schrieb Shaun McCance:
> Mallard explicitly allows elements from external namespaces in three
> separate contexts, and it defines the fallback behavior for tools that
> don't understand those elements. But it doesn't dictate that external
> elements will actually do anything other than the fallback behavior.
>
> For example, let's say I made an extension to colorize text, and my
> pages looked something like this:
>
> <p xmlns:c="http://example.com/colors/">This is <c:red>red</c:red>,
> and this is <c:blue>blue</c:blue>.</p>
>
> If you process that with yelp, you'll get the same kind of warnings
> you got with the Ruby example, and because of the defined fallback
> behavior, your HTML will look like this:
>
> <p>This is red and this is blue.</p>
>
> [...]
>
> But Yelp doesn't work that way right now, and the Mallard spec
> doesn't require it to.

Hello Shaun,

thanks for your detailed answer and the XSL template example. With your
help I actually managed to put the bits together and get it working.

Initially it was a bit difficult/confusing for me as a Mallard newbie to
separate between the general Mallard specification and the concrete
implementation in Yelp. But now I think I got it :-)

> Missed a closing quote for the name attribute. Sorry. I'm going
> to integrate something like this to at least make Ruby work in
> Yelp 3.10. I'm not sure if I'll get to a full HTML pass-through
> for block elements and extra stuff in the head.

In my case it is enough to have the possibility to extend the inline
elements.

Thanks again,
Tobias