Skip to content

Several small What's New fixes - #9259

Merged
tacaswell merged 5 commits into
matplotlib:v2.1.xfrom
QuLogic:whatsnew-fixes
Oct 2, 2017
Merged

tacaswell merged 5 commits into
matplotlib:v2.1.xfrom
QuLogic:whatsnew-fixes

Conversation

@QuLogic

@QuLogic QuLogic commented Oct 2, 2017

Copy link
Copy Markdown
Member

Fix cross-links to other parts of the documentation as well as add links in almost every entry. Change code bits from cross-references to code-styling.

Comment thread doc/users/whats_new.rst
limits allow for creating an annulus, a sector, or some combination of the two.

The :meth:`~matplotlib.axes.projections.polar.PolarAxes.set_rorigin` method may
The :meth:`~matplotlib.projections.polar.PolarAxes.set_rorigin` method may

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can get away (here and below) with omitting the :meth: because the current default role is :py:obj:.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Quite likely; I was a bit lazy and didn't change the existing ones, but generally didn't use any roles when adding the new links. There might be a slight difference with adding () for :func: and :meth:, though?

@anntzer anntzer Oct 2, 2017 •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

http://www.sphinx-doc.org/en/stable/domains.html#role-py:func
http://www.sphinx-doc.org/en/stable/config.html#confval-add_function_parentheses

Not sure whether it is set in conf.py right now, or whether py:obj respecsts that setting. If it doesn't we can just set add_function_parentheses to False.

Of course it's fine if you decide you don't want to mess with the markup, this is already an improvement...

EDIT: sphinx-doc/sphinx#171 suggests :py:obj: respects add_function_parentheses.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

When I tried the two options you gave below, the one with the :meth: role has parentheses while the one without doesn't.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably worth reporting as a Sphinx bug then?

Comment thread doc/users/whats_new.rst
Calling :func:`figure.legend` can now be done with no arguments. In this case a
legend will be created that contains all the artists on all the axes contained
within the figure.
Calling ``Figure.``:func:`~matplotlib.figure.Figure.legend` can now be

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does

`.Figure.legend`

or

:meth:`.Figure.legend`

work?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, I wasn't sure if we could use the leading dot, but it does work in this case.

@tacaswell

Copy link
Copy Markdown
Member

I am going to merge this as-is so I can rebase some re-organization I have been doing on top of it.

@tacaswell
tacaswell merged commit 72b75c9 into matplotlib:v2.1.x Oct 2, 2017
@QuLogic
QuLogic deleted the whatsnew-fixes branch October 2, 2017 04:16
@QuLogic

QuLogic commented Oct 2, 2017

Copy link
Copy Markdown
Member Author

Oh, I was about to push corrections...

@QuLogic QuLogic added this to the 2.1 (next point release) milestone Oct 2, 2017
@tacaswell

Copy link
Copy Markdown
Member

Sorry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants