Export (0) Print
Expand All

Mouse.MouseWheelDeltaForOneLine Field

Represents the number of units the mouse wheel is rotated to scroll one line.

Namespace:  System.Windows.Input
Assembly:  PresentationCore (in PresentationCore.dll)

public const int MouseWheelDeltaForOneLine
You cannot use fields in XAML.

Field Value

Type: System.Int32
The units in one scroll line.

In the current Windows Presentation Foundation (WPF), the value of this field is 120. The intention of the field exposure is to allow for vendors to build finer-resolution mouse wheels in the future, that perhaps would include a freely rotating wheel without notches. The expectation is that such a device would send more messages per rotation, but with a smaller value in each message. To support this possibility, you should either add the incoming delta values until the MouseWheelDeltaForOneLine amount is reached (so for a delta-rotation you get the same response), or scroll partial lines in response to the more frequent messages. You could also choose your own scroll granularity and accumulate deltas of your own choosing until that delta is reached, or perhaps reference user-controllable system parameters for mouse sensitivity and extrapolate these to mouse wheel delta thresholds.

Windows 7, Windows Vista, Windows XP SP2, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0

Community Additions

ADD
Show:
© 2014 Microsoft