| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
Sorry, something went wrong.
|
As had been commented already by @timhoffm, it might be beneficial to introduce a new axes.titlecolor parameter instead. This would avoid breaking existing user styles and some users would totally love to have this anyways. Of course not to break anything with this new parameter either, it might need to take something like "auto" that falls back to whatever the color was before. |
Sorry, something went wrong.
|
Should only axes.titlecolor be added then? Or also figure.titlecolor to follow the paralelism between set_title and suptitle? |
Sorry, something went wrong.
|
Good question. I do not have an opinion on that. Since we do have figure.titlesize and figure.titleweight, it might be more consistent for the figure title to get its own rcParam for color as well. But I wouldn't actually expect it to be used a lot, if at all... |
Sorry, something went wrong.
|
How does this look? I tried to check the behaviour of some other parameters that had an 'auto' option, but I am not sure I actually understood how they handle it. I was also wondering if it would be a good idea to add a call to set_title to one of the subplots in the style sheets reference. |
Sorry, something went wrong.
|
I think it is ready for review, and unless there are any more requests, merging too. |
Sorry, something went wrong.
|
I am 50/50 on using the string "auto" as a sentinel. On one hand it is slightly ambiguous with the string color names, on the other hand we already have precedent for this and using None would be at least as awkward in the code. |
Sorry, something went wrong.
|
Whichever you prefer. It won't be difficult to change. I can leave you some time to discuss it and agree on one alternative for the fallback, just let me know and I will use the chosen one. |
Sorry, something went wrong.
|
@tacaswell @ImportanceOfBeingErnest Should I modify the sentinel to None instead of 'auto'? |
Sorry, something went wrong.
|
There are plenty of "None"s in the rc files, so I think its a good convention for "fall back on a default" |
Sorry, something went wrong.
|
I was changing the code to use None instead of 'auto' and I realized it would yield incoherent results. 'none' is a valid color, meaning "No color", and even though None is not, 'None' and 'NONE' are, therefore, the value in the rctemplate file will be read as a string, lowercased and mapped to 'none' instead of mapped to None (this is done by validate_color in rcsetup.py). Related to #8479. It could be something different than 'auto', but then it would diverge from lines.markerfacecolor and lines.markeredgecolor. |
Sorry, something went wrong.
|
Can someone rerun the docs tests? They failed in the installation section: Package libav-tools is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source However the following packages replace it: ffmpeg Package pgf is not available, but is referred to by another package. This may mean that the package is missing, has been obsoleted, or is only available from another source E: Package 'libav-tools' has no installation candidate E: Package 'pgf' has no installation candidate E: Unable to locate package otf-freefont Exited with code 100 It does not look related to my PR |
Sorry, something went wrong.
|
Can you try a rebase? I think there was a problem with CI that was fixed recently.... I think you just need to do: git fetch upstream git rebase upstream/master assuming you have the upstream branch setup https://matplotlib.org/3.1.0/devel/gitwash/development_workflow.html |
Sorry, something went wrong.
|
Anything else left to do? Maybe add figure.titlecolor? I do not think it would be much used though, and axes already have titlepad and titlelocation which figure does not. |
Sorry, something went wrong.
|
PRs need two approvals to be merged. |
Sorry, something went wrong.
|
Thanks, and congratulations on your first contribution to Matploblib! Hope to see you back some time. |
Sorry, something went wrong.
| Back | FazBrowse Home | New Git URL |
PR Summary
Extremely simple solution to #14656. I am not sure if this follows the direction you had in mind, I am open to add an extra parameter to rcparams as discussed in the issue, extend (or not) this behaviour to suptitle.
PR Checklist