PyQt Help and Advice

I

Ilya Knizhnik

Dear All,

I am fairly new to Python. I have found it an easy language to learn and
a very usefull one for many tasks. Currently I am working on a python
project that involves a GUI and it was suggested that PyQt is the best way to
design that GUI.
However since PyQt is rather new, I have not found much documentation on
it, or examples in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for someone
with almost no GUI experience.
Does anyone have any suggestions?

Ilya
 
S

Sybren Stuvel

Ilya Knizhnik enlightened us with:
However since PyQt is rather new, I have not found much
documentation on it, or examples in it. The only useful
tutorial/book I have found is at www.opendocspublishing.com/pyqt/
but it is not always clear for someone with almost no GUI
experience.

You might want to follow the QT tutorials that come with the QT
documentation. The best way to read the QT docs is through QT
Assistant. You can design GUIs with QT's 'designer' (it's called that
way, very original name) and convert the .ui files to .py files with
'pyuic'.

Sybren
 
K

Keith Jones

However since PyQt is rather new, I have not found much documentation on
it, or examples in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for someone
with almost no GUI experience.
Does anyone have any suggestions?

Ilya

If you're at all familiar with C++, or even if you're not, you'll find
Qt's API docs, http://doc.trolltech.com/3.0/ , very handy. I've found that
pyQt correlates almost exactly with them, except for some str QString
conversion issues. I refer to that all the time when I'm doing PyQt code.
Also, I don't know what OS or distro you're on, but there is a set of pyqt
examples out there. In redhat, I used the PyQt-examples rpm (case
sensitive), which installs a bunch of example programs to
/usr/share/doc/PyQt-examples-[version]. Also. as Sybren mentioned, the Qt
tutorial itself should be useful.. Finally, I'll say that the book you
mentioned is excellent, and a wonder source of example code. I liked it
enough that I bought it, and I'm happy I did.

Good luck with PyQt! The only issues I've had were related to QCanvas not
deleting canvas items (and therefore my program leaking them) if I don't
reuse them. I still haven't figured that out, so I just keep track of the
ones I create and reuse them, in order to prevent memory leaks.

Keith
 
B

Bruce Sass

I am fairly new to Python. I have found it an easy language to
learn and a very usefull one for many tasks. Currently I am working
on a python project that involves a GUI and it was suggested that
PyQt is the best way to design that GUI. However since PyQt is
rather new, I have not found much documentation on it, or examples
in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for
someone with almost no GUI experience. Does anyone have any
suggestions?

http://www.riverbankcomputing.co.uk/pyqt/index.php

Is a good starting point. Subscribe to the mailing list.
 
S

Sybren Stuvel

Keith Jones enlightened us with:
I've found that pyQt correlates almost exactly with them, except for
some str QString conversion issues.

Another thing to be wary about, is that "exec" is a reserved keyword
in Python. QDialog boxes, QApplication and perhaps some others that
have an exec() method in C++ are called exec_loop() in Python. Took me
a little while to figure out ;-)

Sybren
 
J

John J. Lee

However since PyQt is rather new, I have not found much documentation on
it, or examples in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for someone
with almost no GUI experience.
Does anyone have any suggestions?

PyQt isn't new. The reason there's not documentation for every API
function is that the Python interface slavishly follows the C++ API
(actually, I believe you can now pay for documentation, but I don't
see the point). The PyQt docs just list the slight deviations from Qt
proper. The Qt docs are excellent, and you really don't need to know
C++ to understand them.


John
 
P

Phil Thompson

Dear All,

I am fairly new to Python. I have found it an easy language to learn and
a very usefull one for many tasks. Currently I am working on a python
project that involves a GUI and it was suggested that PyQt is the best way
to design that GUI.
However since PyQt is rather new, I have not found much documentation on
it, or examples in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for someone
with almost no GUI experience.
Does anyone have any suggestions?

Ilya

To correct one misconception...

PyQt was first released on November 1st 1998. There have been 34 releases in
all. The next release, including support for Qt v3.2.0, will be around August
12th. It isn't new.

Phil
 
K

Keith Jones

To correct one misconception...

PyQt was first released on November 1st 1998. There have been 34 releases in
all. The next release, including support for Qt v3.2.0, will be around August
12th. It isn't new.

Phil


Phil,

Any idea when Qt3.2 will have noncommercial support in windows?
 
S

Shawn Gordon

Dear All,

I am fairly new to Python. I have found it an easy language to learn and
a very usefull one for many tasks. Currently I am working on a python
project that involves a GUI and it was suggested that PyQt is the best way to
design that GUI.
However since PyQt is rather new, I have not found much documentation on
it, or examples in it. The only useful tutorial/book I have found is at
www.opendocspublishing.com/pyqt/ but it is not always clear for someone
with almost no GUI experience.
Does anyone have any suggestions?

Ilya

We have a product called PyQtDoc that provides a very nice and
convenient interface for all the PyQt information. You can see
information on it at http://www.thekompany.com/products/pyqtdoc/

Best,
Shawn
 
S

Sybren Stuvel

Keith Jones enlightened us with:
Any idea when Qt3.2 will have noncommercial support in windows?

Probably when Qt 4.x has been released. If you want to stay current
and free, try Linux instead.

Sybren
 
P

Phil Thompson

Phil,

Any idea when Qt3.2 will have noncommercial support in windows?

That's a question for Trolltech. I would certainly expect Qt v4 to be released
first.

Phil
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,769
Messages
2,569,581
Members
45,057
Latest member
KetoBeezACVGummies

Latest Threads

Top