[PyQt] python vs qt4 datatypes

Andreas Pakulat apaku at gmx.de
Thu Jun 25 07:51:23 BST 2009


On 24.06.09 22:20:31, Mario Daniel Carugno wrote:
> Hi there
> I'm starting with a pyqt development, a database application (what original).
> I can't decide which datatypes and sql library to use. I mean, is it
> better to use
> python datatypes (str, int, bool) or qt4 datatypes (qstring, ...) ?
> If i use python datatypes, using pyqt4-sql to access data seems to bring a lot
> of datatype convertions, thus in that case i could choose mysqldb, which uses
> python datatypes.
> Is that approach better than use all from PyQT ?
> I feel that python datatypes has more and better methods and functions, and
> that processing data in native types is always better.

If you still use PyQt then for the GUI, you're again facing conversion of
all your data. More importantly you won't be able to use the existing
model/view classes to show your data, but you'll have to write a custom
model yourself.

Andreas

-- 
Your nature demands love and your happiness depends on it.


More information about the PyQt mailing list