Re: [PyQt] Construct QVariant from object of user type

2008-04-14 Thread Arve Knudsen
On 4/14/08, alteo_gange <[EMAIL PROTECTED]> wrote: > Le lundi 14 avril 2008, Arve Knudsen a écrit : > > > How do I construct a QVariant of an object of a non-Qt class? > > > Hi. > > >>> from PyQt4.QtCore import * > >>> from datetime import date > >>> a=date(1991,12,13) > >>> b=QVariant(a) > >>

Re: [PyQt] Re: Setting backgroud color to a QListViewItem

2008-04-14 Thread Hans-Peter Jansen
Am Montag, 14. April 2008 schrieb Christoph Burgmer: > > Someone can send example code to set background color to a > > QListViewItem (pyqt3)? > > defaultPalette = QtGui.QPalette(element) > newPalette = QtGui.QPalette(defaultPalette) > newPalette.setColor(QtGui.QPalette.Base, Qt.green) > element.se

[PyQt] Re: Setting backgroud color to a QListViewItem

2008-04-14 Thread Christoph Burgmer
> Someone can send example code to set background color to a > QListViewItem (pyqt3)? defaultPalette = QtGui.QPalette(element) newPalette = QtGui.QPalette(defaultPalette) newPalette.setColor(QtGui.QPalette.Base, Qt.green) element.setPalette(newPalette) This at least works for QLineEdit under KDE4

Re: [PyQt] Construct QVariant from object of user type

2008-04-14 Thread alteo_gange
Le lundi 14 avril 2008, Arve Knudsen a écrit : > How do I construct a QVariant of an object of a non-Qt class? Hi. >>> from PyQt4.QtCore import * >>> from datetime import date >>> a=date(1991,12,13) >>> b=QVariant(a) >>> print b.toDate().toPyDate() 1991-12-13 -- alteo_gange __

Re: [PyQt] Problem with QDataStream and QString

2008-04-14 Thread Phil Thompson
On Friday 11 April 2008, İsmail Dönmez wrote: > Hi again, > > Looks like I am back to QDataStream problems and here is the testcase : > >>> from PyQt4.QtCore import * > >>> a = QByteArray() > >>> b = QDataStream(a, QIODevice.ReadWrite) > >>> b << QString("123") > > > > >>> b.device().seek(0) > > T

[PyQt] Question about QCalendarWidget

2008-04-14 Thread Cesar Otero
Greetings to all: I've been having some problems with the QCalendarWidget, which is very nice, but seems to lack some documentation. I tried googling and looking through many mail lists, but still can't find the solution to my problem. I have the following code: ... dateStr = "20070101" # january

Re: [PyQt] Qt-support for sip

2008-04-14 Thread Wolfgang Junker
On Mon, 14 Apr 2008, Phil Thompson wrote: > On Monday 14 April 2008, Wolfgang Junker wrote: > > Hi everybody, > > > > I want to install python-2.3, sip-4.2, and PyQt-3.14 on my > > Redhat-Linux. When I configure sip via > > > > /usr/local/bin/python2.3 configure.py > > > > I get the message that "

[PyQt] KDE Plasmoids in Python

2008-04-14 Thread Sundance
Greetings, good folks of various sizes and shapes, Has anyone, and I'm especially turning to our fine PyKDE people here, successfully gotten a Python Plasmoid (applet, data engine, runner, whichever) to work in KDE 4, either 4.0 or in trunk? I have been looking into it and generally remained ba

Re: [PyQt] Regression in sip 4.7.4 "sip: QPixmap has not been defined"

2008-04-14 Thread Adam C Powell IV
On Sun, 2008-04-13 at 14:20 +0100, Phil Thompson wrote: > On Sunday 13 April 2008, Adam C Powell IV wrote: > > On Sun, 2008-04-06 at 20:14 -0400, Adam C Powell IV wrote: > > > On Mon, 2008-04-07 at 00:49 +0100, Phil Thompson wrote: > > > > I said before you should reproduce the problem with the sta

[PyQt] Construct QVariant from object of user type

2008-04-14 Thread Arve Knudsen
How do I construct a QVariant of an object of a non-Qt class? Thanks, Arve ___ PyQt mailing listPyQt@riverbankcomputing.com http://www.riverbankcomputing.com/mailman/listinfo/pyqt

Re: [PyQt] Qt-support for sip

2008-04-14 Thread Phil Thompson
On Monday 14 April 2008, Wolfgang Junker wrote: > Hi everybody, > > I want to install python-2.3, sip-4.2, and PyQt-3.14 on my > Redhat-Linux. When I configure sip via > > /usr/local/bin/python2.3 configure.py > > I get the message that "Qt support is disabled", although I have > Qt installed. And

[PyQt] Qt-support for sip

2008-04-14 Thread Wolfgang Junker
Hi everybody, I want to install python-2.3, sip-4.2, and PyQt-3.14 on my Redhat-Linux. When I configure sip via /usr/local/bin/python2.3 configure.py I get the message that "Qt support is disabled", although I have Qt installed. And then of course installing PyQt fails. I saw in the document