if you are a human please do not click here
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email?
Username :
Password :
Home
Help
Calendar
Register
Login
XMetaL Community Forums
»
General
»
General XMetaL Discussion
»
Schema problem
Pages:
1
« previous
next »
Print
Author
Topic: Schema problem (Read 325 times)
tonys
Member
Posts: 15
Schema problem
«
on:
January 04, 2012, 05:55:22 PM »
I'm having a problem with the schema and XML document in the attached zip.
XMetaL says the document is invalid because the <td> element can't directly contain text. However, if I use libxml2 or Xerces-J they both claim the document is valid.
The critical thing is whether the mixed="true" on the cell.type complex type is inherited by the complexContent which extends it. In section 3.4.2 of Part 1 of the XSD recommendation the definition of "effective mixed" seems to say that only the mixed attributes in the element definition should be used (i.e. mixed should not be inherited as part of the extension), but maybe there's something else that overrides this.
Can anyone confirm what is the correct behaviour? (IMHO the schema should be changed to put the mixed on the element definition, but that's not my call.)
schema.zip
(0.77 KB - downloaded 13 times.)
Logged
Derek Read
Program Manager (XMetaL)
Administrator
Member
Posts: 1548
Re: Schema problem
«
Reply #1 on:
January 05, 2012, 05:26:25 PM »
Our understanding of the primer suggests that the XMetaL Author (or XMAX) behavior is incorrect and that @mixed should be inherited.
Until we can rectify this in our parser, a temporary fix would be to move @mixed to the element declaration (at least for the XMetaL copy of the Schema).
Interesting that this is just now coming to light (no previous reports since we added Schema support in 2003). That suggests to me that this construction is uncommon (at least in any Schemas used by our clients). Not that that helps any here as it is a perfectly valid way to write a Schema.
«
Last Edit: January 05, 2012, 05:33:09 PM by Derek Read
»
Logged
tonys
Member
Posts: 15
Re: Schema problem
«
Reply #2 on:
January 05, 2012, 07:25:09 PM »
Thanks, Derek.
If I tell them they're doing something that no XMetaL users have done in the last 8 years they'll probably think it's a good idea to change it!
Logged
Derek Read
Program Manager (XMetaL)
Administrator
Member
Posts: 1548
Re: Schema problem
«
Reply #3 on:
January 05, 2012, 08:03:42 PM »
Yes, if you have control of the schema then this seems like an easy fix on your side.
It is wrong behaviour though, so I've logged it with development as a bug.
Logged
Pages:
1
Print
« previous
next »
Jump to:
Please select a destination:
-----------------------------
General
-----------------------------
=> Forum Information
=> General XMetaL Discussion
=> DITA and XMetaL Discussion
=> XMetaL Tips and Tricks
=> XMetaL Announcements and Events
Loading...