@@ -639,8 +639,9 @@ def add_directive(self, name: str, cls: Type[Directive], override: bool = False)
639639
640640 :param name: The name of the directive
641641 :param cls: A directive class
642- :param override: If true, install the directive forcedly even if another directive
642+ :param override: If false, do not install it if another directive
643643 is already installed as the same name
644+ If true, unconditionally install the directive.
644645
645646 For example, a custom directive named ``my-directive`` would be added
646647 like this:
@@ -687,8 +688,9 @@ def add_role(self, name: str, role: Any, override: bool = False) -> None:
687688
688689 :param name: The name of role
689690 :param role: A role function
690- :param override: If true, install the role forcedly even if another role is already
691- installed as the same name
691+ :param override: If false, do not install it if another role
692+ is already installed as the same name
693+ If true, unconditionally install the role.
692694
693695 For more details about role functions, see `the Docutils docs
694696 <https://docutils.sourceforge.io/docs/howto/rst-roles.html>`__ .
@@ -708,8 +710,9 @@ def add_generic_role(self, name: str, nodeclass: Any, override: bool = False) ->
708710 Register a Docutils role that does nothing but wrap its contents in the
709711 node given by *nodeclass*.
710712
711- If *override* is True, the given *nodeclass* is forcedly installed even if
712- a role named as *name* is already installed.
713+ :param override: If false, do not install it if another role
714+ is already installed as the same name
715+ If true, unconditionally install the role.
713716
714717 .. versionadded:: 0.6
715718 .. versionchanged:: 1.8
@@ -728,8 +731,9 @@ def add_domain(self, domain: Type[Domain], override: bool = False) -> None:
728731 """Register a domain.
729732
730733 :param domain: A domain class
731- :param override: If true, install the domain forcedly even if another domain
734+ :param override: If false, do not install it if another domain
732735 is already installed as the same name
736+ If true, unconditionally install the domain.
733737
734738 .. versionadded:: 1.0
735739 .. versionchanged:: 1.8
@@ -747,8 +751,9 @@ def add_directive_to_domain(self, domain: str, name: str,
747751 :param domain: The name of target domain
748752 :param name: A name of directive
749753 :param cls: A directive class
750- :param override: If true, install the directive forcedly even if another directive
754+ :param override: If false, do not install it if another directive
751755 is already installed as the same name
756+ If true, unconditionally install the directive.
752757
753758 .. versionadded:: 1.0
754759 .. versionchanged:: 1.8
@@ -766,8 +771,9 @@ def add_role_to_domain(self, domain: str, name: str, role: Union[RoleFunction, X
766771 :param domain: The name of the target domain
767772 :param name: The name of the role
768773 :param role: The role function
769- :param override: If true, install the role forcedly even if another role is already
770- installed as the same name
774+ :param override: If false, do not install it if another role
775+ is already installed as the same name
776+ If true, unconditionally install the role.
771777
772778 .. versionadded:: 1.0
773779 .. versionchanged:: 1.8
@@ -783,8 +789,9 @@ def add_index_to_domain(self, domain: str, index: Type[Index], override: bool =
783789
784790 :param domain: The name of the target domain
785791 :param index: The index class
786- :param override: If true, install the index forcedly even if another index is
787- already installed as the same name
792+ :param override: If false, do not install it if another index
793+ is already installed as the same name
794+ If true, unconditionally install the index.
788795
789796 .. versionadded:: 1.0
790797 .. versionchanged:: 1.8
@@ -889,8 +896,10 @@ def add_crossref_type(self, directivename: str, rolename: str, indextemplate: st
889896 (Of course, the element following the ``topic`` directive needn't be a
890897 section.)
891898
892- If *override* is True, the given crossref_type is forcedly installed even if
893- a crossref_type having the same name is already installed.
899+
900+ :param override: If false, do not install it if another cross-reference type
901+ is already installed as the same name
902+ If true, unconditionally install the cross-reference type.
894903
895904 .. versionchanged:: 1.8
896905 Add *override* keyword.
@@ -949,20 +958,22 @@ def add_js_file(self, filename: Optional[str], priority: int = 500,
949958 loading_method : Optional [str ] = None , ** kwargs : Any ) -> None :
950959 """Register a JavaScript file to include in the HTML output.
951960
952- :param filename: The filename of the JavaScript file. It must be relative to the HTML
953- static path, a full URI with scheme, or ``None`` value. The ``None``
954- value is used to create inline ``<script>`` tag. See the description
955- of *kwargs* below.
956- :param priority: The priority to determine the order of ``<script>`` tag for
957- JavaScript files. See list of "prority range for JavaScript
958- files" below. If the priority of the JavaScript files it the same
959- as others, the JavaScript files will be loaded in order of
960- registration.
961- :param loading_method: The loading method of the JavaScript file. ``'async'`` or
962- ``'defer'`` is allowed.
963- :param kwargs: Extra keyword arguments are included as attributes of the ``<script>``
964- tag. A special keyword argument ``body`` is given, its value will be
965- added between the ``<script>`` tag.
961+ :param filename: The name of a JavaScript file that the default HTML
962+ template will include. It must be relative to the HTML
963+ static path, or a full URI with scheme, or ``None`` .
964+ The ``None`` value is used to create an inline
965+ ``<script>`` tag. See the description of *kwargs*
966+ below.
967+ :param priority: Files are included in ascending order of priority. If
968+ multiple JavaScript files have the same priority,
969+ those files will be included in order of registration.
970+ See list of "prority range for JavaScript files" below.
971+ :param loading_method: The loading method for the JavaScript file.
972+ Either ``'async'`` or ``'defer'`` are allowed.
973+ :param kwargs: Extra keyword arguments are included as attributes of the
974+ ``<script>`` tag. If the special keyword argument
975+ ``body`` is given, its value will be added as the content
976+ of the ``<script>`` tag.
966977
967978 Example::
968979
@@ -1015,14 +1026,15 @@ def add_js_file(self, filename: Optional[str], priority: int = 500,
10151026 def add_css_file (self , filename : str , priority : int = 500 , ** kwargs : Any ) -> None :
10161027 """Register a stylesheet to include in the HTML output.
10171028
1018- :param filename: The filename of the CSS file. It must be relative to the HTML
1029+ :param filename: The name of a CSS file that the default HTML
1030+ template will include. It must be relative to the HTML
10191031 static path, or a full URI with scheme.
1020- :param priority: The priority to determine the order of ``<link>`` tag for the
1021- CSS files. See list of "prority range for CSS files" below.
1022- If the priority of the CSS files it the same as others, the
1023- CSS files will be loaded in order of registration .
1024- :param kwargs: Extra keyword arguments are included as attributes of the ``<link>``
1025- tag.
1032+ :param priority: Files are included in ascending order of priority. If
1033+ multiple CSS files have the same priority,
1034+ those files will be included in order of registration.
1035+ See list of "prority range for CSS files" below .
1036+ :param kwargs: Extra keyword arguments are included as attributes of the
1037+ ``<link>`` tag.
10261038
10271039 Example::
10281040
@@ -1191,8 +1203,9 @@ def add_source_suffix(self, suffix: str, filetype: str, override: bool = False)
11911203 Same as :confval:`source_suffix`. The users can override this
11921204 using the config setting.
11931205
1194- If *override* is True, the given *suffix* is forcedly installed even if
1195- the same suffix is already installed.
1206+ :param override: If false, do not install it the same suffix
1207+ is already installed.
1208+ If true, unconditionally install the suffix.
11961209
11971210 .. versionadded:: 1.8
11981211 """
@@ -1201,8 +1214,9 @@ def add_source_suffix(self, suffix: str, filetype: str, override: bool = False)
12011214 def add_source_parser (self , parser : Type [Parser ], override : bool = False ) -> None :
12021215 """Register a parser class.
12031216
1204- If *override* is True, the given *parser* is forcedly installed even if
1205- a parser for the same suffix is already installed.
1217+ :param override: If false, do not install it if another parser
1218+ is already installed for the same suffix.
1219+ If true, unconditionally install the parser.
12061220
12071221 .. versionadded:: 1.4
12081222 .. versionchanged:: 1.8
0 commit comments