Eric, sorry to take so long getting back to you. The short answer is that
if you download the very latest http://chemapps.stolaf.edu/jmol/Jmol-13.zip,
you can use in JavaScript:
var bondInfo = Jmol.getPropertyAsArray("bondinfo","connected(hbond) and
visible")
bondInfo will be an Array, one element for each bond:
bondInfo=new Array()
bondInfo[0]=new Array()
bondInfo[0].radius=0.15
bondInfo[0].order=1
*bondInfo[0].type="single"
*bondInfo[0].atom2=new Array()
bondInfo[0].atom2.sym="C"
bondInfo[0].atom2.atomno=2
bondInfo[0].atom2._ipt=1
bondInfo[0].atom2.info="C 2/1 #2"
bondInfo[0].atom1=new Array()
bondInfo[0].atom1.sym="H"
bondInfo[0].atom1.atomno=1
bondInfo[0].atom1._ipt=0
bondInfo[0].atom1.info="H 1/1 #1"
bondInfo[0]._bpt=0
bondInfo[0].colix=0
*bondInfo[0].visible=true
*bondInfo[0].length_Ang=1.0810671
bondInfo[1]=new Array()
...
That could be a mix of single and hydrogen bonds still (because you are
selecting atoms, not bonds),
so run through the list looking for bondinfo[i].type == "hbond" and
bondinfo[i].visible = true:
for (var i = bondInfo.length; --i >=0;) {
if (bondinfo[i].type == "hbond" && bondinfo[i].visible) {
.....
}
}
Bob
------------------------------------------------------------------------------
This SF.net email is sponsored by Windows:
Build for Windows Store.
http://p.sf.net/sfu/windows-dev2dev
_______________________________________________
Jmol-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jmol-users