![]() ![]() |
Reference Type: Supported, Category: XGF Function Library, ICR#: 3173
The WIN^XGF API opens a text window on the screen and optionally remember what
it overlays. If the save root parameter is not passed, you cannot restore the
screen behind the window.
In order to save the screen region that the
window overlays it is absolutely necessary that screen output is done using
only the functions in the XGF Function library. If you use the M WRITE command
for output, the screen contents cannot be saved.
A call to the
PREP^XGF():
Screen/Keyboard Setup API must be made at some point prior to calling
WIN^XGF.
Specify the array node under which to save the overlaid screen
region in closed root and fully resolved form (i.e., closed right parenthesis
and with variable references such as $J fully resolved). Using the M
$NAME
function is a quick way to pass fully resolved node specifications.
To
restore screens you save with the WIN^XGF function, use the
RESTORE^XGF(): Screen Restore API.
WIN^XGF(top,left,bottom,right[,save_root])
top: |
(required) Top screen coordinate for box. |
left: |
(required) Left screen coordinate for box. |
bottom: |
(required) Bottom screen coordinate for box. |
right: |
(required) Right screen coordinate for box. |
save_root: |
(optional) Global/local array node, closed root form. |
save_root: |
If you specify a node as a fifth parameter for save_root, WIN^XGF saves the screen region you overlay in an array at that node. |
$X and $Y: |
Set to the right and bottom coordinates you specify as parameters. |
NOTE: See also: CLEAR^XGF(): Screen Clear Region, FRAME^XGF(): Screen Frame, RESTORE^XGF(): Screen Restore, and SAVE^XGF(): Screen Save APIs.
To draw an empty box in the center of the screen (and save the underlying screen region under array SELECT), do the following:
>D WIN^XGF(5,20,15,60,"SELECT") |
To save the same window to a global array (to illustrate the use of $NAME to specify a fully resolved root), do the following:
>D WIN^XGF(5,20,15,60,$NA(^TMP($J))) |