Member Avatar
Reusable Code Snippet Explore Pyside's QWebView

The Pyside GUI toolkit (public PyQt) lets you bring up an interactive web page with its QWebView widget. Here is a simple example.

+2 forum 0
Member Avatar

PySide's QWebView can load a given url and display the web page associated with it with just a few lines of code.

+1 forum 0
Member Avatar

[CODE=c++] #include <QtGui> class MaskedLabel : public QLabel { protected: void resizeEvent(QResizeEvent* event) { QLabel::resizeEvent(event); QPixmap pixmap(size()); pixmap.fill(Qt::transparent); QPainter::setRedirected(this, &pixmap); QPaintEvent pe(rect()); paintEvent(&pe); QPainter::restoreRedirected(this); setMask(pixmap.mask()); } }; int main(int argc, char* argv[]) { QApplication a(argc, argv); QLabel* label = new MaskedLabel(); label->setText("Qt Centre!"); QFont font = label->font(); font.setPointSize(72); label->setFont(font); label->show(); return a.exec(); } [/CODE] Hi, I tired this approach to create Picture In Picture(PIP) window on QWebView widget. And my goal is to create hole on QwebView so that video playing in the background is visible through PIP window. When I first create this Masked Label its showing me the …

+0 forum 0

The End.