#endif
#include <QPrinter>
#include <QPrintDialog>
+#include <QWebInspector>
//#include "Viewer.mpp"
#define prefix_
#endif
connect(page(), SIGNAL(printRequested(QWebFrame*)), this, SLOT(printRequested()));
load(url);
+ inspector_ = new QWebInspector();
+ inspector_->setPage(page());
+}
+
+prefix_ pykit::Viewer::~Viewer()
+{
+ if (inspector_)
+ delete inspector_;
}
prefix_ void pykit::Viewer::printRequested()
//#include "Viewer.mpp"
///////////////////////////////hh.p////////////////////////////////////////
+class QWebInspector;
+
namespace pykit {
class Publisher;
Q_OBJECT;
public:
Viewer(QUrl const & url, Publisher * publisher, QWidget * parent = 0);
+ ~Viewer();
private slots:
void printRequested();
+
+ private:
+ QWebInspector * inspector_;
};
}
#include <QDir>
#include <QFileInfo>
#include <QFontDatabase>
+#include <QWebSettings>
#include <boost/scoped_ptr.hpp>
#include "MainWindow.hh"
#include "PythonPublisher.hh"
QString url (settings.value("home").toString());
if (arguments.size()>1)
url = arguments.at(1);
+
+ if (settings.value("debug").toBool())
+ QWebSettings::globalSettings()->setAttribute(
+ QWebSettings::DeveloperExtrasEnabled, true);
pykit::MainWindow window (QUrl(url), &publisher);
window.setWindowTitle(app.applicationName());
if (!iconPath.isEmpty())
organization=g0dil.de
[Viewer]
-init=init.py
home=http://pykit/
+debug=true
\ No newline at end of file