--- diffpdf-2.1.3/diffpdf.pro +++ diffpdf-2.1.3/diffpdf.pro @@ -31,35 +31,41 @@ TRANSLATIONS += diffpdf_fr.ts TRANSLATIONS += diffpdf_de.ts TRANSLATIONS += diffpdf_es.ts CODECFORTR = UTF-8 -LIBS += -lpoppler-qt4 +LIBS += -lpoppler-qt5 -lQt5Core -lQt5Widgets -lQt5Gui -lQt5PrintSupport win32 { CONFIG += release } exists($(HOME)/opt/poppler024/) { message(Using locally built Poppler library) INCLUDEPATH += $(HOME)/opt/poppler024/include/poppler/cpp - INCLUDEPATH += $(HOME)/opt/poppler024/include/poppler/qt4 + INCLUDEPATH += $(HOME)/opt/poppler024/include/poppler/qt5 LIBS += -Wl,-rpath -Wl,$(HOME)/opt/poppler024/lib -L$(HOME)/opt/poppler024/lib } else { exists(/poppler_lib) { message(Using locally built Poppler library on Windows) INCLUDEPATH += /c/poppler_lib/include/poppler/cpp - INCLUDEPATH += /c/poppler_lib/include/poppler/qt4 + INCLUDEPATH += /c/poppler_lib/include/poppler/qt5 LIBS += -Wl,-rpath -Wl,/c/poppler_lib/bin -Wl,-L/c/poppler_lib/bin } else { - exists(/usr/include/poppler/qt4) { + exists(/usr/include/poppler/qt5) { INCLUDEPATH += /usr/include/poppler/cpp - INCLUDEPATH += /usr/include/poppler/qt4 + INCLUDEPATH += /usr/include/poppler/qt5 + INCLUDEPATH += /usr/include/qt5/QtCore + INCLUDEPATH += /usr/include/qt5/QtWidgets + INCLUDEPATH += /usr/include/qt5/QtPrintSupport } else { INCLUDEPATH += /usr/local/include/poppler/cpp - INCLUDEPATH += /usr/local/include/poppler/qt4 + INCLUDEPATH += /usr/local/include/poppler/qt5 + INCLUDEPATH += /usr/local/include/qt5/QtCore + INCLUDEPATH += /usr/local/include/qt5/QtWidgets + INCLUDEPATH += /usr/local/include/qt5/QtPrintSupport } } } #exists($(HOME)/opt/podofo09/) { # message(Using locally built PoDoFo library) # INCLUDEPATH += $(HOME)/opt/podofo09/include/poppler/cpp -# INCLUDEPATH += $(HOME)/opt/podofo09/include/poppler/qt4 +# INCLUDEPATH += $(HOME)/opt/podofo09/include/poppler/qt5 # LIBS += -Wl,-rpath -Wl,$(HOME)/opt/podofo09/lib64 -Wl,-L$(HOME)/opt/podofo09/lib64 #} else { # exists(/usr/include/podofo) { --- diffpdf-2.1.3/generic.hpp +++ diffpdf-2.1.3/generic.hpp @@ -12,7 +12,7 @@ for more details. */ -#include +#include #include #include #include --- diffpdf-2.1.3/label.cpp +++ diffpdf-2.1.3/label.cpp @@ -15,6 +15,7 @@ #include #include #include +#include Label::Label(QWidget *parent) : QLabel(parent) { --- diffpdf-2.1.3/lineedit.cpp +++ diffpdf-2.1.3/lineedit.cpp @@ -14,6 +14,7 @@ #include "lineedit.hpp" #include #include +#include LineEdit::LineEdit(QWidget *parent) : QLineEdit(parent) --- diffpdf-2.1.3/main.cpp +++ diffpdf-2.1.3/main.cpp @@ -31,7 +31,6 @@ int main(int argc, char *argv[]) app.setOrganizationDomain("qtrac.eu"); app.setApplicationName("DiffPDF"); app.setWindowIcon(QIcon(":/icon.png")); - QTextCodec::setCodecForTr(QTextCodec::codecForName("UTF-8")); QTextStream out(stdout); QStringList args = app.arguments().mid(1); --- diffpdf-2.1.3/mainwindow.hpp +++ diffpdf-2.1.3/mainwindow.hpp @@ -19,7 +19,7 @@ #else #include #endif -#include +#include #include #include #include --- diffpdf-2.1.3/optionsform.cpp +++ diffpdf-2.1.3/optionsform.cpp @@ -76,9 +76,9 @@ void OptionsForm::createWidgets() << qMakePair(tr("Diagonal \\"), Qt::FDiagPattern) << qMakePair(tr("Diagonal Cross"), Qt::DiagCrossPattern)) brushStyleComboBox->addItem(brushSwatch(pair.second, color), - pair.first, pair.second); + pair.first, static_cast(pair.second)); brushStyleComboBox->setCurrentIndex(brushStyleComboBox->findData( - brush.style())); + static_cast(brush.style()))); penStyleComboBox = new QComboBox; typedef QPair PenPair; @@ -90,9 +90,9 @@ void OptionsForm::createWidgets() << qMakePair(tr("Dash-Dotted"), Qt::DashDotLine) << qMakePair(tr("Dash-Dot-Dotted"), Qt::DashDotDotLine)) penStyleComboBox->addItem(penStyleSwatch(pair.second, color), - pair.first, pair.second); + pair.first, static_cast(pair.second)); penStyleComboBox->setCurrentIndex(penStyleComboBox->findData( - pen.style())); + static_cast(pen.style()))); alphaSpinBox = new QSpinBox; alphaSpinBox->setRange(1, 100);