dotnet / dotnet/winforms

ItemHeight of ListBox is not scaled on high DPI in OwnerDrawFixed mode

Open
#6,382 0 comments 4 reactions 1 assignee Claimed by @ricardobossan View on GitHub
:construction: work in progress area-HDPI
Dominant language
C#
Stars
4.9k
Forks
1.1k
Avg merge
20h 23m
Merged PRs (30d)
103

Description

* .NET Core Version:
6.0

* Have you experienced this same bug with .NET Framework?:
No

**Problem description:**

When using ListBox in the OwnerDrawFixed mode, item heights are not scaled.
Scale 100%
![scale100](https://user-images.githubusercontent.com/9930867/146963072-7692bfbe-e38d-42dc-a565-525709369ef8.png)
Scale 150%
![scale100](https://user-images.githubusercontent.com/9930867/146963091-2ce18abd-ef5b-42b6-acd0-931b7aa16c30.png)

**Expected behavior:**
Item heights are scaled in the OwnerDrawFixed mode.

**Minimal repro:**
Sample app is attached. Run it with 100% and 150% scaling.
[ItemHeightBug.zip](https://github.com/dotnet/winforms/files/7756694/ItemHeightBug.zip)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.