Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix appearance of class docstrings, constructor methods, ... #167

Merged
merged 10 commits into from
Aug 27, 2024

Conversation

nyalldawson
Copy link
Contributor

This PR results in a lot of improvements 😄

It's directed at fixing this:

image

Where:

  1. The constructors just get dumped as part of the class description, making the text confusing to read
  2. The way the constructors just appear as plain text, not functions

Now:

Class description shows at the top of the page:

image

While constructors are nicely documented + formatted before the other methods:

image

It also fixes this issue, where the notes block format leaks into the table of contents:

image

Now it's correctly formatted:

image

Since SIP appends the constructor docs to the end of the class
docstring, use a hacky approach to re-split these off. This
allows us to put the actual class documentation at the top of
the page, leaving the constructor/__init__ docs to sit nicely
just under the method listings.
These aren't linked anywhere, and cause sphinx warnings because we have multiple __init__ methods for MANY classes
@3nids 3nids merged commit 22be803 into qgis:main Aug 27, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants