Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What does SnapsToDevicePixels in WPF mean in layman terms?

Anybody? Say I have a Window Class and I give SnapsToDevicePixels = true? what happens?

like image 871
abmv Avatar asked Apr 23 '09 08:04

abmv


2 Answers

It will enable pixel snapping for every element in your window as this property is inherited by child UI elements. It won't have an effect on the appearance of the window itself, though (i. e. window frame or similar), since windows reside on integral coordinates on the screen already, anyway.

like image 59
Joey Avatar answered Nov 08 '22 02:11

Joey


If so,your will enable pixel snap rendering throughout the UI.For devices operation at greater than 96 dot per inch (dpi),pixel snap rendering can minimize anti-aliasing visual artifacts in the vicinity of single-unit solid lines.And all child elements of that subtree will then report SnapToDevicePixes as true and will have the SnapToDevicePixes visual effect.

like image 1
Jiang Zhanchang Avatar answered Nov 08 '22 00:11

Jiang Zhanchang