Rolf, you mean you want to access the point where the hover is over? The
most recent atom index hovered over is _atomhovered, so you can use that
and, within your function:

var a = {atomIndex=_atomhovered}
print a
print a.xyz

etc.

There is no callback when the hover is released. I suppose you could set a
timeout for that.



On Fri, Nov 21, 2014 at 5:06 AM, Rolf Huehne <[email protected]> wrote:

>        Hi all,
>
> I would like to use the 'hoverCallback' with a Jmol script function
> instead of a Javascript function. But I couldn't figure out how to
> access the parameters inside the function.
>
> I tried for example this:
>
> ---- Code ---------------
> function hoverAction(p1, p2, p3) {
>   show p1;
>   show p2;
>   show p3;
> }
> set hoverCallback "jmolscript: hoverAction;";
>
> ---- Result -------------
> p1 = ""
> p2 = ""
> p3 = ""
> -------------------------
>
> Q: And how can I detect the end of a 'hover' to undo the changes made to
> the view?
>
> Regards,
> Rolf
>
> --
>
> Rolf Huehne
> Postdoc
>
> Leibniz Institute for Age Research - Fritz Lipmann Institute (FLI)
> Beutenbergstrasse 11
> 07745 Jena, Germany
>
> Phone:   +49 3641 65 6205
> Fax:     +49 3641 65 6210
> E-Mail:  [email protected]
> Website: http://www.fli-leibniz.de
>
>            Scientific Director: Prof. Dr. K. Lenhard Rudolph
>         Head of Administration: Dr. Daniele Barthel
> Chairman of Board of Trustees: Dennys Klein
>
> VAT No: DE 153 925 464
> Register of Associations: No. 230296, Amtsgericht Jena
> Tax Number: 162/141/08228
>
>
>
> ------------------------------------------------------------------------------
> Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
> from Actuate! Instantly Supercharge Your Business Reports and Dashboards
> with Interactivity, Sharing, Native Excel Exports, App Integration & more
> Get technology previously reserved for billion-dollar corporations, FREE
>
> http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
> _______________________________________________
> Jmol-users mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>



-- 
Robert M. Hanson
Larson-Anderson Professor of Chemistry
Chair, Department of Chemistry
St. Olaf College
Northfield, MN
http://www.stolaf.edu/people/hansonr


If nature does not answer first what we want,
it is better to take what answer we get.

-- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
------------------------------------------------------------------------------
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to