From e42bc7e16e6d9f813b5c712261dffbef6b1bddb2 Mon Sep 17 00:00:00 2001 From: joe berner Date: Tue, 18 Dec 2018 10:59:15 -0600 Subject: Changes the UI interface so that only the current page is rendered on screen at a time. This has significant memory benefits for large PDF files. This also implements a least-recently used cache of tunable size, which improves responsiveness if you're hopping between two specific pages. --- src-qt5/desktop-utils/lumina-pdf/main.cpp | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) (limited to 'src-qt5/desktop-utils/lumina-pdf/main.cpp') diff --git a/src-qt5/desktop-utils/lumina-pdf/main.cpp b/src-qt5/desktop-utils/lumina-pdf/main.cpp index f0430fc8..5e2ed0a9 100644 --- a/src-qt5/desktop-utils/lumina-pdf/main.cpp +++ b/src-qt5/desktop-utils/lumina-pdf/main.cpp @@ -1,28 +1,31 @@ -#include #include #include #include +#include #include "mainUI.h" #include //#include -int main(int argc, char ** argv) -{ - //LTHEME::LoadCustomEnvSettings(); - unsetenv("QT_AUTO_SCREEN_SCALE_FACTOR"); //need pixel-perfect geometries +int main(int argc, char **argv) { + // LTHEME::LoadCustomEnvSettings(); + unsetenv("QT_AUTO_SCREEN_SCALE_FACTOR"); // need pixel-perfect geometries QApplication a(argc, argv); LUtils::LoadTranslation(&a, "l-pdf"); - //Read the input variables + // Read the input variables QString path = ""; - for(int i=1; i