GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||
GeezerVison is showing github.com — TST: remove (most) text from constrained layout tests by jklymak · Pull Request #29833 · matplotlib/matplotlib Conversation
Member
This removes most of the text from The only exception here are a couple of tests with suptitles. These get a special place in constrained layout, and I didn't see an easy way to put a rectangle in there instead (I'm sure its possible but I don't think the goal is to have zero text tests). A follow up may be to remove many of the image tests, but really it is easier to see if things are working with an image test, so lets leave those in for now.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
jklymak
force-pushed
the
tst-constr-remove-text
branch
from
566a1c3 to
8563efa
Compare
|
There was an error while loading. Please reload this page.
|
This PR has flake8 errors like: But clearly doesn't touch that file, so I think maybe flake8 is on a new version? EDIT: ah yes 7.2 was released 4 hours ago. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
8563efa to
3909ae1
Compare
|
Sigh. Why does the bot remove tags that I have specifically added? |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Could we just moneypatch If you want to be selective we could create a |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
drawing text has a bunch of options (rotation, cantering etc) that seem like a lot of work to implement versus just redefining x/ylabel which does 95% of what we want. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Are there that many relevant options? I assume implementing rotation should be sufficient for 99% of the test use cases. This feels simpler than reimplementing all functions that create text. You start with xlabel/ylabel, but remarked yourself, there are issues with suptitles. Then we may need ticks. Then it would be helpful to use this for legends etc. But it's just a suggestion. I won't block over this. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I could try monkey patching, but it'd take me a while to sort out how to do it, and maybe not in time for #29827 which this was aimed at. Note that it is not trivial to place rectangles relative to an axes, but have a fixed physical size, and we place x and y labels by avoiding ticks so we would need to make sure the extents are correct for whatever is monkey patched. It may be worth the effort, but it's not trivial. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
As a very minimal test marks the text positions well. Rotation must still be added, you'll want to replace the actual sizes with dummy sizes to not depend on the font, and you want to pull this out of the middle of |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
This is a good idea, but I do not think we want to block the freetype 2.13.3 adoption on it. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Closed in lieu of #29872 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.