From: John Stone (johns_at_ks.uiuc.edu)
Date: Fri Sep 16 2005 - 21:08:55 CDT

Hi,
  There's not an easy way to do this, but if you really wanted to, you
could calculate your own view matrices based on the extents of the
molecule and force VMD to use your view. This is tricky as VMD
already makes a pretty good attempt at doing this based on the
min/max coordinates of the atoms in the molecule and as you can see
this tends to leave some empty space. If you really want a tight fit,
you'll also have to take perspective projection into account and calculate
the view frustum so that the closest atoms are just inside the four
view frustum clip planes, with some padding for any expansion by the
selected representation method (i.e. VDW radius, etc).

You might find it much easier to do this simply by scaling the default
view that VMD gives by a small fudge factor such as "scale by 1.2" or
something along those lines.

  John Stone
  vmd_at_ks.uiuc.edu

On Fri, Sep 16, 2005 at 06:09:39PM -0500, Jeffrey Tseng wrote:
> Hi, all
>
>
> Dose anyone know how to scale the molecule to to "just right" fit
> the screen by command ?
>
> It will be nice to calculate how large the molecule is and scale it
> to fit the screen (say , my VMD sceen is 400x400 )
>
>
>
> Thanks,
>
> Jeffrey

-- 
NIH Resource for Macromolecular Modeling and Bioinformatics
Beckman Institute for Advanced Science and Technology
University of Illinois, 405 N. Mathews Ave, Urbana, IL 61801
Email: johns_at_ks.uiuc.edu                 Phone: 217-244-3349
  WWW: http://www.ks.uiuc.edu/~johns/      Fax: 217-244-6078