On Oct 29, 2006, at 10:43 AM, Fred Drake wrote:

On 10/29/06, Perry Smith <[EMAIL PROTECTED]> wrote:
I bumped into two problems that stumped me. First, it is general practice
to do:

<metal:arbitrary_tag define-macro="page">

Constructs for this can be written in RELAX NG, but I've not tried
doing that myself though.  The Atom specification includes an example
for elements in the XHTML namespace.

It is simple to have specify a tag like metal:* where anything can follow. But I did not see the benefit to that.


Second, metal and tal constructs are attributes that are placed inside any
tag.
...
So, to really do this properly, each schema that the tal or metal are going
to be used in would need to be modified to allow the tal and metal
attributes. The RNC syntax does have a funny include construct that allows overriding constructs that are defined in the included file. But, that only means that it would be possible to create a maintenance nightmare if someone
wanted to do that.

Almost; it really depends on the how the base schemas are written.
They can be written to cooperate with extending or specializing
schemas.  There are examples in the RELAX NG tutorials.  It does
require that the base schemas be written with that expectation, just
like classes need to be written to expect subclassing.

Yes. thats true. The samples I have for xhtml did not seem to have that. For example, in my xhtml, the title element allowed the xml:lang attribute and nothing else. I got my samples from the nxml emacs package.

But, I think I can still do some useful work here.

I can create a rnc for metal and tal. It can have hooks to let people add to the list of tags (which solves the first problem) and it could create a list (or two lists) of attributes that future schema writers could add into their schema.

Aside from xhtml and zcml, (for 99% of the usage), what is the list of base schemas people are going to add metal and tal attributes to?

It also sounds like I need to look at the tutorials. I was just look at the spec. Maybe there are conventions that I missed.

_______________________________________________
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users

Reply via email to