Documentation/Proposed Extensions for XHP

=Proposed extensions to XHP markup=

Introduction
XHP markup was created for an ambitious objective of offline, online document display and content reuse. However its richness also carries a steep learning curve for Help contents newcomers.

The following proposed XHP extensions aims to simplify XHP markup for frequently used combinations of markup tags, besides making hopefully easier to read textual XML. It worth to note that the existing XHP markup is kept untouched, to preserve legacy contents.

Global rules

 * always preserve existing id=""
 * on textual tags, always add an id=""

Suggested XHP Extensions
Green rows means tags implemented.

=Extensions DTD=

h1
This element is the top heading element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h1 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h1 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h1 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h1&gt;  Proceed as follows to write an italic character  

h2
This element is the heading level 2 element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h2 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h2 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h2 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h2&gt;  Proceed as follows to write an italic character  

h3
This element is the heading level 3 element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h3 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h3 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h3 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h3&gt;  Proceed as follows to write an italic character  

h4
This element is the heading level 2 element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h4 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h4 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h4 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h4&gt;  Proceed as follows to write an italic character  

h5
This element is the heading level 2 element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h5 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h5 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h5 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h5&gt;  Proceed as follows to write an italic character  

h6
This element is the heading level 2 element holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT h6 (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST h6 id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;h6 id="par4711_001" xml_lang="en-US"&gt; Italic characters &lt;/h6&gt;  Proceed as follows to write an italic character  

note
This element adds a note paragraph holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT note (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal | widget)*> <!ATTLIST note id CDATA #REQUIRED xml-lang CDATA #IMPLIED localize CDATA #IMPLIED >

Example

&lt;note id="par4711_001"&gt; You can paste contents with &lt;keycode&gt;Ctrl + Ins&lt;/keycode&gt; &lt;/note&gt;

tip
This element adds a tip paragraph holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT tip (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST tip id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;tip id="par4711_001" xml_lang="en-US"&gt; You can paste content with Ctrl + Ins &lt;/tip&gt;

warning
This element adds a warning paragraph holding content.

Attributes

Parent Elements

,,  ,  ,  ,

Child Elements

,,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,  ,

Element Definition

<!ELEMENT warning (#PCDATA | comment | embedvar | br | emph | item | link | switchinline | variable | ahelp | bookmark | keycode | menuitem | input | literal)*> <!ATTLIST warning id CDATA #REQUIRED xml-lang CDATA #REQUIRED localize CDATA #IMPLIED >

Example

&lt;warning id="par4711_001" xml_lang="en-US"&gt; You cannot paste contents in read-only sections &lt;/warning&gt;

menuitem
This element is used to mark up menu items. This element resembles the

Attributes None

Parent Elements

,,  ,  ,  ,  ,  ,

Child Elements

none

Element Definition

<!ELEMENT menuitem (#PCDATA)> > Example

You see the  File Open  dialog.

input
This element is used to mark up input items.

Attributes None

Parent Elements

,,  ,  ,  ,  ,  ,

Child Elements

none

Element Definition

<!ELEMENT input (#PCDATA)> > Example

 =SUMIF(A1:A10,">0",B1:B10) 

keycode
This element is used to mark up a keystroke.

Attributes None

Parent Elements

,,  ,  ,  ,  ,  ,

Child Elements

none

Element Definition

<!ELEMENT keycode (#PCDATA)> > Example

Press  Ctrl + Shift + V  to open paste special dialog box.

literal
This element is used to mark up a literal content.

Attributes None

Parent Elements

,,  ,  ,  ,  ,  ,

Child Elements

none

Element Definition

<!ELEMENT literal (#PCDATA)> > Example

Fill the range  A1:A100  with data.

icontable
This element defines a table containing one row and 2 columns. The table element itself only contains child elements.

Attributes

Table 23: Attributes of the table element

Parent Elements

,,  ,  ,

Child Elements

,

Element Definition

<!ELEMENT icontable > <!ATTLIST table name CDATA #IMPLIED width CDATA #IMPLIED height CDATA #IMPLIED unit CDATA #IMPLIED class CDATA #IMPLIED id CDATA #REQUIRED localize CDATA #IMPLIED >

Example

   List of shortcuts  

iconimage (WIP)
This element carries information about icon image in the document.

Attributes

Table 12: Attributes of the image element

Parent Elements

Child Elements

Element Definition

<!ELEMENT iconimage ( alt+)?> <!ATTLIST image src CDATA #REQUIRED width CDATA #IMPLIED height CDATA #IMPLIED id CDATA #REQUIRED >

Example

 Main program window  

icontext
This element holds contents of an icontable

Attributes

Parent Elements

Child Elements

,,  ,  ,  ,  ,

Element Definition

<!ELEMENT icontext (section | paragraph | comment | embed | bookmark | image | list)*> <!ATTLIST icontext class CDATA #IMPLIED localize CDATA #IMPLIED >

Example

&lt;icontext id="par4711_001" xml_lang="en-US"&gt; Proceed as follows to write an italic character