#123 mouse synch among multiple applets


On May 23, 2007, at 10:21 AM, Timothy Driscoll asked:

does Jmol implement an equivalent to the Chime synch parameter? in
Chime, synch gave the user mouse control of *all* structures on a
page by controlling any one structure. (in other words, rotate one
and all structures rotated.)

I looked through the mail archives and the doc, but even though I
seem to remember recent discussion on this topic, I found nothing

On May 23, 2007, at 10:44 AM, Bob Hanson wrote:

I think all of Jmol is "synch on" then isn't it? If you rotate any
structure, all structures rotate. To do otherwise you have to use Jmol
l1.1's "rotateSelected" command.

Tim replied:

sorry; I guess I wasn't that clear. Jmol does rotate all structures
in the same applet, yes. I was referring to control of multiple
applets on the same page.

Bob wrote:

Do you know where a description of the Chime command is? I can't
find it
at http://www.life.uiuc.edu/crofts/bc1_in_chime/chime_talk/index.html

Tim replied:

I haven't had much luck either. it's possible they have replaced it
with sendmouse?

Tag name: sendmouse

Description: Specifies whether to send Chime's mouse events to
another target Chime plug-in

Syntax: sendmouse={false|true}

false - do not send mouse events to another target Chime plug-in

true - send mouse events to another target Chime plug-in

And on May 23, 2007, at 6:59 PM, Bob Hanson wrote:

But if you can figure out a scheme that would be reasonable in
terms of
setting up this function wihtin Jmol -- I would want it to be possible
to designate what applets are to be synced, not just "all applets
on the
page" -- then I can see if I can implement it. Maybe some interesting
issues there.

Tim replied:

I can think about it, sure. I don't really see a problem with
synching all applets on a page; that would be much simpler anyway.

Bob wrote:

What I meant by that was that Chime didn't have the wide-ranging
capability that Jmol has. So it's not as simple as sending "the user now
moved the mouse HERE" to the other applets. You would need to address
issues such as:

Do moveto, zoomto, navigate, translate, etc. all get synched, or is it
just the mouse?
Is it the entire orientation that is being synched (zoom and all)?
Does spinning get synched? Does it get turned on automatically in other
How does one recognize which applet is the controller applet, and which
are followers?
What happens when a new file gets loaded in one of the applets?

It would be interesting to see a page with this working in Chime just to
see how/if those programmers addressed these issues.
The preliminary work I did mostly convinced me that it is no simple
matter to do this right.

I would want to know what people wanted before starting
into this.

Tim replied:

I understand. ok, here is my two cents:

moveto, zoomto, etc - any commands that are accessible only from
command line - would not be included. those are fairly easy to
synchronize using javascript. mouse events that affect orientation
(RTZ and spin) would be included.

when applets are synched, any applet on the page that is being
addressed by the mouse would become the controller applet.

loading a new file would not affect the synchronization state of the

perhaps my interpretation is too narrow, but I was investigating a
mouse synch feature only. (though I recognize that 'synch' is a broad
term; maybe 'synch mouse'?)


  • Bob Hanson

    Bob Hanson - 2008-08-15

    Logged In: YES
    Originator: NO

    Jmol allows full synchronization of mouse commands and/or all scripts executed or just actions that affect orientation.

  • Bob Hanson

    Bob Hanson - 2008-08-15
    • status: open --> closed

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

No, thanks