| xHarbour Reference Documentation > Function Reference |
![]() |
![]() |
![]() |
Returns all coordinates of the current window.
WInfo() --> aWindowInfo
The function returns an array of eight elements holding the screen coordinates of the unformatted and formatted display area of a window.
Array holding window coordinates
| Element | Description |
|---|---|
| Unformatted window | |
| 1 | Top row coordinate equivalent to WRow() |
| 2 | Left column coordinate equivalent to WCol() |
| 3 | Bottom row coordinate equivalent to WLastRow() |
| 4 | Right column coordinate equivalent to WLastCol() |
| Formatted display area | |
| 5 | Top row coordinate equivalent to WfRow() |
| 6 | Left column coordinate equivalent to WfCol() |
| 7 | Bottom row coordinate equivalent to WfLastRow() |
| 8 | Right column coordinate equivalent to WfLastCol() |
| See also: | WCol(), WLastCol(), WLastRow(), WOpen(), WRow(), WSelect() |
| Category: | CT:Window , Windows (text mode) , xHarbour extensions |
| Source: | ct\ctwin.c |
| LIB: | xhb.lib |
| DLL: | xhbdll.dll |
// The example creates a window with a frame (fromatted window)
// and displays the contents of the WInfo() array.
PROCEDURE Main
LOCAL nT := 4, nL := 6, nW := 50, nH := 20
SET COLOR TO N/W
CLS
WOpen( nT, nL, nT+nH, nL+nW, .T. )
WBox()
aInfo := WInfo()
FOR i:=1 TO Len( aInfo )
? "aInfo[" + Str(i,1) + "] :=", Str(aInfo[i],2)
NEXT
** result:
// aInfo[1] := 4
// aInfo[2] := 6
// aInfo[3] := 24
// aInfo[4] := 56
// aInfo[5] := 5
// aInfo[6] := 7
// aInfo[7] := 23
// aInfo[8] := 55
Inkey(0)
WClose()
RETURN
http://www.xHarbour.com