4 instantiations of DpiScale2
PresentationCore (4)
MS\Internal\DpiScale2.cs (1)
208
return new
DpiScale2
(ppiX / DpiUtil.DefaultPixelsPerInch, ppiY / DpiUtil.DefaultPixelsPerInch);
MS\Internal\DpiUtil\DpiUtil+SystemDpiHelper.cs (1)
70
return new
DpiScale2
(UIElement.DpiScaleXValues[0], UIElement.DpiScaleYValues[0]);
System\Windows\InterOp\HwndTarget.cs (2)
1747
var newDpi = new
DpiScale2
(e.NewDpi);
1769
var newDpi = new
DpiScale2
(e.NewDpi);
62 references to DpiScale2
PresentationCore (60)
MS\Internal\DpiScale2.cs (19)
13
internal class DpiScale2 : IEquatable<
DpiScale2
>, IEquatable<DpiScale>
18
/// Initializes a new instance of the <see cref="
DpiScale2
"/> class.
27
/// Initializes a new instance of the <see cref="
DpiScale2
"/> class.
77
/// Implicitly casts a <see cref="
DpiScale2
"/> object to
80
/// <param name="dpiScale2">The <see cref="
DpiScale2
"/> object that is
82
public static implicit operator DpiScale(
DpiScale2
dpiScale2)
88
/// Checks to inequality between two <see cref="
DpiScale2
"/> instances.
93
public static bool operator !=(
DpiScale2
dpiScaleA,
DpiScale2
dpiScaleB)
105
/// Checks for equality between two <see cref="
DpiScale2
"/> instances.
110
public static bool operator ==(
DpiScale2
dpiScaleA,
DpiScale2
dpiScaleB)
134
/// Equality test against a <see cref="
DpiScale2
"/> object.
151
public bool Equals(
DpiScale2
dpiScale2)
174
else if (obj is
DpiScale2
)
176
areEqual = this.Equals((
DpiScale2
)obj);
196
/// Creates an instances of <see cref="
DpiScale2
"/> from PPI values.
200
/// <returns>A new <see cref="
DpiScale2
"/> instance</returns>
201
internal static
DpiScale2
FromPixelsPerInch(double ppiX, double ppiY)
MS\Internal\DpiUtil\DpiUtil.cs (6)
94
internal static
DpiScale2
GetSystemDpi()
103
internal static
DpiScale2
GetSystemDpiFromUIElementCache()
112
internal static void UpdateUIElementCacheForSystemDpi(
DpiScale2
systemDpiScale)
127
internal static
DpiScale2
GetWindowDpi(IntPtr hWnd, bool fallbackToNearestMonitorHeuristic)
134
/// <see cref="
DpiScale2
"/>, and the screen-rectangle of the monitor where the <paramref name="hWnd"/> resides.
146
/// <see cref="
DpiScale2
"/>, and the screen-rectangle of the monitor where the <paramref name="hWnd"/> resides.
MS\Internal\DpiUtil\DpiUtil+HwndDpiInfo.cs (4)
21
public class HwndDpiInfo : Tuple<DpiAwarenessContextValue,
DpiScale2
>
37
/// and <see cref="
DpiScale2
"/> information
41
internal HwndDpiInfo(DpiAwarenessContextValue dpiAwarenessContextValue,
DpiScale2
dpiScale)
87
internal
DpiScale2
DpiScale { get => Item2; }
MS\Internal\DpiUtil\DpiUtil+SystemDpiHelper.cs (7)
45
internal static
DpiScale2
GetSystemDpi()
66
internal static
DpiScale2
GetSystemDpiFromUIElementCache()
78
internal static void UpdateUIElementCacheForSystemDpi(
DpiScale2
systemDpiScale)
91
private static
DpiScale2
GetDpiForSystem()
94
return
DpiScale2
.FromPixelsPerInch(dpi, dpi);
102
private static
DpiScale2
GetSystemDpiFromDeviceCaps()
116
return
DpiScale2
.FromPixelsPerInch(ppiX, ppiY);
MS\Internal\DpiUtil\DpiUtil+WindowDpiScaleHelper.cs (5)
43
internal static
DpiScale2
GetWindowDpi(IntPtr hWnd, bool fallbackToNearestMonitorHeuristic)
79
private static
DpiScale2
GetDpiForWindow(IntPtr hWnd)
82
return
DpiScale2
.FromPixelsPerInch(dpi, dpi);
90
private static
DpiScale2
GetDpiForWindowFromNearestMonitor(IntPtr hWnd)
101
return
DpiScale2
.FromPixelsPerInch(dpiX, dpiY);
System\Windows\Input\Stylus\Common\StylusLogic.cs (2)
173
private readonly Dictionary<
DpiScale2
, Matrix> _transformToDeviceMatrices = new Dictionary<
DpiScale2
, Matrix>();
System\Windows\InterOp\HwndTarget.cs (17)
405
private static
DpiScale2
GetDpiScaleForWindow(IntPtr hWnd)
407
DpiScale2
dpiScale = null;
426
dpiScale =
DpiScale2
.FromPixelsPerInch(DpiUtil.DefaultPixelsPerInch, DpiUtil.DefaultPixelsPerInch);
447
dpiScale =
DpiScale2
.FromPixelsPerInch(
870
var
oldDpi = CurrentDpiScale;
871
var
newDpi =
872
DpiScale2
.FromPixelsPerInch(
903
var
oldDpi = CurrentDpiScale;
904
var
newDpi = GetDpiScaleForWindow(_hWnd);
1674
private void UpdateWorldTransform(
DpiScale2
dpiScale)
1705
private void PropagateDpiChangeToRootVisual(
DpiScale2
oldDpi,
DpiScale2
newDpi)
1746
var
oldDpi = CurrentDpiScale;
1747
var
newDpi = new DpiScale2(e.NewDpi);
1768
var
oldDpi = CurrentDpiScale;
1769
var
newDpi = new DpiScale2(e.NewDpi);
2017
internal
DpiScale2
CurrentDpiScale { get; private set; }
PresentationFramework (2)
System\Windows\SystemResources.cs (2)
1044
/// <param name="hwndDpiInfo">Represents a combination of <see cref="DpiAwarenessContextValue"/> and <see cref="
DpiScale2
"/></param>
1664
/// List of {<see cref="DpiAwarenessContextValue"/> , <see cref="
DpiScale2
"/>} combinations for which notify-windows are being maintained