Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dpi-aware process for Winforms #704

Merged
merged 2 commits into from
Jun 1, 2019
Merged

Conversation

obulat
Copy link
Contributor

@obulat obulat commented Jun 1, 2019

Currently toga Winforms apps are rendered with 96 dpi, and virtually scaled to higher dpi monitors which makes text and controls appear blurry on high dpi monitors.

This PR sets app process to be dpi aware, which makes texts appear crisper, and makes window size smaller. It is only set so on Windows major versions higher than 6.0 (Windows Vista, apparently).

The change can be seen on this screenshot, the dpi-aware window is on the left, and the previous dpi-non-aware window is on the right.
win_dpi_changes

PR Checklist:

  • All new features have been tested
  • All new features have been documented
  • I have read the CONTRIBUTING.md file
  • I will abide by the code of conduct

Signed-off-by: Olga Bulat <obulat@gmail.com>
Signed-off-by: Olga Bulat <obulat@gmail.com>
Copy link
Member

@freakboy3742 freakboy3742 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

From a quick poke around, it looks like these two lines are added automatically to every new C# application as part of the template, so it makes sense we'd do the same.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants