I am new to PyQt4. My problem is when I use QWebView to display a pdf file it doesn't display - but no error or anything. I even added "file:///" to the file path and enabled the pdf viewer plugin. Has anyone here encountered this problem?
Here is my code:
import sys
from PyQt4.QtCore import *
from PyQt4.QtGui import *
from PyQt4.QtWebKit import *
app = QApplication(sys.argv)
web = QWebView()
web.settings().setAttribute(QWebSettings.PluginsEnabled, True)
web.show()
web.load(QUrl("sample.pdf")) # Change path to actual file.
sys.exit(app.exec_())