[Jmol-users] how do I reset Jmol applet menus on reload etc?

2007-07-09 Thread Matthew Betts
Hi, Is there a way to make menus reset to their defaults in a Jmol applet when either reloading the page or on some other action (such as loading a pdb file)? The following simple instance leaves the display on 'Spacefill' and the colours on 'Structure' (or whatever) when a new structure is l

Re: [Jmol-users] how do I reset Jmol applet menus on reload etc?

2007-07-09 Thread pim schravendijk
I just tried, when I select a new molecule on the left it opens with the original settings. Then I change it, select the other molecule, and go back again, and all changes are lost, back to default as well. So, the applet seems to have the behavior you want, at least here. Using firefox on linux,

Re: [Jmol-users] how do I reset Jmol applet menus on reload etc?

2007-07-09 Thread Angel Herraez
Hi Matthew It is unlikely that you will find a solution for this in the web or list archive, since it is not a Jmol problem, but a javascript one. You want to reset the menus that you have in the web page, and that cannot be done from Jmol, it's your javascript code in the page that must do i

Re: [Jmol-users] how do I reset Jmol applet menus on reload etc?

2007-07-10 Thread Matthew Betts
Hi Angel, That works really well, thanks for the quick reply. I'm also a javascript newbie... Matthew I tweaked it a bit, using the Jmol javascript command, and it seems to work on change of menu without affecting Jmol. With this in the html head: function resetJmolControls() { docum

Re: [Jmol-users] how do I reset Jmol applet menus on reload etc?

2007-07-10 Thread Angel Herraez
El 10 Jul 2007 a las 11:46, Matthew Betts escribió: {snip} > I tweaked it a bit, using the Jmol javascript command, and it seems to > work on change of menu without affecting Jmol. {snip} > jmolMenu( > [ > ["javascript \"resetJmolControls()\"; load pdb1ema.ent; select > hete