Commit Graph

313 Commits

Author SHA1 Message Date
Rafael Fontenelle
2ccae70089
[docs] Fix typos in autodoc.rst (#12469) 2024-06-24 14:48:54 +02:00
Chris Sewell
8f97fd276a
[docs] Improve landing page (#12453)
This commit is intended to improve new user's first-interaction with the Sphinx site:

- Make page header icon/text smaller and not capitalized
- Give min-width to left sidebar (it was getting too small at certain window sizes)
- Replace features list on landing page with admonition boxes, with adaptive layout
- Add landing page "used by" section
- Slightly restructure the Extension section, into Tutorials and How-tos
- Add code to `conf.py` to write HTML write redirect pages for moved documents
- Improve support page, by adding link to Stackoverflow, GH discussion and ReadtheDocs,
  and remove defunct link to libera chat and matplotlib tutorial
2024-06-21 20:12:57 +02:00
Tim Hoffmann
1e77e6bc9a
DOC: Move autodoc setup/usage to extension docs (#12435)
Leaving just the link in the quickstart guide
2024-06-17 11:58:55 +02:00
Tim Hoffmann
4fbd3682d5
DOC: Add autodoc section "Ensuring the code can be imported" (#12426)
This explains the requirements for importablilty (can be found and dependencies can be resolved). It also explains two common approaches how this can be achieved.
2024-06-12 11:43:33 +02:00
Françoise Conil
5fc2d515fd
Fix debug option in autosectionlabel documentation (#12324)
Co-authored-by: Françoise Conil <francoise.conil@insa-lyon.fr>
2024-04-24 18:59:30 +01:00
Bénédikt Tran
f44ff30673
[doc] cleanup references and update external URLs (#12182) 2024-03-25 11:39:05 +01:00
Chris Sewell
3bedde26a9
🔧 Ruff format python files within docs folder (#12139)
Remove `docs` files from the `exclude` list, and also add the `preview = false` format config, which is shown to reduce diffs to the current code base
2024-03-19 15:23:57 +01:00
Chris Sewell
565d4104d5
👌 Handle external references pointing to object types (#12133)
This commit fixes the issue of `objects.inv` denoting object names, whilst the `external` role only allows for role names. 

As an example, take the `objects.inv` for the sphinx documentation, which contains:

```
py:function
    compile                  : usage/domains/python.html#compile
```

A user might understandably expect that they could reference this using `` :external:py:function:`compile` ``, but actually this would previously error with:

```
WARNING: role for external cross-reference not found: py:function
```

this is because, `function` is the object type, yet `external` expects the related role name `func`.

It should not be necessary for the user to know about this distinction,
so in this commit, we add logic, to first look if the name relates to a role name (as previous, to not be back-breaking) but, if not, then also look if the name relates to an object that has a known role and, if so, use that.

Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
2024-03-19 13:42:50 +01:00
Bénédikt Tran
b2069fb64f
[lint] update Makefile and lint doc (#12117) 2024-03-17 14:45:56 +01:00
Adam Turner
23cef9b59a Use `https://` where possible 2024-01-14 04:18:57 +00:00
Dimitri Papadopoulos Orfanos
460a63010f
Fix various spelling errors (#11735) 2024-01-04 02:37:44 +00:00
Adam Turner
b935915c57
Improve make-mode documentation (#11692) 2023-09-21 09:39:39 +01:00
Adam Turner
1cfb68d8be
Consistently name the object description options (#11533)
*  The directive option ``:noindex:`` was renamed to ``:no-index:``.
*  The directive option ``:noindexentry:`` was renamed to ``:no-index-entry:``.
*  The directive option ``:nocontentsentry:`` was renamed to ``:no-contents-entry:``.

The previous names are retained as aliases, but will be deprecated
and removed in a future version of Sphinx (9.0 or later).
2023-07-28 22:30:26 +01:00
Adam Turner
ff20efcd7e
Tweaks to `doctest_show_successes` (#11535) 2023-07-28 22:29:04 +01:00
benkrikler
762ed8540a
Add line numbers in `sphinx.ext.viewdoc` (#6319)
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
2023-07-28 05:52:48 +01:00
Jorge Leitao
99f9209924
Add summary statistics to the coverage report (#5474)
The current implementation of ``sphinx.ext.coverage`` outputs which
methods,classes, and functions are documented.
This commit adds a short summary of this report in terms of
``documented objects / total number of objects``,
both per module and total.

The purpose of this is to support
a currently not mainstream but relevant use-case:
a coverage report on the number of objects that are documented.

By having the statistics on the report or on the stdout,
a regex expression can capture the coverage percentage
(e.g. ``re.search(r'TOTAL.*?([0-9.]{4,6}\%)', d).group(1)``)
and use it e.g. in another report, a status badge, etc.

Two options were added to the configuration to allow a table
to be printed in the report and/or to stdout.

Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2023-07-28 02:33:42 +01:00
Adam Turner
ad61e41157
Drop support for Python 3.8 (#11511) 2023-07-25 02:07:23 +01:00
Adam Turner
7ecf037280 Enable 'nit-picky mode' for Sphinx's documentation
Fix several reference errors throughout the documentation and set
``nitpick_ignore`` in ``doc/conf.py``.
2023-04-06 23:11:39 +01:00
Jean-François B
e1b15a5c11 Update doc and CHANGES for PR #11281 2023-04-03 11:12:41 +02:00
Benjamin Balder Bach
eda388a506
Docs: Add a link to sphinx-extensions (#11260) 2023-03-23 08:33:16 +01:00
Adam Turner
2902c6c55b
Deprecate legacy `intersphinx_mapping` format (#11247)
This format was made obsolete in Sphinx 1.0, but never formally deprecated.
2023-03-17 16:41:22 +00:00
Adam Turner
670bcb743b
Documentation reshuffle (#11112) 2023-01-08 13:52:36 +00:00
Tim Hoffmann
ec26c2f874
Document autosummary template variable "objtype" (#11044) 2023-01-02 18:38:17 +00:00
Adam Turner
920828fe35 Run the `pyupgrade` tool 2022-10-17 22:39:09 +01:00
Martin Patz
3e29abf8de
Add debug logging to autosectionlabel (#10881)
Co-authored-by: Martin Patz <martin@recogni.com>
2022-10-04 15:25:06 +01:00
Julien Schueller
ef01c5b6bd
imgmath: Allow embedding images in HTML as base64 (#10816)
Co-authored-by: Adam Turner <9087854+aa-turner@users.noreply.github.com>
2022-09-23 17:11:21 +01:00
Adam Turner
ee005caf22 Do not apply epigraph style to all block quotes
Correct indentation where appropriate for stanzas that should not be
rendered as `<blockquote>` HTML elements.

Closes GH-10686
2022-09-12 19:54:36 +01:00
Abdur-Rahmaan Janhangeer
59056aa781
Remove extra line (#10749)
Co-authored-by: Jean-François B. <2589111+jfbu@users.noreply.github.com>
2022-08-04 18:42:55 +02:00
marxin
9a30edac7d Fix indentation of .. version{changed,added}. 2022-07-19 15:26:57 +02:00
Adam Turner
70f950cae0
Remove traces of Python 2 and 3.5 (#10560) 2022-06-16 21:37:46 +01:00
Julien Palard
956cddb7d4
Replace doclinter with sphinx-lint (#10389)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2022-06-16 19:32:09 +01:00
Takeshi KOMIYA
cab2d93076
Merge pull request #10386 from mxd4/10384-comment-img-magick
Add comments on ImageMagick requirement
2022-05-22 19:22:24 +09:00
mxd4
33b5e23467
#10384 - Grammar 2022-05-02 13:56:51 +02:00
mxd4
4fc196a2a5
#10384 - Fix flake8 2022-05-02 12:26:16 +02:00
mxd4
4d840c790c
#10384 - Explicit warning and improve doc clarity 2022-05-02 12:18:30 +02:00
mxd4
d2d5ce4eb6
#10384 - Changes after suggestions 2022-05-02 11:29:11 +02:00
mxd4
85524b5817
#10384 - Add line break to fix docslint 2022-05-02 11:15:29 +02:00
mxd4
930056479f
#10384 - Add comment on ImageMagick requirement 2022-05-02 10:47:56 +02:00
Stefaan Lippens
b98b1b3419
sphinx.ext.napoleon docs: fix Google style link 2022-04-25 12:35:40 +02:00
Takeshi KOMIYA
da73960492 Merge branch '5.x' into autodoc_force_undocumented_rtype 2022-04-03 22:45:42 +09:00
Takeshi KOMIYA
fd42063725 autodoc_typehints_description_target: Rename returnvalue_and_documented_params to documented_params 2022-04-03 22:42:44 +09:00
Takeshi KOMIYA
f731bf1999 Merge branch '5.x' into autodoc_force_undocumented_rtype 2022-04-03 22:29:22 +09:00
Takeshi KOMIYA
21e3a96f09 Close #8417: autodoc: :inherited-members: option now takes multiple classes
It allows to suppress inherited members of several classes on the module at
once by specifying the option to `automodule` directive
2022-04-03 20:17:41 +09:00
Takeshi KOMIYA
2db180da70 Merge branch '4.x' 2022-03-27 19:47:11 +09:00
Takeshi KOMIYA
c6230dc4db extlinks: Disable hardcoded links detector by default (refs: #10126)
The hardcoded links detector added since 4.4.0 causes troubles in many
projects.  Therefore, this disables it by default, and adds a new
configuration `extlinks_detect_hardcoded_links` to enable it explicitly.
2022-03-27 15:22:11 +09:00
Takeshi KOMIYA
fbdfade068 doc: Use :pep: role to refer PEP documents 2022-03-27 01:46:22 +09:00
Hugo van Kemenade
a432bf8c10 Update PEP links in docs 2022-03-24 12:34:05 +02:00
Takeshi KOMIYA
f72cd83e4d Merge branch '4.x' 2022-02-19 16:08:05 +09:00
Takeshi KOMIYA
8b23f6db12 Merge commit '07110b7557a552ecfe702bdd6a2d2f9685cb1af9' 2022-02-14 03:03:40 +09:00
Takeshi KOMIYA
7469096e0a
Update doc/usage/extensions/autodoc.rst 2022-02-06 15:30:54 +09:00