Skip to content
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

GUI: visual manipulation of atom positions #211

Open
NikoOinonen opened this issue Oct 5, 2023 · 2 comments
Open

GUI: visual manipulation of atom positions #211

NikoOinonen opened this issue Oct 5, 2023 · 2 comments
Assignees

Comments

@NikoOinonen
Copy link
Collaborator

The ppafm-gui can open the ASE GUI for visualizing the molecule geometry. It would also be useful if the geometry could also be manipulated in the ASE GUI and update the simulation accordingly. This is something that was requested by one member of our group.

I actually already made a working implementation of this on this branch: https://github.com/Probe-Particle/ppafm/tree/gui-manipulate-atoms. However, there is still some problem that causes the whole program to crash if the ASE GUI is opened a second time after closing it once. It throws an error:

python3: Fatal IO error 22 (Invalid argument) on X server :0.

I traced it down to Tkinter failing to initialize for a second time but could not figure out why it is happening.

@NikoOinonen NikoOinonen self-assigned this Oct 5, 2023
@ProkopHapala
Copy link
Collaborator

Wow that looks like really great feature.

about the error, I don't know. Isn't there some destructor which have to be called to clean up the memory of the previous instance when it is closed? I had similar problem with GUI for FireCore (but that was all my code, without opaque external dependnecies).

@NikoOinonen
Copy link
Collaborator Author

The ASE GUI uses Tk for rendering the window. I was digging into the code in ASE, but I did not see any way to destroy and recreate the window properly. There could be some way of just hiding the window and then bringing it back up without destroying it, but I haven't had the time to look into it.

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

When branches are created from issues, their pull requests are automatically linked.

2 participants