https://github.com/salarcode/salar.dpiaware
High DPI Per-Monitor Windows Forms
https://github.com/salarcode/salar.dpiaware
Last synced: 12 months ago
JSON representation
High DPI Per-Monitor Windows Forms
- Host: GitHub
- URL: https://github.com/salarcode/salar.dpiaware
- Owner: salarcode
- License: bsd-2-clause
- Created: 2016-06-09T17:52:53.000Z (about 10 years ago)
- Default Branch: master
- Last Pushed: 2016-11-30T06:46:49.000Z (over 9 years ago)
- Last Synced: 2025-06-24T17:07:26.645Z (12 months ago)
- Language: C#
- Size: 21.5 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
##Salar.DpiAware
High DPI Per-Monitor Windows Forms
Automatically updates forms respecting current monitors' DPI.
The original work is thanks to emoacht:
[https://emoacht.wordpress.com/2013/10/30/per-monitor-dpi-aware-in-windows-forms/](https://emoacht.wordpress.com/2013/10/30/per-monitor-dpi-aware-in-windows-forms/)
###[NuGet Package](https://www.nuget.org/packages/Salar.DpiAware/)
```
PM> Install-Package Salar.DpiAware
```
###How to enable DPI-Aware in your application.
For now read this page: [Per-Monitor DPI Aware in Windows Forms](https://emoacht.wordpress.com/2013/10/30/per-monitor-dpi-aware-in-windows-forms/)
###How to use
Just change the base class of your form to Salar.HDpiForm and you're done!
```csharp
public partial class frmSampleForm : Salar.HDpiForm
{
...
```
There is also an event named `OnDpiChange` which will be fired when after a DPI change is detected and applied.