PyQT installation /configuration

Discussion in 'Python' started by adrian_p_smith@yahoo.com, Jul 15, 2006.

  1. Guest

    Hi there. I've been trying to get PyQT working on W2K, but have not yet
    found a sufficiently detailed walk-through for my somewhat
    command-line-challenged sensibilities. I did find this page:
    http://www.diotavelli.net/PyQtWiki/GPLPyQtWindows , but I'm not sure
    about installing the whole of Visual Studio .NET as a prerequisite. Can
    anyone tell me if the passing of the years has made this process any
    more approachable?
     
    , Jul 15, 2006
    #1
    1. Advertising

  2. On Saturday 15 July 2006 9:25 am, wrote:
    > Hi there. I've been trying to get PyQT working on W2K, but have not yet
    > found a sufficiently detailed walk-through for my somewhat
    > command-line-challenged sensibilities. I did find this page:
    > http://www.diotavelli.net/PyQtWiki/GPLPyQtWindows , but I'm not sure
    > about installing the whole of Visual Studio .NET as a prerequisite. Can
    > anyone tell me if the passing of the years has made this process any
    > more approachable?


    For Qt4 use the binary installer from...

    http://www.trolltech.com/developer/downloads/qt/windows

    For PyQt4 use the binary installer from...

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

    Phil
     
    Phil Thompson, Jul 15, 2006
    #2
    1. Advertising

  3. Guest

    Phil Thompson wrote:
    > On Saturday 15 July 2006 9:25 am, wrote:
    > > Hi there. I've been trying to get PyQT working on W2K, but have not yet
    > > found a sufficiently detailed walk-through for my somewhat
    > > command-line-challenged sensibilities. I did find this page:
    > > http://www.diotavelli.net/PyQtWiki/GPLPyQtWindows , but I'm not sure
    > > about installing the whole of Visual Studio .NET as a prerequisite. Can
    > > anyone tell me if the passing of the years has made this process any
    > > more approachable?

    >
    > For Qt4 use the binary installer from...
    >
    > http://www.trolltech.com/developer/downloads/qt/windows
    >
    > For PyQt4 use the binary installer from...
    >
    > http://www.riverbankcomputing.co.uk/pyqt/download.php


    Ah thanks, I'm a dork. Why didn't I see that before <mutter>?
     
    , Jul 15, 2006
    #3
  4. Guest

    wrote:
    > Phil Thompson wrote:


    > > For Qt4 use the binary installer from...
    > >
    > > http://www.trolltech.com/developer/downloads/qt/windows
    > >
    > > For PyQt4 use the binary installer from...
    > >
    > > http://www.riverbankcomputing.co.uk/pyqt/download.php

    >
    > Ah thanks, I'm a dork. Why didn't I see that before <mutter>?


    Waitaminute, didn't you write it? Oh dear.

    I've got another problem, I'm afraid - I've installed Qt 4.1.4 and PyQt
    GPL v4.0 over Python 2.4, and the demos for both run happily enough,
    but when I try to run the first example (in IDLE) from Boudewijn
    Rempt's GUI Programming with Python: QT Edition I just get
    "ImportError: No module named qt". Is there something I need to add to
    my sys.path here?

    Sorry to bother you with the newbie questions.
     
    , Jul 16, 2006
    #4
  5. David Boddie Guest

    wrote:

    > I've got another problem, I'm afraid - I've installed Qt 4.1.4 and PyQt
    > GPL v4.0 over Python 2.4, and the demos for both run happily enough,
    > but when I try to run the first example (in IDLE) from Boudewijn
    > Rempt's GUI Programming with Python: QT Edition I just get
    > "ImportError: No module named qt". Is there something I need to add to
    > my sys.path here?


    The module structures for PyQt3 and PyQt4 are quite different: the
    monolithic qt module from PyQt3 has been replaced by a number of
    modules in PyQt4. Despite this, there is a similar way to "import qt"
    in PyQt4:

    from PyQt4 import Qt

    However, you will have difficulty using the examples in that book
    because it was written for PyQt3. Work is underway to "port" the book
    to PyQt4, but it will take some time. (You can help with this and learn
    about PyQt4 at the same time, if you want.)

    In the meantime, the set of slides from a talk at EuroPython 2006 is
    probably the only learning material on the web for PyQt4:

    http://indico.cern.ch/contributionDisplay.py?contribId=33&amp;sessionId=41&amp;confId=44

    There's plenty of learning material for Qt 4; the official
    documentation at http://doc.trolltech.com/4.1 contains examples
    and overviews that are readable if you already know C++. Those of us
    who use PyQt4 are still catching up!

    All the best,

    David
     
    David Boddie, Jul 16, 2006
    #5
  6. Guest

    David Boddie wrote:

    > The module structures for PyQt3 and PyQt4 are quite different: the
    > monolithic qt module from PyQt3 has been replaced by a number of
    > modules in PyQt4. Despite this, there is a similar way to "import qt"
    > in PyQt4:
    >
    > from PyQt4 import Qt
    >
    > However, you will have difficulty using the examples in that book
    > because it was written for PyQt3.


    Ah yes, it doesn't recognise "QApplication" now. Never mind.

    > Work is underway to "port" the book
    > to PyQt4, but it will take some time. (You can help with this and learn
    > about PyQt4 at the same time, if you want.)


    Er...you might be overestimating my potential unless there's some
    *really* entry-level material to be dealt with there. Though they do
    say it's a good way to learn. Is there a forum?

    > In the meantime, the set of slides from a talk at EuroPython 2006 is
    > probably the only learning material on the web for PyQt4:
    >
    > http://indico.cern.ch/contributionDisplay.py?contribId=33&amp;sessionId=41&amp;confId=44
    >
    > There's plenty of learning material for Qt 4; the official
    > documentation at http://doc.trolltech.com/4.1 contains examples
    > and overviews that are readable if you already know C++.


    One of the reasons I chose Python was so I wouldn't have to, alas.

    Thanks!
     
    , Jul 16, 2006
    #6
  7. On Sunday 16 July 2006 1:09 am, wrote:
    > wrote:
    > > Phil Thompson wrote:
    > > > For Qt4 use the binary installer from...
    > > >
    > > > http://www.trolltech.com/developer/downloads/qt/windows
    > > >
    > > > For PyQt4 use the binary installer from...
    > > >
    > > > http://www.riverbankcomputing.co.uk/pyqt/download.php

    > >
    > > Ah thanks, I'm a dork. Why didn't I see that before <mutter>?

    >
    > Waitaminute, didn't you write it? Oh dear.
    >
    > I've got another problem, I'm afraid - I've installed Qt 4.1.4 and PyQt
    > GPL v4.0 over Python 2.4, and the demos for both run happily enough,
    > but when I try to run the first example (in IDLE) from Boudewijn
    > Rempt's GUI Programming with Python: QT Edition I just get
    > "ImportError: No module named qt". Is there something I need to add to
    > my sys.path here?
    >
    > Sorry to bother you with the newbie questions.


    Boudewijn's book describes Qt/PyQt v3.

    Phil
     
    Phil Thompson, Jul 16, 2006
    #7
  8. David Boddie Guest

    wrote:
    > David Boddie wrote:
    >
    > > However, you will have difficulty using the examples in that book
    > > because it was written for PyQt3.

    >
    > Ah yes, it doesn't recognise "QApplication" now. Never mind.


    QApplication is still there. You can access it via the Qt module and
    create an application object in the following way:

    import sys
    from PyQt4 import Qt
    app = Qt.QApplication(sys.argv)

    > > Work is underway to "port" the book
    > > to PyQt4, but it will take some time. (You can help with this and learn
    > > about PyQt4 at the same time, if you want.)

    >
    > Er...you might be overestimating my potential unless there's some
    > *really* entry-level material to be dealt with there. Though they do
    > say it's a good way to learn. Is there a forum?


    Yes, it's at http://mats.imk.fraunhofer.de/mailman/listinfo/pykde

    > > There's plenty of learning material for Qt 4; the official
    > > documentation at http://doc.trolltech.com/4.1 contains examples
    > > and overviews that are readable if you already know C++.

    >
    > One of the reasons I chose Python was so I wouldn't have to, alas.


    Much of the example code for Qt is readable even if you only
    know Python. Some of the main differences between Qt and PyQt
    are described in this document:

    http://www.riverbankcomputing.com/Docs/PyQt4/pyqt4ref.html

    Good luck!

    David
     
    David Boddie, Jul 16, 2006
    #8
    1. Advertising

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

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Stelian Iancu

    PyQT installation problems

    Stelian Iancu, Aug 20, 2003, in forum: Python
    Replies:
    4
    Views:
    857
  2. ulysses
    Replies:
    4
    Views:
    784
    Werner Schiendl
    Oct 22, 2003
  3. =?UTF-8?B?0JTQsNC80ZjQsNC9INCT0LXQvtGA0LPQuNC10LLR

    PyQT, automatically creating GUI for configuration options

    =?UTF-8?B?0JTQsNC80ZjQsNC9INCT0LXQvtGA0LPQuNC10LLR, Jun 18, 2004, in forum: Python
    Replies:
    2
    Views:
    387
    David Fraser
    Jun 23, 2004
  4. Bulba!

    PyQt installation problem

    Bulba!, Dec 29, 2004, in forum: Python
    Replies:
    0
    Views:
    381
    Bulba!
    Dec 29, 2004
  5. Nanoscalesoft

    PyQT installation

    Nanoscalesoft, Dec 30, 2004, in forum: Python
    Replies:
    16
    Views:
    793
    Jarek Zgoda
    Jan 1, 2005
Loading...

Share This Page