Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork8.1k
DOC: Update style sheet reference#21860
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Also make the style name a bit larger and bold so that it's easier toread.
jklymak commentedDec 4, 2021
The one change I made to make the style name a suptitle was more legible in my opinion. I also think it was better as one style so it looked the same for each figure. |
9aa28df to529225fComparetimhoffm commentedDec 4, 2021
Yes, that's true. I've taken over your suptitles. |
| mcolors.to_rgb(plt.rcParams['figure.facecolor']))[2] | ||
| ifback<0.5: | ||
| col= [0.8,0.8,1] | ||
| fig.suptitle(style_label,x=0.01,fontsize=14,ha='left', |
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.
This looks good, but many times the fontsizes are are different?https://65288-1385122-gh.circle-artifacts.com/0/doc/build/html/gallery/style_sheets/style_sheets_reference.html It think this istight_layout making the axes smaller or bigger and then css making all the figures the same size. I think if you switch to constrained_layout this will be better (tight_layout doesn't work with suptitles)
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.
Ok, let's try with constrained layout.
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 didn't work either. I don't really understand why the fontsize is not being respected...
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.
The main "problem" with the fontsize seems to be that the different styles define different figure sizes. E.g. compare
and
The fonts have actually the same size, but the poster is much larger, and thus the png is scaled down to fit in the available width in the theme.
The alternative would be to use an absolute figure size instead of a one relativercParams['figure.size']. Not sure which is better.
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.
Oh weird. That hadn't occurred to me. I'd just make the figure a fixed size. That's essentially what we did w the subfigure version and I think that looked ok?
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.
Done:
It's better to override absolute sizes in the style sheet. Otherwise,
larger figure images are scaled down due to the limited available width
in the html theme. If we don't set a fixed size, we still don't get a size relation, but we
also have different magnifications due to the image scaling.
Notes:
- The width (7.4 -> 740px, assuming 100 dpi) is chosen to fit in the
HTML space (749px) without scaling. - The height is chosen to approximately keep the aspect ratio as before.
- The images are now significantly smaller than previously (all former
images were downscaled). We'll have to verify that the images still
look good given a lot of information and not much space. If not, we
need to add a fixed factor again. - All themes use figure.dpi=100, except "classic", which uses 80. Not
correcting for that is intentional. IMHO "classic" should come out
smaller to highlight the change in dpi.
with less overlapping lines to make the color cycle more obvious.Co-authored-by: Jody Klymak <jklymak@gmail.com>
529225f tob371463CompareIt's better to override absolute sizes in the style sheet. Otherwise,larger figure images are scaled down due to the limited available widthin the html theme. If not, we still don't get a size relation, but wealso have different magnifications due to the image scaling.Notes:- The width (7.4 -> 740px, assuming 100 dpi) is chosen to fit in the HTML without scaling.- The size is chosen to approximately keep the aspect ratio as before.- The images are now significantly smaller than previously (all former images were downscaled). We'll have to verify that the images still look good given a lot of information and not much space. If not, we need to add a factor.- All themes use figure.dpi=100, except "classic", which uses 80. Not correcting for that is intentional. IMHO "classic" should come out smaller to highlight the change in dpi.
7131207 toad1b222Comparejklymak commentedJan 5, 2022
This looks fine to me. Feel free to self merge if you are done with it... |
…860-on-v3.5.xBackport PR#21860 on branch v3.5.x (DOC: Update style sheet reference)
…860-on-v3.5.1-docBackport PR#21860 on branch v3.5.1-doc (DOC: Update style sheet reference)
Uh oh!
There was an error while loading.Please reload this page.