Unidata - To provide the data services, tools, and cyberinfrastructure leadership that advance Earth system science, enhance educational opportunities, and broaden participation. Unidata
         
  advanced  
 

Re:

Amaral wrote:
I woud appreciate if someone could help me to find out what is the visAD object which controls the size of the black display box, how to change its background color and how to clear the box borders. thanks for help.

The box color and visibility are controllable through the visad.RendererControl:

If your DisplayImpl is named 'disp', then do something like:

rc = disp.getDisplayRenderer().getRendererControl()
rc.setBackgroundColor(java.awtColor)
rc.setBoxOn(boolean)

(These calls will the next release of the Jython 'subs.py' collection.)

The box 'size' (relative to the size of the frame) can be manipulated via the display's ProjectionControl. For example, using Jython with a 3D display you would just say "disp.setBoxSize(percent)" where 'percent' varies from 0 (no size) to 1.0 (full window). Look at the code in subs.py for 'setBoxSize()' and you'll see something like this (for 3D...the code is different for 2D):

pc = disp.getProjectionControl()
mat = pc.getMatrix()
mat[0] = percent
mat[5] = percent
mat[10] = percent
pc.setMatrix(mat)

--
Tom Whittaker (tomw@xxxxxxxxxxxxx)
University of Wisconsin-Madison
Space Science and Engineering Center
Cooperative Institute for Meteorological Satellite Studies
Phone/VoiceMail: 608.262.2759


 
 
  Contact Us     Site Map     Search     Terms and Conditions     Privacy Policy     Participation Policy
 
National Science Foundation (NSF) UCAR Community Programs   Unidata is a member of the UCAR Community Programs, is managed by the University Corporation for Atmospheric Research, and is sponsored by the National Science Foundation.
P.O. Box 3000     Boulder, CO 80307-3000 USA     Tel: 303-497-8643     Fax: 303-497-8690