This commit also adds means to manually disable warnings
in `code` tags where it's a false positive with the new
`skip-lint` attribute.
Warnings are now enabled on CI to prevent future errors.
We don't use that info for anything, and it generates unnecessary diffs
every time we bump the minor version (and CI failures if we forget to
sync some files from opt-in modules (mono, text_server_fb).
Adds a check to make_rst to look for matches
between the text inside of the [code][/code] tag
and known param identifiers.
Fixes most of what was revealed.
This helps to find such classes without digging
through the rest of the class reference.
Editor-only classes can still be found under
your normal "Node" and "Resource" types.
This also fixes a typo and a missed case from the recent platform docs PR.
- General improvements to the page layout
- Improved formatting for all class (properties, signals, annotations, theme properties, methods, operators, constructors, enumerations, constants)
- Added extra styling opportunities throughout the generated document
- Made generated tables more flexible to their content
- Changed highlighting for self-reference from code to strong
Before this change, API docs that look like this:
…adding [param character]s to the right of the string.
would turn into rst files that look like this:
…adding ``character``s to the right of the string.
That reStructuredText is invalid and causes warnings when the docs repo
is built.
Since Python 3.5+ is required, we can use proper type hints based on PEP 484. Because we are working on contributor tooling we can assume 3.6+ and use PEP 526 for variable declarations as well.
When generating rst files from xml class reference, unknown references
to operators were generated, as something like:
:ref:`operator <<class_Vector2_operator_lt_bool>`
was rendered in html as:
operator ( Vector2 right )
-it just needed escaping.
The small addendum checks for operator names containing '<' and
substitutes it with '\<', escaping at rst level and generating
instead the right rendered html:
operator < ( Vector2 right )
This affected mostly the reference pages of the VectorX family of
classes. If in the future more types need escaping, a more
general solution will be needed.
This is automatically enabled on all platforms including
Windows 10 and later, whenever a TTY environment is detected.
In non-TTY environments such as CI, this can be forced using the
`--color` command line argument.
When converting doc xml files to rst, add an indenation level to bullet points in the text description of enum values.
Also add check to avoid out of bounds error in rstize_text.
- List file names before error descriptions, as is common in linters.
- Print the number of errors reported at the end of the list.
- Use double quotes instead of single quotes in messages.
Using codespell 2.2-dev from current git.
Added `misc/scripts/codespell.sh` to make it easier to run it once in a
while and update the skip and ignore lists.