diff options
author | Campbell Barton <campbell@blender.org> | 2022-09-19 07:22:31 +0300 |
---|---|---|
committer | Campbell Barton <campbell@blender.org> | 2022-09-19 07:24:31 +0300 |
commit | 4baa6e57bd4240e0dab1e2a1b426698ca4d593bc (patch) | |
tree | 8c9af26e0dbda778263f677c99ece9de0af7c61a /release/scripts/modules | |
parent | 8a9f6a2e0a15ed6d5fcab7030249f0211b667d60 (diff) |
Cleanup: prefer 'arg' over 'params' for sphinx documentation
While both are supported, 'arg' is in more common use so prefer it.
Diffstat (limited to 'release/scripts/modules')
4 files changed, 28 insertions, 28 deletions
diff --git a/release/scripts/modules/bl_console_utils/autocomplete/complete_calltip.py b/release/scripts/modules/bl_console_utils/autocomplete/complete_calltip.py index 07ccac81f91..419a6dc9852 100644 --- a/release/scripts/modules/bl_console_utils/autocomplete/complete_calltip.py +++ b/release/scripts/modules/bl_console_utils/autocomplete/complete_calltip.py @@ -29,7 +29,7 @@ RE_DEF_COMPLETE = re.compile( def reduce_newlines(text): """Reduces multiple newlines to a single newline. - :param text: text with multiple newlines + :arg text: text with multiple newlines :type text: str :returns: text with single newlines :rtype: str @@ -43,7 +43,7 @@ def reduce_newlines(text): def reduce_spaces(text): """Reduces multiple whitespaces to a single space. - :param text: text with multiple spaces + :arg text: text with multiple spaces :type text: str :returns: text with single spaces :rtype: str @@ -57,7 +57,7 @@ def reduce_spaces(text): def get_doc(obj): """Get the doc string or comments for an object. - :param object: object + :arg object: object :returns: doc string :rtype: str @@ -71,11 +71,11 @@ def get_doc(obj): def get_argspec(func, *, strip_self=True, doc=None, source=None): """Get argument specifications. - :param strip_self: strip `self` from argspec + :arg strip_self: strip `self` from argspec :type strip_self: bool - :param doc: doc string of func (optional) + :arg doc: doc string of func (optional) :type doc: str - :param source: source code of func (optional) + :arg source: source code of func (optional) :type source: str :returns: argument specification :rtype: str @@ -131,11 +131,11 @@ def get_argspec(func, *, strip_self=True, doc=None, source=None): def complete(line, cursor, namespace): """Complete callable with calltip. - :param line: incomplete text line + :arg line: incomplete text line :type line: str - :param cursor: current character position + :arg cursor: current character position :type cursor: int - :param namespace: namespace + :arg namespace: namespace :type namespace: dict :returns: (matches, world, scrollback) :rtype: (list of str, str, str) diff --git a/release/scripts/modules/bl_console_utils/autocomplete/complete_import.py b/release/scripts/modules/bl_console_utils/autocomplete/complete_import.py index 1a97e408b70..c506e674cd5 100644 --- a/release/scripts/modules/bl_console_utils/autocomplete/complete_import.py +++ b/release/scripts/modules/bl_console_utils/autocomplete/complete_import.py @@ -76,7 +76,7 @@ def module_list(path): Return the list containing the names of the modules available in the given folder. - :param path: folder path + :arg path: folder path :type path: str :returns: modules :rtype: list @@ -107,7 +107,7 @@ def complete(line): """ Returns a list containing the completion possibilities for an import line. - :param line: + :arg line: incomplete line which contains an import statement:: diff --git a/release/scripts/modules/bl_console_utils/autocomplete/complete_namespace.py b/release/scripts/modules/bl_console_utils/autocomplete/complete_namespace.py index 096e5596fc6..b1b751c96ab 100644 --- a/release/scripts/modules/bl_console_utils/autocomplete/complete_namespace.py +++ b/release/scripts/modules/bl_console_utils/autocomplete/complete_namespace.py @@ -27,9 +27,9 @@ def is_struct_seq(obj): def complete_names(word, namespace): """Complete variable names or attributes - :param word: word to be completed + :arg word: word to be completed :type word: str - :param namespace: namespace + :arg namespace: namespace :type namespace: dict :returns: completion matches :rtype: list of str @@ -50,12 +50,12 @@ def complete_indices(word, namespace, *, obj=None, base=None): * integer numbers for list * any keys for dictionary - :param word: word to be completed + :arg word: word to be completed :type word: str - :param namespace: namespace + :arg namespace: namespace :type namespace: dict - :param obj: object evaluated from base - :param base: sub-string which can be evaluated into an object. + :arg obj: object evaluated from base + :arg base: sub-string which can be evaluated into an object. :type base: str :returns: completion matches :rtype: list of str @@ -103,11 +103,11 @@ def complete(word, namespace, *, private=True): """Complete word within a namespace with the standard rlcompleter module. Also supports index or key access []. - :param word: word to be completed + :arg word: word to be completed :type word: str - :param namespace: namespace + :arg namespace: namespace :type namespace: dict - :param private: whether private attribute/methods should be returned + :arg private: whether private attribute/methods should be returned :type private: bool :returns: completion matches :rtype: list of str diff --git a/release/scripts/modules/bl_console_utils/autocomplete/intellisense.py b/release/scripts/modules/bl_console_utils/autocomplete/intellisense.py index e53e38dbc53..7aff3596c42 100644 --- a/release/scripts/modules/bl_console_utils/autocomplete/intellisense.py +++ b/release/scripts/modules/bl_console_utils/autocomplete/intellisense.py @@ -43,13 +43,13 @@ def complete(line, cursor, namespace, private): * index completion for lists and dictionaries * module completion (from/import) - :param line: incomplete text line + :arg line: incomplete text line :type line: str - :param cursor: current character position + :arg cursor: current character position :type cursor: int - :param namespace: namespace + :arg namespace: namespace :type namespace: dict - :param private: whether private variables should be listed + :arg private: whether private variables should be listed :type private: bool :returns: list of completions, word :rtype: list, str @@ -82,13 +82,13 @@ def expand(line, cursor, namespace, *, private=True): """This method is invoked when the user asks autocompletion, e.g. when Ctrl+Space is clicked. - :param line: incomplete text line + :arg line: incomplete text line :type line: str - :param cursor: current character position + :arg cursor: current character position :type cursor: int - :param namespace: namespace + :arg namespace: namespace :type namespace: dict - :param private: whether private variables should be listed + :arg private: whether private variables should be listed :type private: bool :returns: |