@node Window, Write, While, Commands @iftex @syntax Window. @end iftex @example Syntax: WINDOW nx ny x y @end example @pindex Window @findex plot size, plot window WINDOW makes the current plot location the window at (x,y), where there are nx windows across and ny windows up and down. WINDOW 1 1 1 1 resets the plot location to the entire plot area. The size and placement of the windows is decided by the value of EXPAND when the WINDOW commands are issued, so be sure that EXPAND has the same value for every window in a set. (It's used to figure out the axis labels, and spacings between boxes). While plotting to a given window you can of course change EXPAND to your heart's content. If the number of windows in either the x or y direction is negative no space is left between the boxes in that direction (try DO i=1,3 @{ WINDOW @code{1 -3 1 $i} BOX @}). It's possible to overload `window' and `box' to only label external axes in blocks of touching boxes. If either x or y is specified as, e.g. 2:4, the window is set to cover the range 2-4 (i.e. the part of the screen covered by windows 2, 3, and 4). Note that this feature can be used to split the screen in arbitrary ways, e.g. @example window -1 -6 1 1:5 box window -1 -6 1 6 box @end example (or you could say @code{window -20 -20 15:19 15:19} as an alternative to a LOCATION command). If you don't want boxes that touch, but you don't like the gaps left between boxes by the @code{WINDOW} command, you can now do something about it legally, without lying to SM. After we calculate the widths of the `gutters' between the windows that we think that you need, they are multiplied by the values of the SM variables @code{x_gutter} and @code{y_gutter}, so if you think that the spacing is too large in the x direction you can say @example define x_gutter 0.5 window 2 2 1 1 box window 2 2 1 2 box @end example @noindent to make things look better. Within a macro it can be convenient to say @code{local define x_gutter 0.5}, as then the gutter value softly and suddenly vanishes at the end of the macro. @findex spacing between windows @findex gutters between windows It's confusing to change LOCATIONs while using WINDOWs; you probably want to say WINDOW 1 1 1 1 first.