-
-
Save arndo/c629eac09d7137e281ff to your computer and use it in GitHub Desktop.
diff -aur CutyCapt/CutyCapt.cpp CutyCapt.1/CutyCapt.cpp | |
--- CutyCapt/CutyCapt.cpp 2014-11-12 16:41:30.354714781 +0100 | |
+++ CutyCapt.1/CutyCapt.cpp 2014-11-12 16:41:30.354714781 +0100 | |
@@ -27,11 +27,7 @@ | |
#include <QtWebKit> | |
#include <QtGui> | |
#include <QSvgGenerator> | |
- | |
-#if QT_VERSION < 0x050000 | |
#include <QPrinter> | |
-#endif | |
- | |
#include <QTimer> | |
#include <QByteArray> | |
#include <QNetworkRequest> | |
diff -aur CutyCapt/CutyCapt.pro CutyCapt.1/CutyCapt.pro | |
--- CutyCapt/CutyCapt.pro 2014-11-12 16:31:34.476193204 +0100 | |
+++ CutyCapt.1/CutyCapt.pro 2014-11-12 16:41:30.354714781 +0100 | |
@@ -4,7 +4,7 @@ | |
CONFIG += qt console | |
greaterThan(QT_MAJOR_VERSION, 4): { | |
- QT += webkitwidgets | |
+ QT += webkitwidgets printsupport | |
} | |
contains(CONFIG, static): { |
Awesome! Thanks! :)
While the code did compile, I still got the first warning: CutyCapt.cpp:244:66: warning: unused parameter 'errors' [-Wunused-parameter] CutyCapt::handleSslErrors(QNetworkReply* reply, QList<QSslError> errors) {
This patch doesn't seem to address that one. I found another thread that suggested to add:
`#include
include `
to CutyCapt.hpp but mine already had those lines and still gives the error. If you are notified of this comment, please let me know if you have any ideas on this one. Thanks!
Can confirm this worked for me
wonderful! it work for me too. but let me explain details for beginner person like me to be more clear!
you should change two file: CutyCapt.pro and CutyCapt.cpp.
in CutyCapt.pro: change "QT += webkitwidgets" to "QT += webkitwidgets printsupport"
in CutyCapt.cpp: remove "#if QT_VERSION < 0x050000" and "#endif" from before and aftet of "#include "
and finally run "make" command.
Thank you for this, it works great!