Re: [Jmol-users] setting hover text only for selected atoms

2009-04-02 Thread Angel Herráez
OK, so in case this is useful to anyone in the future, I will post here what I have achieved. The idea is to a have a custom text displayed on hovering the mouse pointer over the atoms, and that custom text is restricted to and specific for certain atoms. (By default, hover text can be set usin

Re: [Jmol-users] setting hover text only for selected atoms

2009-04-02 Thread Robert Hanson
right. atomIndex 2009/4/2 Angel Herraez > Thanks, Bob > > > well, you can do whatever you want with the callback, right? If you > > want to know if an atom is in a certain set, I think you could use: > > > > if ({whateverSet} and {atomno=_atomHovered}) > > Yes, I am already following that line -

Re: [Jmol-users] setting hover text only for selected atoms

2009-04-02 Thread Angel Herraez
Thanks, Bob > well, you can do whatever you want with the callback, right? If you > want to know if an atom is in a certain set, I think you could use: > > if ({whateverSet} and {atomno=_atomHovered}) Yes, I am already following that line -and have a working test-. It is atomindex, not atomno,

Re: [Jmol-users] setting hover text only for selected atoms

2009-04-01 Thread Robert Hanson
well, you can do whatever you want with the callback, right? If you want to know if an atom is in a certain set, I think you could use: if ({whateverSet} and {atomno=_atomHovered}) ... endif Bob 2009/3/31 Angel Herráez > Thanks for the hint, Bob > > Could this procedure be applied to a re

Re: [Jmol-users] setting hover text only for selected atoms

2009-03-31 Thread Angel Herráez
Thanks for the hint, Bob Could this procedure be applied to a restricted set of atoms? (based e.g. on belonging to user-named atom sets) -- ___ Jmol-users mailing list Jmol-us

Re: [Jmol-users] setting hover text only for selected atoms

2009-03-30 Thread Robert Hanson
You have to set a hoverCallback. set hovercallback "jmolscript:set hoverlabel @{\"this is atom \" + _atomHovered}" for example, displays "this is atom 3" when it is over that atom. You can also put anything in a Jmol script function and use that to define hoverlabel. The function is run after _a

[Jmol-users] setting hover text only for selected atoms

2009-03-30 Thread Angel Herráez
11.6.18 and 11.7.28 The command hover myText applies to all atoms, not to the currently selected set. I was of course expecting the latter. The documentation says nothing but that's the behaviour for all commands. How can one set custom hovers? ---