Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
Looks perfect. And that's in $(document).ready ? On Sun, Apr 20, 2014 at 9:42 PM, Jonathan Gutow gu...@uwosh.edu wrote: These applets are created on the fly on a page that is already in existence using a call that looks like: $('#'+jmolDivStr).html(Jmol.getAppletHtml(jmolApplet+appletID,jmolStatus.jmolInfo[appletID])); *jmolDivStr contains the string name of the div the applet is being inserted into. This div is created based on an AJAX interaction with the SageMath server. *jmolApplet is the string name of the applets *appletID is the number assigned to the applet *jmolStatus.jmolInfo[appletID] just points to the jmolInfo data structure that has been constructed for this particular applet based on information from the server. I am using the coverImage feature of applet loading. I see the 2nd canvas whether or not I defer applet loading. Does that clarify the situation any? Any other ideas about what I should look at? Thanks, Jonathan On Sun, Apr 20, 2014 at 9:16 PM, Robert Hanson hans...@stolaf.edu wrote: Something's going wrong with your code, but I don't know from this. Try using Firefox and Inspect Element to see what that object is. My guess is that you are generating the canvas twice. Are you being sure to NOT use Jmol.getApplet() within the page and instead are only creating the applet within $(document).ready(function() {...}) ? Bob On Sun, Apr 20, 2014 at 8:48 PM, Jonathan Gutow gu...@uwosh.edu wrote: I'm having issues with the 2nd 2-D canvas that shows up below the active JSmol blocking access to some of the active components on a web page. Is this second canvas a place that backup drawing is done. It never shows anything, but is collecting clicks and a popup menu can be activated in it. It shows up outside of the boarder of the div within which JSmol is active. In the DOM this second canvas is listed in the same div as JSmol is active in. Did I trigger something bad or am I misusing something? Thanks, Jonathan -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
It isn't actually in $(document).ready because the call is triggered by a watch function that is looking for the div created by AJAX activity. If the div contains a particular hidden div this is called. Jonathan On Apr 21, 2014, at 9:32 AM, Robert Hanson hans...@stolaf.edu wrote: Looks perfect. And that's in $(document).ready ? On Sun, Apr 20, 2014 at 9:42 PM, Jonathan Gutow gu...@uwosh.edu wrote: These applets are created on the fly on a page that is already in existence using a call that looks like: $('#'+jmolDivStr).html(Jmol.getAppletHtml(jmolApplet+appletID,jmolStatus.jmolInfo[appletID])); *jmolDivStr contains the string name of the div the applet is being inserted into. This div is created based on an AJAX interaction with the SageMath server. *jmolApplet is the string name of the applets *appletID is the number assigned to the applet *jmolStatus.jmolInfo[appletID] just points to the jmolInfo data structure that has been constructed for this particular applet based on information from the server. I am using the coverImage feature of applet loading. I see the 2nd canvas whether or not I defer applet loading. Does that clarify the situation any? Any other ideas about what I should look at? Thanks, Jonathan On Sun, Apr 20, 2014 at 9:16 PM, Robert Hanson hans...@stolaf.edu wrote: Something's going wrong with your code, but I don't know from this. Try using Firefox and Inspect Element to see what that object is. My guess is that you are generating the canvas twice. Are you being sure to NOT use Jmol.getApplet() within the page and instead are only creating the applet within $(document).ready(function() {...}) ? Bob On Sun, Apr 20, 2014 at 8:48 PM, Jonathan Gutow gu...@uwosh.edu wrote: I'm having issues with the 2nd 2-D canvas that shows up below the active JSmol blocking access to some of the active components on a web page. Is this second canvas a place that backup drawing is done. It never shows anything, but is collecting clicks and a popup menu can be activated in it. It shows up outside of the boarder of the div within which JSmol is active. In the DOM this second canvas is listed in the same div as JSmol is active in. Did I trigger something bad or am I misusing something? Thanks, Jonathan -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
Any chance you can provide a link to an offending page? What did you learn from inspect element? Is it a duplicate? What is its outerHTML value? Sounds to me like something is running twice. On Mon, Apr 21, 2014 at 10:11 AM, Gutow, Jonathan H gu...@uwosh.edu wrote: It isn't actually in $(document).ready because the call is triggered by a watch function that is looking for the div created by AJAX activity. If the div contains a particular hidden div this is called. Jonathan On Apr 21, 2014, at 9:32 AM, Robert Hanson hans...@stolaf.edu wrote: Looks perfect. And that's in $(document).ready ? On Sun, Apr 20, 2014 at 9:42 PM, Jonathan Gutow gu...@uwosh.edu wrote: These applets are created on the fly on a page that is already in existence using a call that looks like: $('#'+jmolDivStr).html(Jmol.getAppletHtml(jmolApplet+appletID,jmolStatus.jmolInfo[appletID])); *jmolDivStr contains the string name of the div the applet is being inserted into. This div is created based on an AJAX interaction with the SageMath server. *jmolApplet is the string name of the applets *appletID is the number assigned to the applet *jmolStatus.jmolInfo[appletID] just points to the jmolInfo data structure that has been constructed for this particular applet based on information from the server. I am using the coverImage feature of applet loading. I see the 2nd canvas whether or not I defer applet loading. Does that clarify the situation any? Any other ideas about what I should look at? Thanks, Jonathan On Sun, Apr 20, 2014 at 9:16 PM, Robert Hanson hans...@stolaf.edu wrote: Something's going wrong with your code, but I don't know from this. Try using Firefox and Inspect Element to see what that object is. My guess is that you are generating the canvas twice. Are you being sure to NOT use Jmol.getApplet() within the page and instead are only creating the applet within $(document).ready(function() {...}) ? Bob On Sun, Apr 20, 2014 at 8:48 PM, Jonathan Gutow gu...@uwosh.edu wrote: I'm having issues with the 2nd 2-D canvas that shows up below the active JSmol blocking access to some of the active components on a web page. Is this second canvas a place that backup drawing is done. It never shows anything, but is collecting clicks and a popup menu can be activated in it. It shows up outside of the boarder of the div within which JSmol is active. In the DOM this second canvas is listed in the same div as JSmol is active in. Did I trigger something bad or am I misusing something? Thanks, Jonathan -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 --
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
At present it is on my development lap top. To test you would have to set up the whole SAGE server. I will look for a way that it could be launching twice. thanks, Jonathan On Apr 21, 2014, at 11:38 AM, Robert Hanson hans...@stolaf.edu wrote: Any chance you can provide a link to an offending page? What did you learn from inspect element? Is it a duplicate? What is its outerHTML value? Sounds to me like something is running twice. On Mon, Apr 21, 2014 at 10:11 AM, Gutow, Jonathan H gu...@uwosh.edu wrote: It isn't actually in $(document).ready because the call is triggered by a watch function that is looking for the div created by AJAX activity. If the div contains a particular hidden div this is called. Jonathan On Apr 21, 2014, at 9:32 AM, Robert Hanson hans...@stolaf.edu wrote: Looks perfect. And that's in $(document).ready ? On Sun, Apr 20, 2014 at 9:42 PM, Jonathan Gutow gu...@uwosh.edu wrote: These applets are created on the fly on a page that is already in existence using a call that looks like: $('#'+jmolDivStr).html(Jmol.getAppletHtml(jmolApplet+appletID,jmolStatus.jmolInfo[appletID])); *jmolDivStr contains the string name of the div the applet is being inserted into. This div is created based on an AJAX interaction with the SageMath server. *jmolApplet is the string name of the applets *appletID is the number assigned to the applet *jmolStatus.jmolInfo[appletID] just points to the jmolInfo data structure that has been constructed for this particular applet based on information from the server. I am using the coverImage feature of applet loading. I see the 2nd canvas whether or not I defer applet loading. Does that clarify the situation any? Any other ideas about what I should look at? Thanks, Jonathan On Sun, Apr 20, 2014 at 9:16 PM, Robert Hanson hans...@stolaf.edu wrote: Something's going wrong with your code, but I don't know from this. Try using Firefox and Inspect Element to see what that object is. My guess is that you are generating the canvas twice. Are you being sure to NOT use Jmol.getApplet() within the page and instead are only creating the applet within $(document).ready(function() {...}) ? Bob On Sun, Apr 20, 2014 at 8:48 PM, Jonathan Gutow gu...@uwosh.edu wrote: I'm having issues with the 2nd 2-D canvas that shows up below the active JSmol blocking access to some of the active components on a web page. Is this second canvas a place that backup drawing is done. It never shows anything, but is collecting clicks and a popup menu can be activated in it. It shows up outside of the boarder of the div within which JSmol is active. In the DOM this second canvas is listed in the same div as JSmol is active in. Did I trigger something bad or am I misusing something? Thanks, Jonathan -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor of Chemistry St. Olaf College Northfield,
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
I'm sure that some simple element inspection will answer your question. Send me that if you need to. On Mon, Apr 21, 2014 at 5:39 PM, Gutow, Jonathan H gu...@uwosh.edu wrote: At present it is on my development lap top. To test you would have to set up the whole SAGE server. I will look for a way that it could be launching twice. thanks, Jonathan On Apr 21, 2014, at 11:38 AM, Robert Hanson hans...@stolaf.edu wrote: Any chance you can provide a link to an offending page? What did you learn from inspect element? Is it a duplicate? What is its outerHTML value? Sounds to me like something is running twice. On Mon, Apr 21, 2014 at 10:11 AM, Gutow, Jonathan H gu...@uwosh.edu wrote: It isn't actually in $(document).ready because the call is triggered by a watch function that is looking for the div created by AJAX activity. If the div contains a particular hidden div this is called. Jonathan On Apr 21, 2014, at 9:32 AM, Robert Hanson hans...@stolaf.edu wrote: Looks perfect. And that's in $(document).ready ? On Sun, Apr 20, 2014 at 9:42 PM, Jonathan Gutow gu...@uwosh.edu wrote: These applets are created on the fly on a page that is already in existence using a call that looks like: $('#'+jmolDivStr).html(Jmol.getAppletHtml(jmolApplet+appletID,jmolStatus.jmolInfo[appletID])); *jmolDivStr contains the string name of the div the applet is being inserted into. This div is created based on an AJAX interaction with the SageMath server. *jmolApplet is the string name of the applets *appletID is the number assigned to the applet *jmolStatus.jmolInfo[appletID] just points to the jmolInfo data structure that has been constructed for this particular applet based on information from the server. I am using the coverImage feature of applet loading. I see the 2nd canvas whether or not I defer applet loading. Does that clarify the situation any? Any other ideas about what I should look at? Thanks, Jonathan On Sun, Apr 20, 2014 at 9:16 PM, Robert Hanson hans...@stolaf.edu wrote: Something's going wrong with your code, but I don't know from this. Try using Firefox and Inspect Element to see what that object is. My guess is that you are generating the canvas twice. Are you being sure to NOT use Jmol.getApplet() within the page and instead are only creating the applet within $(document).ready(function() {...}) ? Bob On Sun, Apr 20, 2014 at 8:48 PM, Jonathan Gutow gu...@uwosh.edu wrote: I'm having issues with the 2nd 2-D canvas that shows up below the active JSmol blocking access to some of the active components on a web page. Is this second canvas a place that backup drawing is done. It never shows anything, but is collecting clicks and a popup menu can be activated in it. It shows up outside of the boarder of the div within which JSmol is active. In the DOM this second canvas is listed in the same div as JSmol is active in. Did I trigger something bad or am I misusing something? Thanks, Jonathan -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Robert M. Hanson Larson-Anderson Professor 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 -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___ Jmol-developers mailing list Jmol-developers@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/jmol-developers -- Start Your Social Network Today - Download eXo Platform Build your Enterprise Intranet with eXo Platform Software Java Based Open Source Intranet - Social, Extensible, Cloud Ready Get Started Now And Turn Your Intranet Into A Collaboration Platform http://p.sf.net/sfu/ExoPlatform ___
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
Bob, Thanks for agreeing to look at this. I'm sending the two parts that seem relevant. 1) The div that is loaded with the applethtml using the calls mentioned previously. As you can see this puts up a static image and awaits the user click. {{{ div id=jmol0 class=ui-resizable style=height:400px; width:400px; div id=jmolApplet0_appletinfotablediv style= width:100%;height:100%;position:relative;font-size:14px;text-align:left div id=jmolApplet0_coverdiv style= background-color:red;z-index:11;width:100%;height:100%;display:inline;position:absolute;top:0px;left:0px img id=jmolApplet0_coverimage title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style=width:100%;height:100% src=/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 img id=jmolApplet0_coverclickgo title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style= width:25px;height:25px;position:absolute;bottom:10px;left:10px;z-index:11;opacity:0.5; src=/jsmol/j2s/img/play_make_live.jpg /div div id=jmolApplet0_appletdiv style= z-index:5;width:100%;height:100%;position:absolute;top:0px;left:0px;/div div id=jmolApplet0_2dappletdiv style= position:absolute;width:100%;height:100%;overflow:hidden;display:none/div div id=jmolApplet0_infotablediv style= width:100%;height:100%;position:absolute;top:0px;left:0px div id=jmolApplet0_infoheaderdiv style= height:20px;width:100%;background:yellow;display:none div id=jmolApplet0_infodiv style= position:absolute;top:20px;bottom:0px;width:100%;height:100%;overflow:auto /div /div /div /div }}} 2) What is in the div after the user click. {{{ div id=sage_jmol1 class=3DPlotDiv div id=sage_jmol_size1 class=JmolSize style=display:none;500/div div id=sage_jmol_img1 class=JmolImg style=display:none;/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 /div div id=sage_jmol_script1 class=JmolScript style=display:none; /home/admin/3/cells/1/sage0-size500.jmol?1398130820/div div id=sage_jmol_status1 class=JmolStatus style=display:none; Activated/div spanClick on 3-D image to make it live. Right-click on live image for a control menu./span div id=jmol0 class=ui-resizable style=height:400px; width:400px; div id=jmolApplet0_appletinfotablediv style= width:100%;height:100%;position:relative;font-size:14px;text-align:left div id=jmolApplet0_coverdiv style=background-color: red; z-index: 11; width: 100%; height: 100%; display: none; position: absolute; top: 0px; left: 0px; img id=jmolApplet0_coverimage title=3D model is loading... onclick=Jmol.coverApplet(jmolApplet0, false) style=width:100%;height:100% src=/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 img id=jmolApplet0_coverclickgo title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style= width:25px;height:25px;position:absolute;bottom:10px;left:10px;z-index:11;opacity:0.5; src=/jsmol/j2s/img/play_make_live.jpg /div div id=jmolApplet0_appletdiv style=z-index: 5; width: 100%; height: 100%; position: absolute; top: 0px; left: 0px; display: block; canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; z-index: 7; width=400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width= 400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width= 400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width= 400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width= 400 height=400/canvas /div div id=jmolApplet0_2dappletdiv style= position:absolute;width:100%;height:100%;overflow:hidden;display:none/div div id=jmolApplet0_infotablediv style=width: 100%; height: 100%; position: absolute; top: 0px; left: 0px; display: none; div id=jmolApplet0_infoheaderdiv style=height: 20px; width: 100%; background: none repeat scroll 0% 0% yellow; display: none; div id=jmolApplet0_infodiv style= position:absolute;top:20px;bottom:0px;width:100%;height:100%;overflow:auto /div /div /div }}} As you can see in this particular instance it has created 5 canvas2d elements. The number seems to vary between two and five. The one with the z-index of 7 seems to be the active one. However, the second on the list seems to be showing up immediately below the first one with a z-index of auto. The others do not show up as having any ability to catch clicks (I think they are below the second instance). We are using the very latest jquery. I'm not noticing any warnings associated with that. I I'm also using the latest Jmol/JSmol 14.0.13. see you've caught up with the deprecation of preventDefault. One hint. The pages are essentially fancy terminals for the server running inside a browser. The pages have lots of server communication javascript functions running on 200 ms and other intervals. Is it possible that this is delaying something in the JSmol load sequence so that it restarts the load? Thanks for any other suggestions you can provide. I'm stuck. Jonathan On
Re: [Jmol-developers] What is the second Canvas2d for that shows up below the active one when using JSmol?
I guess you just have to send me your computer. :) Clearly you are getting multiple calls to the canvas creation method. canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; z-index: 7; width=400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width=400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width=400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width=400 height=400/canvas canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; width=400 height=400/canvas Your Info array definitely has this? Info.deferApplet = true; Info.deferUncover = true; Here's what you need to do: 1) replace JSmol.min.js with js/Jmol.full.js. 2) edit (the now readable) JSmol.min.js, finding this._start(); and put an alert just before that: alert(callee.caller.toString()) and see where this is coming from. If necessary, work backward: alert(callee.caller.caller.toString()) alert(callee.caller.caller.caller.toString()) It looks like jmolApplet0._start() is being called five times. That is calling jmolApplet0._getCanvas(false), and that is then causing the multiple canvases to be produced in jmolApplet0._createCanvas2d. The z-index is only being set once, because after that there are multiple canvases all with the same id. The only code that is supposed to be calling this is an image click set up in JSmolCore.js: Jmol._getWrapper = function(applet, isHeader) { ... var more = onclick=\Jmol.coverApplet(ID, false)\ title=\ + (applet._coverTitle) + \; ... Seems unlikely that you are clicking that multiple times. Bob On Mon, Apr 21, 2014 at 8:58 PM, Jonathan Gutow gu...@uwosh.edu wrote: Bob, Thanks for agreeing to look at this. I'm sending the two parts that seem relevant. 1) The div that is loaded with the applethtml using the calls mentioned previously. As you can see this puts up a static image and awaits the user click. {{{ div id=jmol0 class=ui-resizable style=height:400px; width:400px; div id=jmolApplet0_appletinfotablediv style= width:100%;height:100%;position:relative;font-size:14px;text-align:left div id=jmolApplet0_coverdiv style= background-color:red;z-index:11;width:100%;height:100%;display:inline;position:absolute;top:0px;left:0px img id=jmolApplet0_coverimage title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style=width:100%;height:100% src=/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 img id=jmolApplet0_coverclickgo title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style= width:25px;height:25px;position:absolute;bottom:10px;left:10px;z-index:11;opacity:0.5; src=/jsmol/j2s/img/play_make_live.jpg /div div id=jmolApplet0_appletdiv style= z-index:5;width:100%;height:100%;position:absolute;top:0px;left:0px;/ div div id=jmolApplet0_2dappletdiv style= position:absolute;width:100%;height:100%;overflow:hidden;display:none/ div div id=jmolApplet0_infotablediv style= width:100%;height:100%;position:absolute;top:0px;left:0px div id=jmolApplet0_infoheaderdiv style= height:20px;width:100%;background:yellow;display:none div id=jmolApplet0_infodiv style= position:absolute;top:20px;bottom:0px;width:100%;height:100%;overflow:auto /div /div /div /div }}} 2) What is in the div after the user click. {{{ div id=sage_jmol1 class=3DPlotDiv div id=sage_jmol_size1 class=JmolSize style=display:none;500/div div id=sage_jmol_img1 class=JmolImg style=display:none;/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 /div div id=sage_jmol_script1 class=JmolScript style=display:none; /home/admin/3/cells/1/sage0-size500.jmol?1398130820/div div id=sage_jmol_status1 class=JmolStatus style=display:none; Activated/div spanClick on 3-D image to make it live. Right-click on live image for a control menu./span div id=jmol0 class=ui-resizable style=height:400px; width:400px; div id=jmolApplet0_appletinfotablediv style= width:100%;height:100%;position:relative;font-size:14px;text-align:left div id=jmolApplet0_coverdiv style=background-color: red; z-index: 11; width: 100%; height: 100%; display: none; position: absolute; top: 0px; left: 0px; img id=jmolApplet0_coverimage title=3D model is loading... onclick=Jmol.coverApplet(jmolApplet0, false) style=width:100%;height:100% src=/home/admin/3/cells/1/.jmol_images/sage0-size500.jmol.png?1398130820 img id=jmolApplet0_coverclickgo title=activate 3D model onclick=Jmol.coverApplet(jmolApplet0, false) style= width:25px;height:25px;position:absolute;bottom:10px;left:10px;z-index:11;opacity:0.5; src=/jsmol/j2s/img/play_make_live.jpg /div div id=jmolApplet0_appletdiv style=z-index: 5; width: 100%; height: 100%; position: absolute; top: 0px; left: 0px; display: block; canvas id=jmolApplet0_canvas2d style=width: 100%; height: 100%; z-index: 7; width=400 height=400/canvas