diff --git a/qelectrotech.exe.manifest b/qelectrotech.exe.manifest
deleted file mode 100644
index 7a2113ddf..000000000
--- a/qelectrotech.exe.manifest
+++ /dev/null
@@ -1,26 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
- true/pm
-
- permonitorv2,permonitor
-
- true
-
-
-
-
diff --git a/qelectrotech.pro b/qelectrotech.pro
index 9daae45a7..2f2afe9fa 100644
--- a/qelectrotech.pro
+++ b/qelectrotech.pro
@@ -31,7 +31,7 @@ win32 {
QET_LANG_PATH = 'lang/'
QET_LICENSE_PATH = './'
# Liste des ressources Windows
- RC_FILE = qelectrotech.rc
+ #RC_FILE = qelectrotech.rc
}
macx {
# Chemins MacOS X
diff --git a/qelectrotech.rc b/qelectrotech.rc
deleted file mode 100644
index b751f7e6b..000000000
--- a/qelectrotech.rc
+++ /dev/null
@@ -1,4 +0,0 @@
-#include
-
-ID_ICON1 ICON DISCARDABLE "ico/windows_icon/qelectrotech.ico"
-1 RT_MANIFEST "qelectrotech.exe.manifest"
diff --git a/sources/diagramprintdialog.cpp b/sources/diagramprintdialog.cpp
index fa74a4b94..18c04f51e 100644
--- a/sources/diagramprintdialog.cpp
+++ b/sources/diagramprintdialog.cpp
@@ -354,7 +354,25 @@ void DiagramPrintDialog::browseFilePrintTypeDialog() {
*/
void DiagramPrintDialog::print(const QList &diagrams, bool fit_page, const ExportProperties options) {
//qDebug() << "Demande d'impression de " << diagrams.count() << "schemas.";
-
+#if QT_VERSION >= QT_VERSION_CHECK(5, 0, 0)
+ #ifdef Q_OS_WIN
+ #ifdef QT_DEBUG
+ qDebug() << "--";
+ qDebug() << "DiagramPrintDialog::print printer_->resolution() before " << printer_->resolution();
+ qDebug() << "DiagramPrintDialog::print screennumber " << QApplication::desktop()->screenNumber();
+ #endif
+
+ QScreen *srn = QApplication::screens().at(QApplication::desktop()->screenNumber());
+ qreal dotsPerInch = (qreal)srn->logicalDotsPerInch();
+ printer_->setResolution(dotsPerInch);
+
+ #ifdef QT_DEBUG
+ qDebug() << "DiagramPrintDialog::print dotsPerInch " << dotsPerInch;
+ qDebug() << "DiagramPrintDialog::print printer_->resolution() after" << printer_->resolution();
+ qDebug() << "--";
+ #endif
+ #endif
+#endif
// QPainter utiliser pour effectuer le rendu
QPainter qp(printer_);
diff --git a/sources/main.cpp b/sources/main.cpp
index c240af60a..868c225f7 100644
--- a/sources/main.cpp
+++ b/sources/main.cpp
@@ -32,14 +32,10 @@ int main(int argc, char **argv)
QCoreApplication::setApplicationName("QElectroTech");
//Creation and execution of the application
//HighDPI
-#if QT_VERSION >= QT_VERSION_CHECK (5, 6, 0)
-#if defined Q_OS_MAC
- QApplication::setAttribute (Qt::AA_EnableHighDpiScaling);
-#elif !defined(Q_OS_MAC)
- QApplication::setAttribute (Qt::AA_DisableHighDpiScaling);
+#if QT_VERSION >= QT_VERSION_CHECK(5, 6, 0)
+ QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
#else
- qputenv("QT_DEVICE_PIXEL_RATIO", QByteArray("1"));
-#endif
+ qputenv("QT_DEVICE_PIXEL_RATIO", QByteArray("auto"));
#endif
return(QETApp(argc, argv).exec());
}