[PyQt] QWebHistory load/save
phil at riverbankcomputing.com
Mon Mar 15 18:09:13 GMT 2010
On Mon, 15 Mar 2010 12:57:27 -0500, David Bronke <whitelynx at gmail.com>
> Well, according to the Qt docs, the << and >> operators for QWebHistory
> added in Qt 4.6, which would explain why it's just giving you
> under Qt 4.5.3... I'm not seeing that output here, though, and I'm still
> getting a zero-length file. (with your test script as well)
Which is what you would expect - you don't have an event loop running.
> On Mon, Mar 15, 2010 at 12:39, Russell Valentine
> <russ at coldstonelabs.org>wrote:
>> Looks like your on to something unless I did something wrong as well. I
>> wrote a little simple case. Using .__lshift__ instead of "<<" just made
>> not have an exception but it shows as "NotImplemented" in the console.
>> Qt: 4.5.3
>> PyQt4: 4.7
>> Python: 2.6.4
>> from PyQt4 import QtCore, QtGui, QtWebKit
>> import sys
>> app = QtGui.QApplication(sys.argv)
>> David Bronke wrote:
>>> Sorry, I spoke to soon. Using out.__lshift__(view.page().history())
>>> zero-length file. Attached is another somewhat minimal test case; it
>>> google, wikipedia, and CNN one after the other, and when CNN is loaded,
>>> saves the web view's history to a file and checks the file's length. On
>>> machine, this invariably comes out to 0 bytes.
>>> Qt version: 4.6.1
>>> PyQt4 version: 4.7.1-snapshot-20100120 (I couldn't get anything but the
>>> snapshot to install correctly)
>>> Python version: 2.6.4
>>> OS: Arch Linux
>>> Should I update to the latest snapshot and see if that fixes anything?
More information about the PyQt