doc: use DX-friendly names in configuration option documentation

Change the generated config option documentation to use the DX-friendly
names defined for the configurator UI (instead of the XML element name
hierarchy previously used).

Options are grouped by the top-level section (aka complex type) they
belong to and then sorted alphabetically with these groups.

Use badges to indicate where options can be found in the configurator UI
and whether they're applicable to the Hypervisor or Pre/Post/Service VM.
Add a custom css style for the config-option doc that puts the first
paragraph of a glossary item on the same line as the glossary term so
these badges look pretty.

Added a acrn-custom.js patch that copies the alt text for images into a
title property for images within the config-doc document.  This provides
tooltip text when hovering over the badges.

Don't display options not visible in the configurator UI (elements with
acrn:views="").

A missing acrn:views or acrn:applicable-vm means we look for an
applicable value from an ancestor element.

Add processing of a second xs:documentation element within an
xs:annotation element. This second documentation element's content will
be appended as a new paragraph to the first xs:documentation content in
the generated documentation. Only the first xs:documentation element is
used by the Configurator for its tooltips.

Update documents that were referring to options by their XML names.

Because we're now using a glossary to provide links to config options,
we can't duplicate option names or glosary names anywhere in the doc
set.

Signed-off-by: David B. Kinder <david.b.kinder@intel.com>
This commit is contained in:
David B. Kinder
2022-04-20 14:09:22 -07:00
committed by David Kinder
parent f8f1689a88
commit f71c7a8032
16 changed files with 328 additions and 188 deletions

View File

@@ -20,8 +20,7 @@ Within this option documentation, we refer to some common type
definitions:
Boolean
A true or false value specified as either ``y`` or ``n``. Other
values such as ``t`` or ``f`` are not supported.
A true or false value specified as either ``y`` or ``n``.
Hexadecimal
A base-16 (integer) value represented by a leading ``0x`` or ``0X`` followed by
@@ -36,6 +35,51 @@ String
A sequence of UTF-8 characters. String-length limits or specific
string value restrictions are defined in the option description.
.. comment These images are used in generated option documentation
.. |icon-advanced| image:: images/Advanced.svg
:alt: Find this option on the Configurator's Advanced Parameters tab
.. |icon-basic| image:: images/Basic.svg
:alt: Find this option on the Configurator's Basic Parameters tab
.. |icon-not-available| image:: images/Not-available.svg
:alt: This is a hidden option and not user-editable using the Configurator
.. |icon-post-launched-vm| image:: images/Post-launched-VM.svg
:alt: Find this option on a Configurator Post-launched VM tab
.. |icon-pre-launched-vm| image:: images/Pre-launched-VM.svg
:alt: Find this option on a Configurator Pre-launched VM tab
.. |icon-service-vm| image:: images/Service-VM.svg
:alt: Find this option on the Configurator Service VM tab
.. |icon-hypervisor| image:: images/Hypervisor.svg
:alt: Find this option on the Configurator's Hypervisor Global Settings tab
We use icons within an option description to indicate where the option can be
found within the Configurator UI:
.. list-table::
:header-rows: 1
* - **Hypervisor/VM Tab**
- **Basic/Advanced Tab**
* - |icon-hypervisor|
Find this option on the Configurator's **Hypervisor Global Settings** tab
- |icon-basic|
Find this option on the Hypervisor's or VM's **Basic Parameters** tab
* - |icon-pre-launched-vm|
Find this option on a Configurator **Pre-Launched VM** tab
- |icon-advanced|
Find this option on the Hypervisor's or VM's **Advanced Parameters** tab
* - |icon-post-launched-vm|
Find this option on a Configurator **Post-Launched VM** tab
-
* - |icon-service-vm|
Find this option on the Configurator **Service VM** tab
-
-----
.. comment This configdoc.txt is generated during the doc build process
from the acrn config schema files found in misc/config_tools/schema

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="125" height="20" role="img" aria-label="Advanced Parameter"><title>Advanced Parameter</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="125" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#e05d44"/><rect x="0" width="125" height="20" fill="#e05d44"/><rect width="125" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="625" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="1150">Advanced Parameter</text><text x="625" y="140" transform="scale(.1)" fill="#fff" textLength="1150">Advanced Parameter</text></g></svg>

After

Width:  |  Height:  |  Size: 965 B

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="99" height="20" role="img" aria-label="Basic Parameter"><title>Basic Parameter</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="99" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#007ec6"/><rect x="0" width="99" height="20" fill="#007ec6"/><rect width="99" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="495" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="890">Basic Parameter</text><text x="495" y="140" transform="scale(.1)" fill="#fff" textLength="890">Basic Parameter</text></g></svg>

After

Width:  |  Height:  |  Size: 947 B

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="69" height="20" role="img" aria-label="Hypervisor"><title>Hypervisor</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="69" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#2b978f"/><rect x="0" width="69" height="20" fill="#2b978f"/><rect width="69" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="345" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="590">Hypervisor</text><text x="345" y="140" transform="scale(.1)" fill="#fff" textLength="590">Hypervisor</text></g></svg>

After

Width:  |  Height:  |  Size: 927 B

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="185" height="20" role="img" aria-label="Not available in Configurator UI"><title>Not available in Configurator UI</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="185" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#9f9f9f"/><rect x="0" width="185" height="20" fill="#9f9f9f"/><rect width="185" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="925" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="1750">Not available in Configurator UI</text><text x="925" y="140" transform="scale(.1)" fill="#fff" textLength="1750">Not available in Configurator UI</text></g></svg>

After

Width:  |  Height:  |  Size: 1021 B

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="109" height="20" role="img" aria-label="Post-launched VM"><title>Post-launched VM</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="109" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#998265"/><rect x="0" width="109" height="20" fill="#998265"/><rect width="109" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="545" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="990">Post-launched VM</text><text x="545" y="140" transform="scale(.1)" fill="#fff" textLength="990">Post-launched VM</text></g></svg>

After

Width:  |  Height:  |  Size: 955 B

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="103" height="20" role="img" aria-label="Pre-launched VM"><title>Pre-launched VM</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="103" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#4c1"/><rect x="0" width="103" height="20" fill="#4c1"/><rect width="103" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="515" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="930">Pre-launched VM</text><text x="515" y="140" transform="scale(.1)" fill="#fff" textLength="930">Pre-launched VM</text></g></svg>

After

Width:  |  Height:  |  Size: 945 B

View File

@@ -0,0 +1,3 @@
These icon badges were created using https://shields.io static badges.
Standard colors were used except for the Hypervisor #69BFAD (acrn-lightgreen) and post-launched VM
#998265 (acrn-brown) colors defined in the acrn-custom.css

View File

@@ -0,0 +1 @@
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" width="71" height="20" role="img" aria-label="Service VM"><title>Service VM</title><linearGradient id="s" x2="0" y2="100%"><stop offset="0" stop-color="#bbb" stop-opacity=".1"/><stop offset="1" stop-opacity=".1"/></linearGradient><clipPath id="r"><rect width="71" height="20" rx="3" fill="#fff"/></clipPath><g clip-path="url(#r)"><rect width="0" height="20" fill="#dfb317"/><rect x="0" width="71" height="20" fill="#dfb317"/><rect width="71" height="20" fill="url(#s)"/></g><g fill="#fff" text-anchor="middle" font-family="Verdana,Geneva,DejaVu Sans,sans-serif" text-rendering="geometricPrecision" font-size="110"><text aria-hidden="true" x="355" y="150" fill="#010101" fill-opacity=".3" transform="scale(.1)" textLength="610">Service VM</text><text x="355" y="140" transform="scale(.1)" fill="#fff" textLength="610">Service VM</text></g></svg>

After

Width:  |  Height:  |  Size: 927 B