[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] | Reference for unit 'Forms' (#lcl)

# TCustomForm.WMWindowPosChanged

Handles the LM_WINDOWPOSCHANGED window message for the form.

## Declaration

Source position: forms.pp line 613

`protected procedure TCustomForm.WMWindowPosChanged(`
`var Message: TLMWindowPosChanged`
`); message;`

## Arguments

`Message` |  | Message examined in the method.

## Description

Re-implements the method from the ancestor class.

Ensures that auto-sizing is disabled for a position message to a top-level form (where Parent is not assigned), or from the LCL interface when new height or width values are provided. This is done by including the value fsDisableAutoSize in the FormState property.

Calls the inherited method prior to exit to apply the position and bounds for the form.