D10415: Fix realDpi function for Mac

Sergio Bragin noreply at phabricator.kde.org
Sun Feb 11 12:54:22 UTC 2018


sbragin added a comment.


  In D10415#204346 <https://phabricator.kde.org/D10415#204346>, @cullmann wrote:
  
  > In our company we use the logicalDpiX()/logicalDpiY() on the widget we paint to, that works on macOS, too.
  >
  > I assume the physicalDotsPerInchY() should work the same.
  
  
  I think they are not exactly the same. physicalDotsPerInchY() would give twice difference in the resolution depending on whether one uses the native or HiDPI mode. But logicalDpiX()/logicalDpiY() would return the same value in both cases.
  
  > Sidenote: do we need to go over QScreen? We just use the function of the widget in question which is there via QPaintDevice.
  >  Which here would be just widgetOnScreen->physicalDpi....
  
  Well, that's a relevant question, but should be addressed to the Okular developers. I just kept the code that was already there.

REPOSITORY
  R223 Okular

BRANCH
  master

REVISION DETAIL
  https://phabricator.kde.org/D10415

To: sbragin, #okular, rjvbb
Cc: rjvbb, cullmann, aacid, kde-mac, ltoscano, #okular, michaelweghorn, ngraham
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-mac/attachments/20180211/4aab0f65/attachment.html>


More information about the kde-mac mailing list