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 our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Idea for canvas reinitialization: x.reinit() #275

Closed
lee1043 opened this Issue Nov 28, 2017 · 4 comments

Comments

Projects
None yet
3 participants
@lee1043

lee1043 commented Nov 28, 2017

Currently removeobject works for removing individual object or template, but I was thinking something like below, so everything can be easily removed but keep canvas alive so it can be re-used.

x=vcs.init()
x.plot(d)
x.reinit() ## Clear every objects in the canvas, remaining canvas alive

This would help when creating thousands of plots as @durack1 , @gleckler1 and I do, but memory usage is keep increasing because of user missed erase some of vcs object. @doutriaux1 What do you think?

@lee1043 lee1043 added the enhancement label Nov 28, 2017

@doutriaux1

This comment has been minimized.

Member

doutriaux1 commented Nov 28, 2017

@lee1043 I will add a function vcs.reset() that will remove all non displayed elements.

@doutriaux1 doutriaux1 self-assigned this Nov 28, 2017

@doutriaux1 doutriaux1 added this to the 3.0 milestone Nov 28, 2017

@durack1

This comment has been minimized.

Member

durack1 commented Nov 28, 2017

@lee1043 @doutriaux1 I think a vcs.reset() function would be ideal, I wonder whether having keyword args as an additional expansion to the function would be useful?

@lee1043

This comment has been minimized.

lee1043 commented Nov 28, 2017

@doutriaux1 Great, thanks. May I ask when I expect start using it? (No pressure, just estimation. :-) )

@doutriaux1

This comment has been minimized.

Member

doutriaux1 commented Nov 28, 2017

you may, but you might not like the answer 😸

doutriaux1 added a commit that referenced this issue Dec 7, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment