Is there a way to write ASE GUI image with charges?


I know I can display the charge in the ASE GUI by manually select that, but is there way to write('xxx.png') or animate('xxx.gif') with charges (or other atomic properties)? I think plot_atoms can only take a few generic options.
Thank you for the help in advance.

Correct, unfortunately the plot_atoms() code was originally made by copying and pasting the GUI rendering code (which is not a good practice). So every time something is added to one of them, it will become inconsistent with the other and they drift apart.

It would not be too difficult to add this, I suppose, but it would be wise to add an abstraction layer so the two renderers can rely on the same actual code to some extent and stop drifting apart.

(Admittedly there’s a big difference between the pixel-based GUI rendering and the floating-point based matplotlib rendering, so it’s not extremely easy to make an abstraction that allows unifying them.)