[PyKDE] QStringList

Phil Thompson phil at river-bank.demon.co.uk
Mon Apr 3 14:19:35 BST 2000

Pete Ware wrote:
> PyQt-0.11.
> I wanted to use qt.QTextBrowser and setup a Mime source using
>         qt.QMimeSourceFactory.defaultFactory().setFilePath ('some path')
> Unfortunately, setFilePath() expects a QStringList (I expected a list
> of strings).  Unfortunately, PyQt's QStringList doesn't have anyway of
> adding more than the initial string specified in the constructor
> (i.e. it needs to add the QValueList append() method).

I didn't implement append() (and prepend()) because they return an
iterator.  However, return values are easy enough to ignore.  Try

	void append(const QString &)
	void prepend(const QString &)

...to qstringlist.sip and re-generate the code.


More information about the PyQt mailing list