Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Wiki Markup
{alias:xwi}
h2. Name

*xwi* — Window on screen

h2. Syntax
{panel:|borderStyle=solid|borderWidth=1|bgColor=#FFFFAA}
*xwi* \[*stereo | del | sel*] \[*pixels*] | \[_xpixels ypixels_] \[*con*] \[*tk*] \[*exist*] \[*toplevel* | *top*] \[*fullscreen* | *fsc*] \[*xyscale*]
{panel}

When a graphical window is generated there are a few manipulation command:

{panel:|borderStyle=solid|borderWidth=1|bgColor=#FFFFAA}
*xwi min | max | fullscr*
{panel}

h2. Description

Handling of display window and its parameters in the graphical screen. The graphical display window is called an *xwindow* or just *window*. 

h2. Arguments

*stereo* 
{indent}The graphic window will be stereo-enabled.{indent}
*del* \[*1 | 2 | 3 ...*] 
{indent}Delete (remove) the last graphic window \[or xwindow number 1/2/3/...].{indent} 
_pixel_ 
{indent}Create an quadratic window display with sides _pixel_ pixels.{indent} 
_xpixels ypixels_ 
{indent}Create a window display sized _xpixels_ times _ypixels_ pixels.{indent} 
*sel* _number_ 
{indent}Select xwindow number.{indent} 
*con* _number_ 
{indent}Camera is connected to xwindow _number_.{indent} 
*exist* _number_ 
{indent}Check if an xwindow exists. The result is placed in the return code \[gvar rc].{indent} 
{info:title=Example of checking if a window exists} 
  xwi exist 3
  set doesexist \[gvar rc]
  #will set the variable $doesexist to 1 if the xwindow does exist, and -1 if not existing. 
{info}
*subframes* _no_of_subframes_ 
{indent}Set the number of sub frames for doing motion blur. The default is zero. Once this is set greater than one, you will no longer see a new frame for every Render(). If you set this to five, you will need to do five Render() invocations before seeing the result. This is not very impressive unless something is changing between the Renders.{indent} 
*toplevel* | *top* 
{indent}To get a toplevel stand alone window.{indent} 
*fullscreen* | *fsc* 
{indent}To get a toplevel fullscreen stand alone window.{indent} 
*xyscale* _scale_ | *off*
{indent}
_scale_ : To establish a specific plot scale in the current graphical window; like 1:_scale_. The window will be set into 2D mode and the zoom button will be disabled. To enable the zoom button go into 3D mode.
*off* : Turn off the scale. Will enable the zoom button.
{indent} 
*min*
{indent}Will minimize the window.{indent} 
*max*
{indent}Will maximize the window.{indent} 
*fullscr*
{indent}Will maximize the window to absolute max size without any toolbar. One can use the *Esc button* to switch back to normal.{indent} 

h2. Examples

h3. Ex.1: Setting a specific scale on a graphical window

{noformat:|borderWidth=1|bgColor=#eeeeee}

        win demo            ;#  get the demo window
        xwi xyscale 100000  ;#  establish scale 1:100000
        mak ran 11          ;#  11 random points
        grp 111 111         ;#  make a grid
        map                 ;#  map the grid
        sma i 250 can ans 2 ;#  spline map
        axe tic             ;#  dra axes
        tx2 lle col bla txt "Scale 1:100000"
{noformat}

The above example produces a similar image. 

!att:_img_ref^demoscale.png|border=1!
_The demo window plotted in scale 1:100000_

h3. Ex.2: Plotting the Atlantis grid in scale 1:20 000 000

{noformat:|borderWidth=1|bgColor=#eeeeee}
        # Setting scale
        xwi xyscale 20000000 ;#  scale 1: 20 000 000
{noformat}

!att:_img_ref^atlantis_scale.png|border=1!
_The Atlantis grid plotted on the screen in scale 1:20 000 000_


h2. See also

[vie - Viewport handling], [win - Window specification]
{pagebreak}