GetScaleFactorForDevice function

Gets the preferred scale factor for a display device.

Note  This function is not supported as of Windows 8.1. Use GetScaleFactorForMonitor instead.
 

Syntax

DEVICE_SCALE_FACTOR GetScaleFactorForDevice(
  DISPLAY_DEVICE_TYPE deviceType
);

Parameters

deviceType

Type: DISPLAY_DEVICE_TYPE

The value that indicates the type of the display device.

Return Value

Type: DEVICE_SCALE_FACTOR

A value that indicates the scale factor that should be used with the specified DISPLAY_DEVICE_TYPE.

Return code/value Description
SCALE_100_PERCENT
100
Use a scale factor of 1x.
SCALE_140_PERCENT
140
Use a scale factor of 1.4x.
SCALE_180_PERCENT
180
Use a scale factor of 1.8x.

Remarks

The default DEVICE_SCALE_FACTOR is SCALE_100_PERCENT.

Use the scale factor that is returned to scale point values for fonts and pixel values.

Requirements

   
Windows version Windows 8 [desktop apps only] Windows Server 2012 [desktop apps only]
Target Platform Windows
Header shellscalingapi.h
DLL Shcore.dll

See Also

GetScaleFactorForMonitor

RegisterScaleChangeEvent

UnregisterScaleChangeEvent