Promote underline levels

This commit is contained in:
Adam Turner 2023-10-01 20:03:34 +01:00
parent 385a9193a7
commit e15fc04e53
7 changed files with 40 additions and 33 deletions

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
============
The C Domain The C Domain
------------ ============
The C domain (name **c**) is suited for documentation of C API. The C domain (name **c**) is suited for documentation of C API.
@ -126,7 +127,7 @@ The C domain (name **c**) is suited for documentation of C API.
.. _c-roles: .. _c-roles:
Cross-referencing C constructs Cross-referencing C constructs
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ------------------------------
The following roles create cross-references to C-language constructs if they The following roles create cross-references to C-language constructs if they
are defined in the documentation: are defined in the documentation:
@ -151,7 +152,7 @@ are defined in the documentation:
Anonymous Entities Anonymous Entities
~~~~~~~~~~~~~~~~~~ ------------------
C supports anonymous structs, enums, and unions. C supports anonymous structs, enums, and unions.
For the sake of documentation they must be given some name that starts with For the sake of documentation they must be given some name that starts with
@ -197,7 +198,7 @@ Explicit ref: :c:var:`Data.@data.a`. Short-hand ref: :c:var:`Data.a`.
Aliasing Declarations Aliasing Declarations
~~~~~~~~~~~~~~~~~~~~~ ---------------------
.. c:namespace-push:: @alias .. c:namespace-push:: @alias
@ -251,7 +252,7 @@ The following directive can be used for this purpose.
Inline Expressions and Types Inline Expressions and Types
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------
.. rst:role:: c:expr .. rst:role:: c:expr
c:texpr c:texpr
@ -287,7 +288,7 @@ Inline Expressions and Types
Namespacing Namespacing
~~~~~~~~~~~ -----------
.. versionadded:: 3.1 .. versionadded:: 3.1
@ -352,6 +353,6 @@ The ``c:namespace-pop`` directive undoes the most recent
.. c:namespace-push:: A.B .. c:namespace-push:: A.B
Configuration Variables Configuration Variables
~~~~~~~~~~~~~~~~~~~~~~~ -----------------------
See :ref:`c-config`. See :ref:`c-config`.

View File

@ -1,12 +1,13 @@
.. highlight:: rst .. highlight:: rst
==============
The C++ Domain The C++ Domain
-------------- ==============
The C++ domain (name **cpp**) supports documenting C++ projects. The C++ domain (name **cpp**) supports documenting C++ projects.
Directives for Declaring Entities Directives for Declaring Entities
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ---------------------------------
The following directives are available. All declarations can start with a The following directives are available. All declarations can start with a
visibility statement (``public``, ``private`` or ``protected``). visibility statement (``public``, ``private`` or ``protected``).
@ -247,7 +248,7 @@ visibility statement (``public``, ``private`` or ``protected``).
Options Options
^^^^^^^ ~~~~~~~
Some directives support options: Some directives support options:
@ -258,7 +259,7 @@ Some directives support options:
.. versionadded:: 1.6 .. versionadded:: 1.6
Anonymous Entities Anonymous Entities
~~~~~~~~~~~~~~~~~~ ------------------
C++ supports anonymous namespaces, classes, enums, and unions. C++ supports anonymous namespaces, classes, enums, and unions.
For the sake of documentation they must be given some name that starts with For the sake of documentation they must be given some name that starts with
@ -304,7 +305,7 @@ Explicit ref: :cpp:var:`Data::@data::a`. Short-hand ref: :cpp:var:`Data::a`.
Aliasing Declarations Aliasing Declarations
~~~~~~~~~~~~~~~~~~~~~ ---------------------
Sometimes it may be helpful list declarations elsewhere than their main Sometimes it may be helpful list declarations elsewhere than their main
documentation, e.g., when creating a synopsis of a class interface. documentation, e.g., when creating a synopsis of a class interface.
@ -359,7 +360,7 @@ The following directive can be used for this purpose.
Constrained Templates Constrained Templates
~~~~~~~~~~~~~~~~~~~~~ ---------------------
.. warning:: The support for concepts is experimental. It is based on the .. warning:: The support for concepts is experimental. It is based on the
current draft standard and the Concepts Technical Specification. current draft standard and the Concepts Technical Specification.
@ -368,7 +369,7 @@ Constrained Templates
.. note:: Sphinx does not currently support ``requires`` clauses. .. note:: Sphinx does not currently support ``requires`` clauses.
Placeholders Placeholders
^^^^^^^^^^^^ ~~~~~~~~~~~~
Declarations may use the name of a concept to introduce constrained template Declarations may use the name of a concept to introduce constrained template
parameters, or the keyword ``auto`` to introduce unconstrained template parameters, or the keyword ``auto`` to introduce unconstrained template
@ -384,7 +385,7 @@ parameters::
Iterator concept. Iterator concept.
Template Introductions Template Introductions
^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~
Simple constrained function or class templates can be declared with a `template Simple constrained function or class templates can be declared with a `template
introduction` instead of a template parameter list:: introduction` instead of a template parameter list::
@ -419,7 +420,7 @@ compatibility. E.g., ``Iterator{A, B, C}`` will be accepted as an introduction
even though it would not be valid C++. even though it would not be valid C++.
Inline Expressions and Types Inline Expressions and Types
~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ----------------------------
.. rst:role:: cpp:expr .. rst:role:: cpp:expr
cpp:texpr cpp:texpr
@ -458,7 +459,7 @@ Inline Expressions and Types
The :rst:role:`cpp:texpr` role. The :rst:role:`cpp:texpr` role.
Namespacing Namespacing
~~~~~~~~~~~ -----------
Declarations in the C++ domain are as default placed in global scope. The Declarations in the C++ domain are as default placed in global scope. The
current scope can be changed using three namespace directives. They manage a current scope can be changed using three namespace directives. They manage a
@ -544,7 +545,7 @@ The ``cpp:namespace-pop`` directive undoes the most recent
.. versionadded:: 1.4 .. versionadded:: 1.4
Info field lists Info field lists
~~~~~~~~~~~~~~~~~ ----------------
All the C++ directives for declaring entities support the following All the C++ directives for declaring entities support the following
info fields (see also :ref:`info-field-lists`): info fields (see also :ref:`info-field-lists`):
@ -566,7 +567,7 @@ following fields:
.. _cpp-roles: .. _cpp-roles:
Cross-referencing Cross-referencing
~~~~~~~~~~~~~~~~~ -----------------
These roles link to the given declaration types: These roles link to the given declaration types:
@ -602,14 +603,14 @@ These roles link to the given declaration types:
angle brackets do not need escaping. angle brackets do not need escaping.
Declarations without template parameters and template arguments Declarations without template parameters and template arguments
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
For linking to non-templated declarations the name must be a nested name, e.g., For linking to non-templated declarations the name must be a nested name, e.g.,
``f`` or ``MyClass::f``. ``f`` or ``MyClass::f``.
Overloaded (member) functions Overloaded (member) functions
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
When a (member) function is referenced using just its name, the reference When a (member) function is referenced using just its name, the reference
will point to an arbitrary matching overload. will point to an arbitrary matching overload.
@ -643,7 +644,7 @@ does not influence specific overload references.
Templated declarations Templated declarations
^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~
Assume the following declarations. Assume the following declarations.
@ -680,7 +681,7 @@ This means the following references work as well:
(:cpp:class:`template\<typename TInner> Wrapper::Outer::Inner`) (:cpp:class:`template\<typename TInner> Wrapper::Outer::Inner`)
(Full) Template Specialisations (Full) Template Specialisations
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Assume the following declarations. Assume the following declarations.
@ -709,7 +710,7 @@ shorthand the empty template parameter list can be omitted, e.g.,
(:cpp:class:`Outer\<int>::Inner\<bool>`). (:cpp:class:`Outer\<int>::Inner\<bool>`).
Partial Template Specialisations Partial Template Specialisations
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Assume the following declaration. Assume the following declaration.
@ -722,6 +723,6 @@ parameter lists, e.g., ``template\<typename T> Outer\<T*>``
succeed if the template parameter identifiers are equal strings. succeed if the template parameter identifiers are equal strings.
Configuration Variables Configuration Variables
~~~~~~~~~~~~~~~~~~~~~~~ -----------------------
See :ref:`cpp-config`. See :ref:`cpp-config`.

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
=====================
The JavaScript Domain The JavaScript Domain
--------------------- =====================
The JavaScript domain (name **js**) provides the following directives: The JavaScript domain (name **js**) provides the following directives:

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
======================
The Mathematics Domain The Mathematics Domain
---------------------- ======================
The math domain (name **math**) provides the following roles: The math domain (name **math**) provides the following roles:

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
=================
The Python Domain The Python Domain
----------------- =================
The Python domain (name **py**) provides the following directives for module The Python domain (name **py**) provides the following directives for module
declarations: declarations:
@ -468,7 +469,7 @@ The following directives are provided for module and class contents:
.. _signatures: .. _signatures:
Python Signatures Python Signatures
~~~~~~~~~~~~~~~~~ -----------------
Signatures of functions, methods and class constructors can be given like they Signatures of functions, methods and class constructors can be given like they
would be written in Python. would be written in Python.
@ -512,7 +513,7 @@ See :pep:`695` and :pep:`696` for details and the full specification.
.. _info-field-lists: .. _info-field-lists:
Info field lists Info field lists
~~~~~~~~~~~~~~~~ ----------------
.. versionadded:: 0.4 .. versionadded:: 0.4
.. versionchanged:: 3.0 .. versionchanged:: 3.0
@ -603,7 +604,7 @@ word "or"::
.. _python-roles: .. _python-roles:
Cross-referencing Python objects Cross-referencing Python objects
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ --------------------------------
The following roles refer to objects in modules and are possibly hyperlinked if The following roles refer to objects in modules and are possibly hyperlinked if
a matching identifier is found: a matching identifier is found:

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
===========================
The reStructuredText Domain The reStructuredText Domain
--------------------------- ===========================
The reStructuredText domain (name **rst**) provides the following directives: The reStructuredText domain (name **rst**) provides the following directives:

View File

@ -1,7 +1,8 @@
.. highlight:: rst .. highlight:: rst
===================
The Standard Domain The Standard Domain
------------------- ===================
The so-called "standard" domain collects all markup that doesn't warrant a The so-called "standard" domain collects all markup that doesn't warrant a
domain of its own. Its directives and roles are not prefixed with a domain domain of its own. Its directives and roles are not prefixed with a domain