Skip to content

Commit

Permalink
Merge branch 'compatibility-version-elements' into 'html5-css'
Browse files Browse the repository at this point in the history
Addition of the compatibility/version element.

See merge request riscos/toolchain/prminxml!5
  • Loading branch information
gerph committed May 16, 2022
2 parents 6169c3e + ebc0d9c commit 6fe8461
Show file tree
Hide file tree
Showing 8 changed files with 769 additions and 37 deletions.
73 changes: 73 additions & 0 deletions catalog/docs/PRMinXML.txt
Original file line number Diff line number Diff line change
Expand Up @@ -783,13 +783,17 @@ These are grouped into table/value pairs :
offset-table & offset
message-table & message
definition-table & definition
version-table & version

message-tables are solely for use within descriptions of Wimp message
blocks.

value-tables are intended for numeric data, whilst definition-tables are
indented for textual definitions.

version-tables are for describing compatibility and differences in
behaviour between versions of a component or protocol.


Element: bitfield-table
Attributes: <none>
Expand Down Expand Up @@ -959,6 +963,64 @@ table comprising the definitions. The meaning of the definition is
described by the content of the element.


Element: version-table
Attributes: <none>
Children: (version)*

The version-table element is represented as a set of rows describing
the differences between different versions of a component or protocol.
Unlike the other tables above, this information is not (in the standard
layout) presented as tabular data, but as an indented list.


Element: version
Attributes: module-name, module-lt, module-eq, module-ge,
riscos-lt, riscos-eq, riscos-ge,
supplier, hardware, architecture,
state

module-name: (optional) The name of a module within which this version applies
(defaults to not saying the module, assumed to be the one
documented in the chapter)
module-lt: (optional) The documentation details versions up to the version
given.
module-eq: (optional) The documentation details an explicit version.
module-ge: (optional) The documentation details versions after the version given.
riscos-lt: (optional) The documentation details versions of the OS up to the
version given.
riscos-eq: (optional) The documentation details an explicit version of the OS.
riscos-ge: (optional) The documentation details versions of the OS after the
version given.
supplier: (optional) Qualifies the supplier of the component (RISC OS/module).
For example, to discuss RISC OS Ltd versions, RISC OS Open versions,
RISC OS Direct versions (for the OS), or the supplier of a module
as might be the case for different hardwar manufacturers of some
modules (like Joystick).
hardware: (optional) Qualifies the behaviour on specific hardware.
architecture: (optional) Describes the processor architectures to which it
applies (defaulting to AArch32) as a comma separated list of
aarch32, aarch64, x64.
state: 'supported', 'unsupported' or 'content' ('content' is the default
and includes any child content)

The version element describes the compatibility of a component, API or
protocol in different versions. The attributes of the element differentiate
which version the description applies. There are 5 dimensions in which
the version may be differentiated:

module - differentiating a given module by version (giving its name,
and bounds for the version.
riscos - differentiating by the version of the operating system.
supplier - differentiating by the supplier of a module, OS, or hardware.
hardware - differentiating by the type of hardware.
architecture - differentiating by the CPU architecture.

The 'state' may be stated as simply 'supported' or 'unsupported' to give
a simple statement of the support of the feature. If these are not used,
the content describing the compatibility will be taken from the child
elements.


API definitions
---------------

Expand Down Expand Up @@ -1096,6 +1158,15 @@ other details relevant to its use which are not part of the overall component
structure as described in the Technical details.


Element: compatibility
Attributes: <none>
Children: <version>*

The compatibility element describes the support of the definition within
different versions. It is equivalent to the version-table element, but as
an explicit section within the API definition.


Element: example
Attributes: <none>
Children: (p | command | systemoutput | br)*
Expand Down Expand Up @@ -1584,4 +1655,6 @@ Changes from 1.02 to 1.03
prefixed (previously wouldb prefixed by the usual prefixes, like 'UpCall_'.
* image elements are better supported now and allow multiple images to be
aligned in a row.
* compatibility, version-table and version elements added to provide information
about the support for given features.
* indexed content now supports cover and front-matter elements.
56 changes: 56 additions & 0 deletions catalog/gerph/103/prm-css.xml
Original file line number Diff line number Diff line change
Expand Up @@ -361,6 +361,9 @@ section.definition::before {
.definition-declarations::before {
content: 'Declarations';
}
.definition-compatibility::before {
content: 'Compatibility';
}
.definition-examples::before {
content: 'Examples';
}
Expand Down Expand Up @@ -504,6 +507,59 @@ table {
text-align: right;
}
.version-table:before {
content: "Compatibility";
font-weight: bold;
line-height: 2em;
}
.version-table {
padding-left: 0.5em;
}
.version-table .version {
padding-left: 1em;
}
.version + .version {
margin-top: 1em;
}
.version-qualifiers {
font-style: italic;
display: block;
}
.version-supplier {
margin-right: 1em;
}
.version-module {
margin-right: 1em;
}
.version-module-name:after {
content: "\00a0\00a0";
}
.version-module, .version-riscos {
margin-right: 1em;
}
.version-lt:before {
content: "<\00a0";
}
.version-ltge-separator:before {
content: ",\00a0\00a0";
}
.version-ge:before {
content: "\2265\00a0";
}
.version-riscos:before {
content: "RISC\00a0OS\00a0";
}
.version-hardware {
margin-right: 1em;
}
.version-architecture {
margin-right: 1em;
}
.version-content {
padding-left: 2em;
}
.userreplace {
font-style: italic;
}
Expand Down

0 comments on commit 6fe8461

Please sign in to comment.