[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    [Rekonq] 3af01d7: Minor change to better debug fonts DPI..
From:       Andrea Diamantini <adjam7 () gmail ! com>
Date:       2010-05-31 23:27:06
Message-ID: 201005312327.o4VNR6SV021591 () kore ! kollide ! net
[Download RAW message or body]

commit 3af01d702411c2f724c87417a4b3bd99d7e8d53e
Author: Andrea Diamantini <adjam7@gmail.com>
Date:   Mon May 31 23:53:40 2010 +0200

    Minor change to better debug fonts DPI..

diff --git a/src/application.cpp b/src/application.cpp
index 732bb27..9620feb 100644
--- a/src/application.cpp
+++ b/src/application.cpp
@@ -447,10 +447,12 @@ void Application::updateConfiguration()
     int defaultFontSize = ReKonfig::defaultFontSize();    
     int minimumFontSize = ReKonfig::minFontSize();
     
-    float toPix = mainWindow()->currentTab()->view()->logicalDpiY()/72.0;
-
-    if (toPix < 96.0/72.0) 
-        toPix = 96.0/72.0;
+    int logDpiY = mainWindow()->currentTab()->view()->logicalDpiY();
+    kDebug() << "Logical Dot per Inch Y: " << logDpiY;
+    
+    float toPix = (logDpiY < 96.0)
+        ? 96.0/72.0
+        : logDpiY/72.0 ;
 
     defaultSettings->setFontSize(QWebSettings::DefaultFontSize, qRound(defaultFontSize * toPix) );
     defaultSettings->setFontSize(QWebSettings::MinimumFontSize, qRound(minimumFontSize * toPix) );
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic