Closed mwaskom closed 6 years ago
Also previously the examples were loosely ordered alphabetically to go in a loosely ascending order of complexity/how common the task is, which is no longer the case.
I won't have time to look at this anytime soon. Feel free to roll back to the old version if need be
Actually I have a bit of time now...
Also previously the examples were loosely ordered alphabetically to go in a loosely ascending order of complexity/how common the task is, which is no longer the case.
Two options for this one:
Examples that produce a multi-panel figure no longer show the multi-panel image that gets saved; now they show four separate images and only one becomes the thumbnail.
This one can't be easily fixed unfortunately. :( One way to fix it would be to 1) take a screenshot
of the PySurfer window, 2) plot it using matplotlib
, and 3) tell SG to use this instead of the first image, but it's a bit of a hack.
We have a few examples that don't produce an image
I actually don't mind this too much. It's nice to have them listed on the page, even if it's with a default thumbnail. Alternatively, we can make them produce some image.
Also previously the examples were loosely ordered alphabetically to go in a loosely ascending order of complexity/how common the task is, which is no longer the case.
So it turns out SG by default orders examples by the number of code lines, so it should still in some sense be ordered by complexity. But there is a PR in the works to allow explicit ordering.
@mwaskom how was the ordering actually defined before? I think it might have been filename-alphabetical, in which case the SG PR mentioned above also adds this option, and we can use it until someone wants to explicitly reorder.
Can we live with the single-image problem, and the no-image-produced problem (I don't actually think it's a problem...?) and close this once the ordering problem is solved?
@mwaskom how was the ordering actually defined before? I think it might have been filename-alphabetical, in which case the SG PR mentioned above also adds this option, and we can use it until someone wants to explicitly reorder.
It was alphabetical by filename. But the SG default seems reasonable.
Can we live with the single-image problem, and the no-image-produced problem (I don't actually think it's a problem...?) and close this once the ordering problem is solved?
The single-image problem strikes me as a little weird in that what the example shows isn't actually what the user will see (i.e. it doesn't show of your nice work putting the split brains together). But if it's simply undoable, oh well. I think the small number of examples with no image generated make the gallery look a little blighted, but it should be easy to make those scripts generate an image (I'm actually not sure why they don't?)
Alphabetical by filename is also doable, let me know if you'd prefer that (old way) to the SG default (number of lines).
I also noticed that the size of thumbnails decreased from ~250x250 to ~112x112, do you want me to bump that back up while I'm in there? I plan to figure out how to set it in SG using CSS.
I also noticed that the size of thumbnails decreased from ~250x250 to ~112x112, do you want me to bump that back up while I'm in there? I plan to figure out how to set it in SG using CSS.
Yeah, looking at the doc build from the last PR, the thumbnails are pretty small. I think 250 is a good size.
I just noticed to issues with the new example gallery:
plot_*
, which was originally how we identified which scripts should populate the gallery)