Validating @outputclass by subjectScheme
Posted: Wed Jul 06, 2016 5:26 pm
I’m developing subjectScheme to validate @outputclass attribute. If I want apply @outputclass=”title-page|title|page” for xref element, subjectScheme will be coded as following:
This works fine in oXygen 18.0. Following is the screen shot.
https://www.dropbox.com/s/gogdmqymt8th5 ... 6.png?dl=0
However if I want to apply fig/@outputclass=”none|left|right” and figgroup/@outputclass=”auto|left|right”, the subjectScheme will become following because the value “left” and “right” are common to fig and figgroup:
In this case “floatRight” and “floatLeft” are also treated as the candidate attribute value.
https://www.dropbox.com/s/ay2g8x6t7whho ... 9.png?dl=0
But obviously it is not what I intended. Are there any ways to limit both fig/@outputclass and figgroup/@outputclass to expected value?
Regards,
/*--------------------------------------------------
Toshihiko Makita
Development Group. Antenna House, Inc. Ina Branch
Web site:
http://www.antenna.co.jp/
http://www.antennahouse.com/
--------------------------------------------------*/
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="urn:oasis:names:tc:dita:spec:classification:rng:subjectScheme.rng" schematypens="http://relaxng.org/ns/structure/1.0"?>
<subjectScheme>
<subjectHead>
<subjectHeadMeta>
<navtitle> Constraint @outputclass for xref</navtitle>
</subjectHeadMeta>
</subjectHead>
<subjectdef keys="outputclassXref">
<subjectdef keys="title">
<topicmeta>
<navtitle>Output destination title only</navtitle>
</topicmeta>
</subjectdef>
<subjectdef keys="title-page">
<topicmeta>
<navtitle>Output destination title & page</navtitle>
</topicmeta>
</subjectdef>
<subjectdef keys="page">
<topicmeta>
<navtitle>Output destination page only</navtitle>
</topicmeta>
</subjectdef>
</subjectdef>
<enumerationdef>
<elementdef name="xref"/>
<attributedef name="outputclass"/>
<subjectdef keyref="outputclassXref"/>
</enumerationdef>
</subjectScheme>
https://www.dropbox.com/s/gogdmqymt8th5 ... 6.png?dl=0
However if I want to apply fig/@outputclass=”none|left|right” and figgroup/@outputclass=”auto|left|right”, the subjectScheme will become following because the value “left” and “right” are common to fig and figgroup:
Code: Select all
<?xml version="1.0" encoding="UTF-8"?>
<?xml-model href="urn:oasis:names:tc:dita:spec:classification:rng:subjectScheme.rng" schematypens="http://relaxng.org/ns/structure/1.0"?>
<subjectScheme>
<subjectHead>
<subjectHeadMeta>
<navtitle> Constraint @outputclass for fig </navtitle>
</subjectHeadMeta>
</subjectHead>
<subjectdef keys="floatLeft">
<subjectdef keys="left">
<topicmeta>
<navtitle>Floats left</navtitle>
</topicmeta>
</subjectdef>
</subjectdef>
<subjectdef keys="floatRight">
<subjectdef keys="right">
<topicmeta>
<navtitle>Floats right</navtitle>
</topicmeta>
</subjectdef>
</subjectdef>
<subjectdef keys="outputclassFig">
<subjectdef keys="none">
<topicmeta>
<navtitle>No float</navtitle>
</topicmeta>
</subjectdef>
<subjectdef keyref="floatLeft"/>
<subjectdef keyref="floatRight"/>
</subjectdef>
<subjectdef keys="outputclassFigGroup">
<subjectdef keys="auto">
<topicmeta>
<navtitle>Auto (Same as previous)</navtitle>
</topicmeta>
</subjectdef>
<subjectdef keyref="floatLeft"/>
<subjectdef keyref="floatRight"/>
</subjectdef>
<enumerationdef>
<elementdef name="fig"/>
<attributedef name="outputclass"/>
<subjectdef keyref="outputclassFig"/>
</enumerationdef>
<enumerationdef>
<elementdef name="figgroup"/>
<attributedef name="outputclass"/>
<subjectdef keyref="outputclassFigGroup"/>
</enumerationdef>
</subjectScheme>
https://www.dropbox.com/s/ay2g8x6t7whho ... 9.png?dl=0
But obviously it is not what I intended. Are there any ways to limit both fig/@outputclass and figgroup/@outputclass to expected value?
Regards,
/*--------------------------------------------------
Toshihiko Makita
Development Group. Antenna House, Inc. Ina Branch
Web site:
http://www.antenna.co.jp/
http://www.antennahouse.com/
--------------------------------------------------*/