2.2.1.3.1.2.1 New or Existing Window
A Window Information Order is generated by the server whenever a new window is created on the server or when a property on a new or existing window is updated. The window metrics sent in this order are illustrated in the "An illustration of the window metrics sent in the Window Information Order" figure in section 3.3.5.1.6.
|
|
|
|
|
|
|
|
|
|
1 |
|
|
|
|
|
|
|
|
|
2 |
|
|
|
|
|
|
|
|
|
3 |
|
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Hdr |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
... |
OwnerWindowId (optional) |
||||||||||||||||||||||||||||||
... |
Style (optional) |
||||||||||||||||||||||||||||||
... |
ExtendedStyle (optional) |
||||||||||||||||||||||||||||||
... |
ShowState (optional) |
||||||||||||||||||||||||||||||
TitleInfo (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
ClientOffsetX (optional) |
|||||||||||||||||||||||||||||||
ClientOffsetY (optional) |
|||||||||||||||||||||||||||||||
ClientAreaWidth (optional) |
|||||||||||||||||||||||||||||||
ClientAreaHeight (optional) |
|||||||||||||||||||||||||||||||
WindowLeftResizeMargin (optional) |
|||||||||||||||||||||||||||||||
WindowRightResizeMargin (optional) |
|||||||||||||||||||||||||||||||
WindowTopResizeMargin (optional) |
|||||||||||||||||||||||||||||||
WindowBottomResizeMargin (optional) |
|||||||||||||||||||||||||||||||
RPContent (optional) |
RootParentHandle (optional) |
||||||||||||||||||||||||||||||
... |
WindowOffsetX (optional) |
||||||||||||||||||||||||||||||
... |
WindowOffsetY (optional) |
||||||||||||||||||||||||||||||
... |
WindowClientDeltaX (optional) |
||||||||||||||||||||||||||||||
... |
WindowClientDeltaY (optional) |
||||||||||||||||||||||||||||||
... |
WindowWidth (optional) |
||||||||||||||||||||||||||||||
... |
WindowHeight (optional) |
||||||||||||||||||||||||||||||
... |
NumWindowRects (optional) |
WindowRects (variable) |
|||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
VisibleOffsetX (optional) |
|||||||||||||||||||||||||||||||
VisibleOffsetY (optional) |
|||||||||||||||||||||||||||||||
NumVisibilityRects (optional) |
VisibilityRects (variable) |
||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
OverlayDescription (variable) |
|||||||||||||||||||||||||||||||
... |
|||||||||||||||||||||||||||||||
TaskbarButton (optional) |
EnforceServerZOrder (optional) |
AppBarState (optional) |
AppBarEdge (optional) |
Hdr (11 bytes): Eleven bytes. Common Window AltSec Order header, TS_WINDOW_ORDER_HEADER. The FieldsPresentFlags field of the header MUST conform to the values defined as follows.
-
Value
Meaning
0x01000000
WINDOW_ORDER_TYPE_WINDOW
Indicates a Windowing Alternate Secondary Drawing Order describing a window. This flag MUST be set.
0x10000000
WINDOW_ORDER_STATE_NEW
Indicates that the Windowing Alternate Secondary Drawing Order contains information for a new window. If this flag is not set, the order contains information for an existing window.
0x00000002
WINDOW_ORDER_FIELD_OWNER
Indicates that the OwnerWindowId field is present.
0x00000008
WINDOW_ORDER_FIELD_STYLE
Indicates that the Style and ExtendedStyle fields are present.
0x00000010
WINDOW_ORDER_FIELD_SHOW
Indicates that the ShowState field is present.
0x00000004
WINDOW_ORDER_FIELD_TITLE
Indicates that the TitleInfo field is present.
0x00004000
WINDOW_ORDER_FIELD_CLIENTAREAOFFSET
Indicates that the ClientOffsetX and ClientOffsetY fields are present.
0x00010000
WINDOW_ORDER_FIELD_CLIENTAREASIZE
Indicates that the ClientAreaWidth and ClientAreaHeight fields are present.<3>
0x00000080
WINDOW_ORDER_FIELD_RESIZE_MARGIN_X
Indicates that the WindowLeftResizeMargin and WindowRightResizeMargin fields are present.
0x08000000
WINDOW_ORDER_FIELD_RESIZE_MARGIN_Y
Indicates that the WindowTopResizeMargin and WindowBottomResizeMargin fields are present.
0x00020000
WINDOW_ORDER_FIELD_RPCONTENT
Indicates that the RPContent field is present. <4>
0x00040000
WINDOW_ORDER_FIELD_ROOTPARENT
Indicates that the RootParentHandle field is present. <5>
0x00000800
WINDOW_ORDER_FIELD_WNDOFFSET
Indicates that the WindowOffsetX and WindowOffsetY fields are present.
0x00008000
WINDOW_ORDER_FIELD_CLIENTDELTA
Indicates that the WindowClientDeltaX and WindowClientDeltaY fields are present.
0x00000400
WINDOW_ORDER_FIELD_WNDSIZE
Indicates that the WindowWidth and WindowHeight fields are present.
0x00000100
WINDOW_ORDER_FIELD_WNDRECTS
Indicates that the NumWindowRects and WindowRects fields are present.
0x00001000
WINDOW_ORDER_FIELD_VISOFFSET
Indicates that the VisibleOffsetX and VisibleOffsetY fields are present.
0x00000200
WINDOW_ORDER_FIELD_VISIBILITY
Indicates that the NumVisibilityRects and VisibilityRects fields are present.
0x00400000
WINDOW_ORDER_FIELD_OVERLAY_DESCRIPTION
Indicates that the OverlayDescription field is present.
0x00200000
WINDOW_ORDER_FIELD_ICON_OVERLAY_NULL
Indicates that a taskbar overlay icon previously set by the window has been removed.
0x00800000
WINDOW_ORDER_FIELD_TASKBAR_BUTTON
Indicates that the TaskbarButton field is present.
0x00080000
WINDOW_ORDER_FIELD_ENFORCE_SERVER_ZORDER
Indicates that the EnforceServerZOrder field is present.
0x00000040
WINDOW_ORDER_FIELD_APPBAR_STATE
Indicates that the AppBarState field is present.
0x00000001
WINDOW_ORDER_FIELD_APPBAR_EDGE
Indicates that the AppBarEdge field is present.
OwnerWindowId (4 bytes): An unsigned 32-bit integer. The ID of the window on the server that is the owner of the window specified in WindowId field of Hdr. For more information on owned windows, see [MSDN-WINFEATURE]. This field is present if and only if the WINDOW_ORDER_FIELD_OWNER flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
Style (4 bytes): An unsigned 32-bit integer. Describes the window's current style. Window styles determine the appearance and behavior of a window. For more information, see [MSDN-WINSTYLE]. This field is present if and only if the WINDOW_ORDER_FIELD_STYLE flag is set in the FieldsPresentFlags field of the TS_WINDOW_ORDER_HEADER.
ExtendedStyle (4 bytes): An unsigned 32-bit integer. Extended window style information. For more information about extended window styles, see [MSDN-CREATEWINEX].
-
This field is present if and only if the WINDOW_ORDER_FIELD_STYLE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
ShowState (1 byte): An unsigned 8-bit integer. Describes the show state of the window.
-
This field is present if and only if the WINDOW_ORDER_FIELD_SHOW flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
-
The field MUST be one of the following values.
-
Value
Meaning
0x00
Do not show the window.
0x02
Show the window minimized.
0x03
Show the window maximized.
0x05
Show the window in its current size and position.
TitleInfo (variable): UNICODE_STRING. Variable length. Contains the window's title string. This string is not guaranteed to be null-terminated. The maximum value for the CbString field of UNICODE_STRING is 520 bytes. This structure is present only if the WINDOW_ORDER_FIELD_TITLE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
ClientOffsetX (4 bytes): A 32-bit signed integer. The X (horizontal) offset from the top-left corner of the screen to the top-left corner of the window's client area, expressed in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_CLIENTAREAOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
ClientOffsetY (4 bytes): A 32-bit signed integer. The Y (vertical) offset from the top-left corner of the screen to the top-left corner of the window's client area, expressed in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_CLIENTAREAOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
ClientAreaWidth (4 bytes): An unsigned 32-bit integer specifying the width of the client area rectangle of the target window.
-
This field only appears if the WndSupportLevel field of the Window List Capability Set message is set to TS_WINDOW_LEVEL_SUPPORTED_EX (as specified in section 2.2.1.1.2) and the WINDOW_ORDER_FIELD_CLIENTAREASIZE flag is set in the FieldsPresentFlags field of the TS_WINDOW_ORDER_HEADER packet (section 2.2.1.3.1.1).
ClientAreaHeight (4 bytes): An unsigned 32-bit integer specifying the height of the client area rectangle of the target window.
-
This field only appears if the WndSupportLevel field of the Window List Capability Set message is set to TS_WINDOW_LEVEL_SUPPORTED_EX (as specified in section 2.2.1.1.2) and the Hdr field has the WINDOW_ORDER_FIELD_CLIENTAREASIZE flag is set in the FieldsPresentFlags field of the TS_WINDOW_ORDER_HEADER packet (section 2.2.1.3.1.1).
WindowLeftResizeMargin (4 bytes): An unsigned 32-bit integer specifying the width of the transparent hit-testable margin along the left edge of the window. Any mouse, pen, or touch input within this margin SHOULD be sent to the server.
-
This field is present only if the WINDOW_ORDER_FIELD_RESIZE_MARGIN_X flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
-
Resize margins SHOULD be used to extend the window geometry (defined by the WindowOffsetX, WindowOffsetY, WindowWidth and WindowHeight fields) and are not included in the window boundaries.
WindowRightResizeMargin (4 bytes): An unsigned 32-bit integer specifying the width of the transparent hit-testable margin along the right edge of the window. Any mouse, pen or touch input within this margin SHOULD be sent to the server.
-
This field is present only if the WINDOW_ORDER_FIELD_RESIZE_MARGIN_X flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
-
Resize margins SHOULD be used to extend the window geometry (defined by the WindowOffsetX, WindowOffsetY, WindowWidth and WindowHeight fields) and are not included in the window boundaries.
WindowTopResizeMargin (4 bytes): An unsigned 32-bit integer specifying the height of the transparent hit-testable margin along the top edge of the window. Any mouse, pen or touch input within this margin SHOULD be sent to the server.
-
This field is present only if the WINDOW_ORDER_FIELD_RESIZE_MARGIN_Y flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
-
Resize margins SHOULD be used to extend the window geometry (defined by the WindowOffsetX, WindowOffsetY, WindowWidth and WindowHeight fields) and are not included in the window boundaries.
WindowBottomResizeMargin (4 bytes): An unsigned 32-bit integer specifying the height of the transparent hit-testable margin along the bottom edge of the window. Any mouse, pen or touch input within this margin SHOULD be sent to the server.
-
This field is present only if the WINDOW_ORDER_FIELD_RESIZE_MARGIN_Y flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
-
Resize margins SHOULD be used to extend the window geometry (defined by the WindowOffsetX, WindowOffsetY, WindowWidth and WindowHeight fields) and are not included in the window boundaries.
RPContent (1 byte): An unsigned BYTE that MUST be set to one of the following possible values.
-
Value
Meaning
0x00
The window is not used by a render plug-in to do client-side rendering.
0x01
The window is used by a render plug-in to do client-side rendering.
-
This field only appears if the WndSupportLevel field of the Window List Capability Set message is set to TS_WINDOW_LEVEL_SUPPORTED_EX (as specified in section 2.2.1.1.2) and the Hdr field has the WINDOW_ORDER_FIELD_RPCONTENT flag is set in the FieldsPresentFlags field of the TS_WINDOW_ORDER_HEADER packet (section 2.2.1.3.1.1).
RootParentHandle (4 bytes): An unsigned 32-bit integer specifying the server-side target window's top-level parent window handle. A Top-Level parent window is the window immediately below "desktop" in the window hierarchy. If the target window is a top-level window, the window handle of the target window is sent.
-
This field only appears if the WndSupportLevel field of the Window List Capability Set message is set to TS_WINDOW_LEVEL_SUPPORTED_EX (as specified in section 2.2.1.1.2) and the Hdr field has the WINDOW_ORDER_FIELD_ROOTPARENT flag is set in the FieldsPresentFlags field of the TS_WINDOW_ORDER_HEADER packet (section 2.2.1.3.1.1).
WindowOffsetX (4 bytes): A 32-bit signed integer. The X (horizontal) offset from the top-left corner of the primary monitor to the top-left corner of the window, expressed in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_WNDOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowOffsetY (4 bytes): A 32-bit signed integer. The Y (vertical) offset from the top-left corner of the primary monitor to the top-left corner of the window, expressed in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_WNDOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowClientDeltaX (4 bytes): A 32-bit signed integer. The X (horizontal) delta between the top-left corner of the window and the window's client area.
-
This field is present only if the WINDOW_ORDER_FIELD_CLIENTDELTA flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowClientDeltaY (4 bytes): A 32-bit signed integer. The Y (vertical) delta between the top-left corner of the window and the window's client area.
-
This field is present only if the WINDOW_ORDER_FIELD_CLIENTDELTA flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowWidth (4 bytes): An unsigned 32-bit integer. The window width, in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_WNDSIZE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowHeight (4 bytes): An unsigned 32-bit integer. The window height, in screen coordinates.
-
This field is present only if the WINDOW_ORDER_FIELD_WNDSIZE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
NumWindowRects (2 bytes): An unsigned 16-bit integer. A count of rectangles describing the window geometry.
-
This field is present only if the WINDOW_ORDER_FIELD_WNDRECTS flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
WindowRects (variable): An array of TS_RECTANGLE_16 structures, NumWindowRects wide, describing the window geometry. All coordinates are window coordinates.
-
This field is present only if the NumWindowRects field is greater than 0 and the WINDOW_ORDER_FIELD_WNDRECTS flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
VisibleOffsetX (4 bytes): A 32-bit signed integer. The X (horizontal) offset from the top-left corner of the screen to the top-left corner of the window visible region's bounding rectangle, expressed in screen coordinates.<6>
-
This field is present only if the WINDOW_ORDER_FIELD_VISOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
VisibleOffsetY (4 bytes): A 32-bit signed integer. The Y (vertical) offset from the top-left corner of the screen to the top-left corner of the window visible region's bounding rectangle, expressed in screen coordinates.<7>
-
This field is present only if the WINDOW_ORDER_FIELD_VISOFFSET flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
NumVisibilityRects (2 bytes): An unsigned 16-bit integer. A count of rectangles describing the window visible region.
-
This field is present only if the WINDOW_ORDER_FIELD_VISIBILITY flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
VisibilityRects (variable): An array of TS_RECTANGLE_16 structures, NumVisibilityRects wide, describing the window visible region. All coordinates are window coordinates.
-
This field is present only if the value of the NumVisibilityRects field is greater than 0 and the WINDOW_ORDER_FIELD_VISIBILITY flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
OverlayDescription (variable, optional): A variable length UNICODE_STRING (section 2.2.1.2.1) that contains the description text for the window's overlay icon (see sections 2.2.1.3.1.2.2 and 2.2.1.3.1.2.3).
-
This field is present only if the WINDOW_ORDER_FIELD_OVERLAY_DESCRIPTION flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
TaskbarButton (1 byte, optional): An 8-bit unsigned integer. If this field is set to 0x00, then the client SHOULD add a tab to the taskbar button group for the window, if supported by the operating system, instead of adding a new taskbar button for the window. If this field is set to 0x01, then the client SHOULD remove the tab from the taskbar button group for the window.
-
Windows share a taskbar button group if they have matching Application IDs, as specified by the Server Get Application ID Response PDU (section 2.2.2.8.1).
-
This field is present only if the WINDOW_ORDER_FIELD_TASKBAR_BUTTON flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
EnforceServerZOrder (1 byte, optional): An 8-bit unsigned integer. If this field is set to 0x01, then the client SHOULD order this window, and all other windows in the Z-order list (in the Actively Monitored Desktop packet, as specified in section 2.2.1.3.3.2.1) that also have the field set consecutively per the Z-order hierarchy. The client SHOULD NOT attempt to reorder these windows with respect to each other, or to move any window between the windows in this group.
-
If this field is set to 0x00, then no special Z-order handling is required.
-
This field is present only if the WINDOW_ORDER_FIELD_ENFORCE_SERVER_ZORDER flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
AppBarState (1 byte, optional): An 8-bit unsigned integer. If this field is set to 0x01, then the window SHOULD be registered as an application desktop toolbar. If this field is set to 0x00, then the application desktop toolbar SHOULD be deregistered.
-
This field is present only if the WINDOW_ORDER_FIELD_APPBAR_STATE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.
AppBarEdge (1 byte, optional): An 8-bit unsigned integer. The value of this field indicates the edge to which the application desktop toolbar SHOULD be anchored. This field MUST be set to one of the following possible values.
-
Value
Meaning
0x00
Anchor to the left edge.
0x01
Anchor to the top edge.
0x02
Anchor to the right edge.
0x03
Anchor to the bottom edge.
-
This field is present only if the WINDOW_ORDER_FIELD_APPBAR_EDGE flag is set in the FieldsPresentFlags field of TS_WINDOW_ORDER_HEADER.