Commit Graph

27 Commits

Author SHA1 Message Date
Adam Turner
7b570c06a1 Standardise on a common directive for describing code snippets 2024-07-15 02:15:52 +01:00
Adam Turner
f2640a4286 Standardise on "reStructuredText" over "reST" in documentation 2024-07-15 02:15:52 +01:00
Adam Turner
26576590ed Make the domain referencing role targets more specific 2024-07-15 01:59:42 +01:00
Tim Hoffmann
a95d716f7f
Add a class option to the toctree directive (#12524)
Co-authored-by: Adam Turner <9087854+AA-Turner@users.noreply.github.com>
2024-07-10 11:07:49 +01:00
Bénédikt Tran
f44ff30673
[doc] cleanup references and update external URLs (#12182) 2024-03-25 11:39:05 +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
Hugo van Kemenade
7f62f539be
Correct the Python Developer Guide markup style advice link (#11189) 2023-02-11 13:19:51 +00:00
Hugo van Kemenade
dc29bf9abe
Docs: Update devguide link (#11017)
Update devguide link
2022-12-16 16:42:11 +01:00
Jean-François B
e7c0881992
LaTeX: support for booktabs-style and zebra-striped tables (#10759)
This is a combination of 2 + 28 + 7 + and some more commits...

* Cherry-pick: Add support for booktabs-style tables to LaTeX builder

* Cherry-pick: Add support for zebra-striped tables to LaTeX builder

Co-authored-by: Stefan Wiehler <stefan.wiehler@missinglinkelectronics.com>

Above work originally initiated by @sephalon (thanks!)

Development refactored and continued by @jfbu

* latex_table_style configuration, support booktabs, colorrows, borderless

Some details:

- Simplify a bit a conditional in the longtable template

  This also puts the target for a longtable with a label but no caption
  above the toprule for better hyperlinking (testing shows hyperlink
  target can not end up alone at bottom of previous page).

- Extend allowed syntax for colour assignments via 'sphinxsetup'

- latex_table_style new configuration value and coloured rows

  For the user interface I tried to look for inspiration in
  https://docutils.sourceforge.io/docs/user/config.html#table-style
  which mentions booktabs and borderless.  They also mention
  captionbelow which we can implement later, now that architecture
  is here.  They don't mention coloured rows.

- Test on our own document... looks fine!

- Work-around an incompatibility of \cline with row colours

- Reverse priority of classes to allow overruling booktabs by standard
  after parsing source but before letting LaTeX writer act

- Closes #8220

  Commit
  bb859c6696
  already improved a bit, this finishes it (as :rst:dir:`rst-class` was
  actually not linking to anywhere).

- Let booktabs style defaults to *not* using \cmidrule.  They actually
  don't make much sense there, as all \hline's are removed.

- Add \sphinxnorowcolor which allows construct such as this one in
  a tabularcolumns directive:

    >{\columncolor{blue}\sphinxnorowcolor}

  else LaTeX always overrides column colour by row colour

- Add TableMergeColorHeader, TableMergeColorOdd, TableMergeColorEven
  so single-row merged cells can be styled especially

- Extend row colours to all header rows not only the first one
  (all header rows will share same colour settings)

- Auto-adjust to a no '|'-colspec for optimal handling of merged cell

- Add \sphinxcolorblend

- Workaround LaTeX's \cline features and other grid tables matters

- Add \sphinxbuildwarning for important warnings

- Fix some white gaps in merged cells of tables with vlines and
  colorrows

- Work around LaTeX's \cline serious deficiencies for complex grid
  tables

  This commit corrects \cline badly impacting vertical spacing and
  making tables look even more cramped as they usually are in LaTeX
  (although one sees it clearly only with \arrarrulewidth a bit more
  than the LaTeX default of 0.4pt).

  Most importantly this commit solves the problem that \cline's got
  masked by colour panels from the row below.

- Update CHANGES for PR #10759

- Improve documentation of new latex_table_style regarding colours
2022-10-12 17:15:40 +02:00
Noah Sprent
25c4287da5
Remove commas when describing characters for section headings 2022-02-02 10:52:06 +01:00
Latosha Maltba
ee3f361992 Document indent behaviour for directives
Mention how the indent of the contents for directives is chosen and what
the effect on directives which are sensitive to whitespace is,
e.g. code-block.
2021-09-27 09:06:52 +00:00
Juan Luis Cano Rodríguez
57b0a1b465 Add section about the toctree 2021-06-17 00:31:53 +02:00
igo95862
e67c9e5df1
doc: Upgrade docutils.sourceforge.io links to HTTPS
Also change any docutils.sourceforge.net link to io
top level domain.
2021-05-16 15:53:49 +03:00
Ebram Shehata
df2d4839c4
Update basics.rst 2020-07-29 15:14:29 +02:00
Michaël Defferrard
5e5bd748e6
remove repeted word in reStructuredText Primer 2020-05-20 22:30:58 +02:00
Timotheus Kampik
0662a3ecd6
#6503 document meta directive (#6562)
#6503 document meta directive

The `meta` directive has partly Sphinx-specific behavior
and hence needs to be documented
2019-07-08 22:48:41 +02:00
Stephen Finucane
b595c4a45b doc: Add "builders" to usage guide
This is placed in a directory as this document will eventually be split
up. However, this is not the day to do this.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-06-20 09:26:59 +01:00
Takeshi KOMIYA
8e6c04c630
Merge branch 'master' into deprecate_highlightlang_directive 2018-04-29 21:13:13 +09:00
Takeshi KOMIYA
b35198d847 Deprecate highlightlang directive
highlightlang directive is not documented, and marked as old in v0.2.
2018-04-15 00:33:02 +09:00
Gussie Carther
390ea6d35a Fix #4420: Docs conflict on use of rst_prolog and rst_epilog 2018-04-14 17:51:06 +09:00
jfbu
525f3bd104 Typo from #4801 2018-04-01 11:39:58 +02:00
Tim Graham
725d20b0f9 Add section labels for intersphinx 2018-03-29 13:23:39 -04:00
Stephen Finucane
893a7ac1f2 doc: Rework "showing code" section
This makes the section more consistent with the rest of the document.
This adds a new section to the basics guide for doctest blocks, which
are a docutils thing. It also update the default highlight language,
which is now 'default'.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-03-27 15:37:28 +01:00
Stephen Finucane
fdf91e502c doc: Add "directives" doc to restructuredtext section
There's simply no need to artificially divide up the documentation on
directives into multiple, hard-to-navigate documents. Gather all
documentation for directives into one easy-to-reference guide, starting
with the former 'toctree' document. There are no changes to the content.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-03-27 15:37:28 +01:00
Stephen Finucane
08ff8160b8 doc: Add "field-lists" doc to restructuredtext section
These are very poorly documented at present, especially given their
power and use in basically all non-Napoleon based Python documentation.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-03-27 15:37:25 +01:00
Stephen Finucane
3fcb1bd2dd doc: Add "roles" doc to restructuredtext section
This is essentially the 'markup/inline' with a few small fixes. There
are also some modifications to the basic rST guide to highlight what a
role is; we were doing this for directives but not roles.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-03-27 15:34:36 +01:00
Stephen Finucane
9c2ab8c3bb doc: Add "restructuredtext" section to usage guide
This is taken from the existing 'rest' documents. Little to no
modifications are necessary, thankfully.

Signed-off-by: Stephen Finucane <stephen@that.guru>
2018-03-27 15:34:26 +01:00