-
Notifications
You must be signed in to change notification settings - Fork 224
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
Adjust titles in polar projections overview #3700
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good.
@@ -61,7 +61,7 @@ | |||
# Set map width to 5 cm | |||
projection="P5c", | |||
# Set the frame and title; @^ allows for a line break within the title | |||
frame=["xa45f", "+gbisque+tprojection='P5c' @^ region=[0, 360, 0, 1]"], | |||
frame=["xa45f", '+gbisque+tprojection="P5c" @^ region=[0, 360, 0, 1]'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmm. I am a bit debating on what is more important, (i) using consistently double quotation marks for string arguments or (ii) making the title consistent with the argument. Currently, I am a bit more on the side of (i). A way to use both times double quotation marks is to add a leading \
for the inner double quotation marks. But maybe this makes things only more complicated.
frame=["xa45f", '+gbisque+tprojection="P5c" @^ region=[0, 360, 0, 1]'], | |
frame=["xa45f", "+gbisque+tprojection=\"P5c\" @^ region=[0, 360, 0, 1]"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Currently, single quotes are displayed like
’
, rather than'
. See #3476 for the reason and #3105 for the fix.
That's the reason why I wanted to change it. The single quotes are looking like accute accents right now and that's something that seems to be weird for users when they see it in plots. And yes, backslashes make the code more difficult and confusing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's the reason why I wanted to change it. The single quotes are looking like accute accents right now and that's something that seems to be weird for users when they see it in plots
Then it means we can close the PR without merging if #3105 is approved.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would still go with using double quotations here since the titles directly reference the projection
parameter in the code. Using single quotations for a string in such cases is fine in my opinion. But I'm also fine if all others what to keep it as is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm inclined to keep it as is.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would also prefer to keep it as is, as I prefer to have (if possible) double quotation marks for the string inputs.
I'm closing the PR. |
Description of proposed changes
Adjust title for each plot so that the formatting looks like the string given to the projection parameter (double quotations are shown in the plot titles instead of single ones).
Old:
New:
Reminders
make format
andmake check
to make sure the code follows the style guide.doc/api/index.rst
.Slash Commands
You can write slash commands (
/command
) in the first line of a comment to performspecific operations. Supported slash command is:
/format
: automatically format and lint the code