OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

dita message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: RE: [dita] ditaval file syntax


Hi,

 

A ânormalizedâ version of the DTD is this, according to the Xerces xml parser, in case this helps:

 

<!ELEMENT val (style-conflict?,(prop|revprop)*)>

<!ELEMENT style-conflict EMPTY>

<!ATTLIST style-conflict

          foreground-conflict-color CDATA #IMPLIED

          background-conflict-color CDATA #IMPLIED>

<!ELEMENT prop (startflag?,endflag?)>

<!ATTLIST prop

          att CDATA #IMPLIED

          val CDATA #IMPLIED

          action ( flag | include | exclude | passthrough ) #REQUIRED

          outputclass CDATA #IMPLIED

          color CDATA #IMPLIED

          backcolor CDATA #IMPLIED

          style NMTOKENS #IMPLIED>

<!ELEMENT startflag (alt-text?)>

<!ATTLIST startflag

          imageref CDATA #IMPLIED>

<!ELEMENT endflag (alt-text?)>

<!ATTLIST endflag

          imageref CDATA #IMPLIED>

<!ELEMENT alt-text (#PCDATA)>

<!ELEMENT revprop (startflag?,endflag?)>

<!ATTLIST revprop

          val CDATA #IMPLIED

          action ( include | passthrough | flag ) #REQUIRED

          outputclass CDATA #IMPLIED

          changebar CDATA #IMPLIED

          color CDATA #IMPLIED

          backcolor CDATA #IMPLIED

          style NMTOKENS #IMPLIED>

 

Sorry for being late to the most recent meetingâ

 

Kendall

From: dita@lists.oasis-open.org <dita@lists.oasis-open.org> On Behalf Of Jim Tivy
Sent: Sunday, October 23, 2022 4:49 PM
To: dita@lists.oasis-open.org
Subject: [dita] ditaval file syntax

 

Hi Folks

I was reviewing DITAVAL syntax and semantics and found I had to dig a bit to find the syntax.

I think I missed the 2.0 review on this section

The current spec does explain semantics well but the syntax was a bit more vague.

As a result I came up with a quick Backus Naur for the syntax.  This is a quick draft and the naming and accuracy may offend but the general idea is there.

Do we see any value in this kind of presentation in the spec.  Also reference to supporting resources such as XML Schema or RelaxNg for the ditaval file would help, however that would not serve documentation needs.

https://dita.fluidtopics.com/r/Darwin-Information-Typing-Architecture-DITA-Version-1.3-Part-3-All-Inclusive-Edition/val

Syntax

Here is a specification of the syntax of the ditaval file in a roughly extended Backus-Naur form.  Although the ditaval file is XML, the XML is removed but the information model is retained and such a model could be serialized into XML.

The names of the syntax rules below relay some semantic information about the actions however, the exact semantics are discussed elsewhere.

  • [x] is optional x
  • * is 0..n
  • + is 1..n
  • | is exclusive or
  • name is the name of a semantic piece.

 

actionSet ::= [styleConflictAction],propActions*

propActions ::= includeAction | excludeAction | | passthroughAction |

                flagAction | revFlagAction

 

includeAction ::= propSelector

excludeAction ::= propSelector

propSelector ::= propAttrValue | propAllValues | propAllAttrs

propAttrValue ::= attributeName attributeValue

propAllValues ::= attributeName

propAllAttrs ::= attributeValue

 

flagAction ::= propSelector appearanceDirective [startFlag] [endFlag]

appearanceDirective ::= color | backcolor | style

startFlag ::= demarcateDirective

endFlag ::= demarcateDirective

demarcateDirective ::= imageref [altText]

 

revFlagAction ::= revValue appearanceDirective

 

Could relate to a ditaval file XML for instance propAttrValue is represented as: 

<prop att="audience" val="administrator">

 

cheers

Jim



[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]