Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Language Bindings
  4. Visual Development of GUI possible with pyside
Forum Updated to NodeBB v4.3 + New Features

Visual Development of GUI possible with pyside

Scheduled Pinned Locked Moved Language Bindings
5 Posts 4 Posters 20.9k Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • T Offline
    T Offline
    tinjaw
    wrote on last edited by
    #1

    I would like to use Qt Creator to build my GUI and then pyside for coding.

    All the example I can find use QML, which I don't believe you can build WYSIWYG in Qt Creator.

    Is there a tutorial to WYSIWYG build a form and then code it up in python using pyside?

    Thanks

    1 Reply Last reply
    0
    • M Offline
      M Offline
      mairas
      wrote on last edited by
      #2

      I'm not sure whether tutorials for that currently exist (please create one if you have time and interest!), but creating the forms in Qt Creator is quite simple. Just design the form in Qt Creator (or Qt Designer, for that matter) and save the .ui file. Then, run pyside-uic:

      @
      pyside-uic -o ui_myform.py myform.ui
      @

      Then, you import the created python file, subclass it in your program, and be done with it. The whole process is pretty well detailed in Mark Summerfield's PyQt book, which is also applicable to PySide (with minor differences).

      However, it's also possible to design QML UIs in Qt Creator: the plugin just might not be enabled by default in older Qt Creator versions. For example, I just downloaded Qt Creator 2.0.1 to doublecheck these instructions, and there you need to enable the QML designer plugin at Help -> About Plugins (no, not the most obvious place in the world, I agree). After restarting, the "Design" button at the left toolbar is enabled and can be used to create QML UIs. These you can just save and use right away in your Python programs.

      Qt Creator (at least the recent versions) already has support for Python code highlighting, so it's also possible to edit Python code there directly. No support for Python projects exists at the moment, though.

      1 Reply Last reply
      0
      • E Offline
        E Offline
        ericparent
        wrote on last edited by
        #3

        Hi,

        I tried installing PySide on my machine (win7 64 bits, using Python 2.7 64 bits) and I got this message:

        @ > easy_install PySide

        ...
        
        error: Setup script exited with error: You need the program "nmake" on your system path to compile PySide.@
        

        What's that "nmake" program?

        1 Reply Last reply
        0
        • L Offline
          L Offline
          lndn
          wrote on last edited by
          #4

          Consistent with what @mairas says, there's a tutorial that shows you how to do this:

          Using QtCreator, PySide and PySide Tools
          You can also create the GUI in QtCreator and convert it to a python script. Follow this tutorial:
          http://qt-project.org/wiki/QtCreator_and_PySide

          1 Reply Last reply
          0
          • L Offline
            L Offline
            lndn
            wrote on last edited by
            #5

            @ericparent, your post seems to be unrelated to the OP's discussion, but have you tried to install the windows binaries?

            Go here and click on "Get PySide": http://qt-project.org/wiki/PySide

            1 Reply Last reply
            0

            • Login

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • Users
            • Groups
            • Search
            • Get Qt Extensions
            • Unsolved