Created
July 13, 2015 21:40
-
-
Save rodgomesc/2c6d85f85ac0cc28a3d5 to your computer and use it in GitHub Desktop.
Youtube_embed_PyQt.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from PyQt4.QtGui import QApplication | |
from PyQt4.QtCore import QUrl | |
from PyQt4.QtWebKit import QWebView | |
from PyQt4.QtCore import QString | |
import sys | |
__autor__= 'Rodrigo Gomes' | |
app = QApplication(sys.argv) | |
b = QWebView() | |
string = QString("""<!DOCTYPE html> | |
<html> | |
<body> | |
<iframe width="560" height="315" src="//www.youtube.com/embed/PLe1Buo9ERpeVkq-3aqxBSeriyV-didkwW" frameborder="0" allowfullscreen></iframe> | |
</body> | |
</html>""") | |
b.setHtml(string,QUrl('https://youtube.com')) | |
b.show() | |
app.exec_() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment