How to set BestFit in Applet

User 39ade0cdf9

10-07-2007 02:35:55

I found there exists an option:Bestfit to applet window size, how to assign this parameter in applet? The rendered structure looks much smaller than Applet window, I wanna better size just like autoscale in Marvin Sketch.





what's the relationship between render size and applet size(width height)?


how marvin space calculates render size? Thanks a lot!

ChemAxon 909aee4527

12-07-2007 07:06:18

Hello Liu,





MarvinSpace usually works with larger PDB files, but of course we handle small molecules too. The difference between the size of input structures complicates autoscaling a bit.





First we compute the bounding sphere radius of all visible components, and multiply it with a scalar counting in the smaller window size (width or height).


The scalar was experimentally chosen by displaying many structures - it works quite good in all cases, but of course it could be better if you examine one particular structure only.


We found the current computation fast and good enough so far, but we could make a more precise one if it's required.





It is possible to manually adjust the zoom through applet parameter or script file. In these examples (http://www.chemaxon.com/marvinspace/html/webstart.html) we changed rotation and zoom parameters to achieve better fit than the default.





Kind regards,


Judit