Allow open/interact without plotting anything #1227
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Currently, the
canvas.open()
call doesn't do anything. In developing and testing my GUI parts embedded in VCS, it's really quite handy to have a fully-prepared VCS canvas without actually plotting anything (or plotting something and then callingclear()
, which gives the same end result). This PR makes it so you can open the canvas prior to plotting. As a caveat of that, if you callx.open(); x.interact()
, it'll now enter interact mode. This is a little goofy, but given the fact that we have some GUI elements that allow for some user interaction with a blank canvas (markers and text buttons, top right), it's not completely ridiculous. I'm happy to scrap the ability tointeract()
with a blank canvas; it's not particularly useful for me.All of the tests pass for me with this PR, though there is one test that will hang until manually quit (
test_vcs_interact_no_plot.py
). If we make it sointeract()
will fail when there are no plots, that test can remain the same; if we don't, this test will either have to change or be eliminated.@doutriaux1 @aashish24 @dlonie Opinions?