Skip to content

Match Battle.net's DPI to the monitor scale on launch (4.5) - #17513

Merged
ryanrhughes merged 1 commit into
v4-5-0from
backport/v4-5-0-battlenet-dpi
Nov 4, 2026
Merged

ryanrhughes merged 1 commit into
v4-5-0from
backport/v4-5-0-battlenet-dpi

Conversation

@ryanrhughes

Copy link
Copy Markdown
Collaborator

Backports #17418 to 4.5. On a HiDPI monitor the Battle.net launcher opens at 100% and looks half-size. Hyprland leaves XWayland apps unscaled (xwayland:force_zero_scaling), and Wine takes its scale from the LogPixels DPI value in the prefix registry, which stays at Wine's default of 96.

omarchy-launch-battlenet now sets LogPixels to the focused monitor's scale × 96 before each launch, so a scale change takes effect the next time Battle.net starts. While the prefix's wineserver is running, it leaves the value alone: the running launcher would ignore it, and wineserver writes its own copy back over user.reg on exit.

This is a clean cherry-pick of the #17418 squash commit, 24e56174. Both files match quattro byte for byte, and test/shell.d/launch-battlenet-test.sh passes on this branch.

Scope and risk

Only Battle.net launches through omarchy-launch-battlenet are affected. The script rewrites only existing LogPixels lines in the Battle.net prefix's user.reg, and skips the write if Hyprland reports no focused monitor scale. To undo it, revert this commit; the prefix keeps whatever DPI was last written until it's changed again.

Hyprland leaves XWayland apps unscaled, and Wine reads its DPI from the prefix registry, so the launcher opened at 100% on HiDPI monitors. omarchy-launch-battlenet now sets LogPixels to the focused monitor's scale x 96 before each launch, and leaves it alone while the prefix's wineserver is running.
@greptile-apps

greptile-apps Bot commented Nov 4, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerView in GreptileConfidence Score: 5/5

[Low impact] The PR appears safe to merge.

Summary

omarchy-launch-battlenet now matches Wine’s DPI to the focused monitor before starting Battle.net.

  • Battle.net launches use the focused monitor’s scale for Wine’s DPI.

Reviews (1) · Last reviewed commit: "Match Battle.net's DPI to the monitor sc..." · Reviewed by Greptile

@ryanrhughes
ryanrhughes merged commit 6c363f9 into v4-5-0 Nov 4, 2026
2 checks passed
@ryanrhughes
ryanrhughes deleted the backport/v4-5-0-battlenet-dpi branch November 4, 2026 04:47
@emirb emirb added this to the 4.5 milestone Nov 5, 2026
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