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

# TCustomTreeView.WMHScroll

Handles the LM_HSCROLL message for the control.

## Declaration

Source position: comctrls.pp line 3637

`protected procedure TCustomTreeView.WMHScroll(`
`var Msg: TLMScroll`
`); message;`

## Arguments

`Msg` |  | Window message handled in the method.

## Description

WMHScroll ensures that the ScrollLeft property is updated to apply the horizontal scroll code passed in the Msg argument. The following scroll codes are handled in the method:

SB_LEFT
  Sets ScrolledLeft to 0.
SB_RIGHT
  Sets ScrolledLeft to its largest value for the visible control area.
SB_LINERIGHT
  Increments ScrolledLeft by one-half of the default ItemHeight for the control.
SB_LINELEFT
  Decrements ScrolledLeft by one-half of the default ItemHeight for the control.
SB_PAGERIGHT
  Increments ScrolledLeft by one page of lines.
SB_PAGELEFT
  Decrements ScrolleLeft by one page of lines.
SB_THUMBPOSITION, SB_THUMBTRACK
  Sets ScrolledLeft to the current scroll bar position in Msg.
SB_ENDSCROLL
  Ends scroll bar message handling.