rooler icon indicating copy to clipboard operation
rooler copied to clipboard

Fix display scaling and positioning

Open DanielRose opened this issue 3 years ago • 3 comments

This solves some problems:

  1. The primary screen has a top/left position of 0, 0. In a multi-monitor setup, if there are screens to the left/above the primary screen, then those screens have negative coordinates. This corrects the calculations where needed. This fixes #5
  2. WPF uses coordinates and sizes based on a virtual 96dpi screen. If a user sets display scaling (ex. 150%), the virtual WPF pixels will not be the same as the native pixels. Besides fixing internal problems related to that, in those cases the "WPF" pixels and "native" pixels are both shown (ex. for bounds, spacing). The WPF value is shown first, with the native value in parentheses.
    • Note that WPF uses the display scaling of the primary screen everywhere. It is possible to have different values per screen, but WPF does not handle that case. In those cases, the "native" values for other screens will be incorrect.
  3. At least in my system, using the DropShadowEffect causes access violations, so I removed it.

DanielRose avatar Sep 29 '22 11:09 DanielRose

Hello, I have no idea what all the coding means when I look through this information. But I have a very basic question that I hope you can answer. I have an image brought up in Photoshop that is approximately 2357 x 2357 pixels at 300 DPI. When I use the Screen Ruler, it measures the image as 713 x 761. Is there a setting that I need to adjust to make the Screen Ruler read my image exactly (or close) to what the image is?

LadyCritique avatar Mar 12 '24 16:03 LadyCritique

Hello, I have no idea what all the coding means when I look through this information. But I have a very basic question that I hope you can answer. I have an image brought up in Photoshop that is approximately 2357 x 2357 pixels at 300 DPI. When I use the Screen Ruler, it measures the image as 713 x 761. Is there a setting that I need to adjust to make the Screen Ruler read my image exactly (or close) to what the image is?

The screen ruler measure the screen pixels. You are probably not displaying the image at 100% zoom.

DanielRose avatar Mar 13 '24 08:03 DanielRose

Thank you so much for your reply!!! That totally makes sense! So if my image is at 50%, then I can use the ruler and multiple by 2 to get the correct reading! Thank you so much for explaining that, I never would have figured that out...it seems so simple now. Thanks again NJ King

On 3/13/2024 4:22:41 AM, Daniel Rose @.> wrote: Hello, I have no idea what all the coding means when I look through this information. But I have a very basic question that I hope you can answer. I have an image brought up in Photoshop that is approximately 2357 x 2357 pixels at 300 DPI. When I use the Screen Ruler, it measures the image as 713 x 761. Is there a setting that I need to adjust to make the Screen Ruler read my image exactly (or close) to what the image is? The screen ruler measure the screen pixels. You are probably not displaying the image at 100% zoom. — Reply to this email directly, view it on GitHub [https://github.com/peteblois/rooler/pull/6#issuecomment-1993798084], or unsubscribe [https://github.com/notifications/unsubscribe-auth/AKPNFKZZEG2INH4UFBZZEYDYYAEE3AVCNFSM6AAAAAAQYVMKMSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTSOJTG44TQMBYGQ]. You are receiving this because you commented.Message ID: @.> [fc8e879a-1f10-47d2-8da7-e9fbfc2f2d9e]

LadyCritique avatar Mar 13 '24 16:03 LadyCritique