daily pastebin goal
30%
SHARE
TWEET

Untitled

a guest Dec 9th, 2018 57 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. #include <QApplication>
  2. #include <QGraphicsWebView>
  3. #include <QGraphicsScene>
  4. #include <QGraphicsView>
  5. #include <QDebug>
  6.  
  7. int main(int argc, char *argv[])
  8. {
  9.     QApplication a(argc, argv);
  10.     QGraphicsScene graphicsScene;
  11.     QGraphicsView graphicsView(&graphicsScene);
  12.     QGraphicsWebView webView;
  13.     webView.load(QUrl("html5_test.html"));
  14.     graphicsScene.addItem(&webView);
  15.     graphicsView.setVerticalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
  16.     graphicsView.setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
  17.     graphicsView.resize(500,400);
  18.  
  19.     qDebug() << QTWEBKIT_VERSION_STR;
  20.     graphicsView.show();
  21.  
  22.     return a.exec();
  23. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top