Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. The Lounge
  3. Any Python Devs? What UI?

Any Python Devs? What UI?

Scheduled Pinned Locked Moved The Lounge
questionpythondesignhtml
23 Posts 13 Posters 1 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.
  • R raddevus

    This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

    A Offline
    A Offline
    Asday
    wrote on last edited by
    #4

    wxPython, with the added help of wxFormBuilder, (because writing interface code/data by hand is hell).

    R 1 Reply Last reply
    0
    • R raddevus

      This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

      D Offline
      D Offline
      Davyd McColl
      wrote on last edited by
      #5

      Haven't done Python UI stuff in a while, but when I did -- PyQt (I used 4, but I believe there's a 5 variant now). I really found it to be quite rewarding. IIRC you can code by hand (which I preferred) or use QtDesigner to code UIs WYSIWIG style and use them in Python. PyQt is cross-platform and, I found, looks better than wxPython, which I also found to be way more difficult and restraining, since it tries to fit a generic paradigm to GTK on linux, Windows native UI and Darwin native UI. Qt has the freedom to provide a unified way to work on things and stuff actually works -- then the output is styled by default to feel native on the hosting platform.

      ------------------------------------------------ If you say that getting the money is the most important thing You will spend your life completely wasting your time You will be doing things you don't like doing In order to go on living That is, to go on doing things you don't like doing Which is stupid. - Alan Watts https://www.youtube.com/watch?v=-gXTZM\_uPMY

      P R A 3 Replies Last reply
      0
      • D Davyd McColl

        Haven't done Python UI stuff in a while, but when I did -- PyQt (I used 4, but I believe there's a 5 variant now). I really found it to be quite rewarding. IIRC you can code by hand (which I preferred) or use QtDesigner to code UIs WYSIWIG style and use them in Python. PyQt is cross-platform and, I found, looks better than wxPython, which I also found to be way more difficult and restraining, since it tries to fit a generic paradigm to GTK on linux, Windows native UI and Darwin native UI. Qt has the freedom to provide a unified way to work on things and stuff actually works -- then the output is styled by default to feel native on the hosting platform.

        ------------------------------------------------ If you say that getting the money is the most important thing You will spend your life completely wasting your time You will be doing things you don't like doing In order to go on living That is, to go on doing things you don't like doing Which is stupid. - Alan Watts https://www.youtube.com/watch?v=-gXTZM\_uPMY

        P Offline
        P Offline
        peterkmx
        wrote on last edited by
        #6

        PyQt sounds interesting ... I am trying to learn Python in my spare time (if any left ...), and indeed, Python GUI dev is not obvious when looking from C#/WinForm or C++/MFC perspective. I will give PyQt (with PyCharm) a try ... Thanks for the suggestion,

        1 Reply Last reply
        0
        • R raddevus

          This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

          E Offline
          E Offline
          Ed Korsberg
          wrote on last edited by
          #7

          I have not used in recently but once had to make a GUI and found that easygui, https://pypi.org/project/easygui/ was in fact quite easy to use. The GUI choices are basic but functional

          R 1 Reply Last reply
          0
          • G Garth J Lancaster

            raddevus wrote:

            Maybe desktop apps are just out for Python???

            That's what I like to think - I've yet to see a decent Python UI maybe you go IronPython if that's what you need

            R Offline
            R Offline
            raddevus
            wrote on last edited by
            #8

            Thanks for the input. It does seem as if there isn't a great way to build a UI that python uses.

            1 Reply Last reply
            0
            • A AETaylor

              I don't do much Python myself, but some of the guys where I work have achieved decent results with [^]Kivy

              R Offline
              R Offline
              raddevus
              wrote on last edited by
              #9

              Thanks I'll check it out.

              1 Reply Last reply
              0
              • A Asday

                wxPython, with the added help of wxFormBuilder, (because writing interface code/data by hand is hell).

                R Offline
                R Offline
                raddevus
                wrote on last edited by
                #10

                Asday wrote:

                wxPython, with the added help of wxFormBuilder

                Searched on this and I see that it says this is "bundled" with python and it is an alternative to tkinter. Thanks. Basically what I'm learning is there isn't a great way to add a GUI on top of python. But also understand Python may be used for other types of things too.

                A 1 Reply Last reply
                0
                • D Davyd McColl

                  Haven't done Python UI stuff in a while, but when I did -- PyQt (I used 4, but I believe there's a 5 variant now). I really found it to be quite rewarding. IIRC you can code by hand (which I preferred) or use QtDesigner to code UIs WYSIWIG style and use them in Python. PyQt is cross-platform and, I found, looks better than wxPython, which I also found to be way more difficult and restraining, since it tries to fit a generic paradigm to GTK on linux, Windows native UI and Darwin native UI. Qt has the freedom to provide a unified way to work on things and stuff actually works -- then the output is styled by default to feel native on the hosting platform.

                  ------------------------------------------------ If you say that getting the money is the most important thing You will spend your life completely wasting your time You will be doing things you don't like doing In order to go on living That is, to go on doing things you don't like doing Which is stupid. - Alan Watts https://www.youtube.com/watch?v=-gXTZM\_uPMY

                  R Offline
                  R Offline
                  raddevus
                  wrote on last edited by
                  #11

                  Davyd McColl wrote:

                  PyQt (I used 4, but I believe there's a 5 variant now)

                  Thanks for the info. I will check it out.

                  1 Reply Last reply
                  0
                  • E Ed Korsberg

                    I have not used in recently but once had to make a GUI and found that easygui, https://pypi.org/project/easygui/ was in fact quite easy to use. The GUI choices are basic but functional

                    R Offline
                    R Offline
                    raddevus
                    wrote on last edited by
                    #12

                    I will take a look at it. Thanks for the info.

                    1 Reply Last reply
                    0
                    • R raddevus

                      This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

                      P Offline
                      P Offline
                      Peter R Fletcher
                      wrote on last edited by
                      #13

                      Flask is another web-based approach to providing a GUI for Python scripts, which seems to have a somewhat less steep learning curve than Django. It is easier to learn what you need to know for a particular project and progressively build on this.

                      1 Reply Last reply
                      0
                      • R raddevus

                        This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

                        U Offline
                        U Offline
                        User 10655931
                        wrote on last edited by
                        #14

                        PyQT

                        M 1 Reply Last reply
                        0
                        • R raddevus

                          This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

                          D Offline
                          D Offline
                          dseverns5
                          wrote on last edited by
                          #15

                          If you want a Microsoft Windows interface, which is still 85% of business desktops, that will run whether your programs are running on Linux or a Windows box that can interface with anything which Windows can interface, like ActiveX controls, .NET controls, I use a software tool called SP2 from Flexus International. It is written in C and I use it with current C development and past development with Cobol. It is not open source so there is a cost, but it is worth it and a great product. SP2 is royalty free. I plan to embed Python in my current C application and while I haven't done it yet, I think Python, which is also written in C, should be relatively easy to interface with the SP2 API. I have interfaced SP2 with a Business Basic app, and Python should be much easier. I have used the Flexus products (flexus.com) since mid-90s and they are top drawer. I have used the Flexus products with various flavors of AIX, Unix, Linux and all Windows versions. If you run your apps on AIX/Unix/Linux you do so using windows clients and all displays, mouse and key clicks go to the windows client via software Thin Client. Flexus also has a product called Web Client X that renders the Windows screens into HTML/CSS/Javascript/Ajax for a complete browser interface with very little code change. SP2 and WC/X are lightning fast and of course will run on any platform with a browser. If anyone is interested, I will be glad to share my Python/SP2 interface with them when I finish it.

                          R 1 Reply Last reply
                          0
                          • D dseverns5

                            If you want a Microsoft Windows interface, which is still 85% of business desktops, that will run whether your programs are running on Linux or a Windows box that can interface with anything which Windows can interface, like ActiveX controls, .NET controls, I use a software tool called SP2 from Flexus International. It is written in C and I use it with current C development and past development with Cobol. It is not open source so there is a cost, but it is worth it and a great product. SP2 is royalty free. I plan to embed Python in my current C application and while I haven't done it yet, I think Python, which is also written in C, should be relatively easy to interface with the SP2 API. I have interfaced SP2 with a Business Basic app, and Python should be much easier. I have used the Flexus products (flexus.com) since mid-90s and they are top drawer. I have used the Flexus products with various flavors of AIX, Unix, Linux and all Windows versions. If you run your apps on AIX/Unix/Linux you do so using windows clients and all displays, mouse and key clicks go to the windows client via software Thin Client. Flexus also has a product called Web Client X that renders the Windows screens into HTML/CSS/Javascript/Ajax for a complete browser interface with very little code change. SP2 and WC/X are lightning fast and of course will run on any platform with a browser. If anyone is interested, I will be glad to share my Python/SP2 interface with them when I finish it.

                            R Offline
                            R Offline
                            raddevus
                            wrote on last edited by
                            #16

                            Sounds very interesting. Thanks for the details.

                            1 Reply Last reply
                            0
                            • R raddevus

                              Asday wrote:

                              wxPython, with the added help of wxFormBuilder

                              Searched on this and I see that it says this is "bundled" with python and it is an alternative to tkinter. Thanks. Basically what I'm learning is there isn't a great way to add a GUI on top of python. But also understand Python may be used for other types of things too.

                              A Offline
                              A Offline
                              Asday
                              wrote on last edited by
                              #17

                              I don't think wxPython is part of the stdlib at all, is it? That's news to me. I also don't particularly agree with you that there "isn't a great way to add a GUI on top of Python". When you use Visual Studio to make a XAML or WinForms interface, the code that gets written by that is still really mealy awful code, but because the tool writes it for you, you don't notice as much. It's the same with wxFormBuilder, it just happens to be third party. I understand you can do similar with Glade and GTK.

                              R 1 Reply Last reply
                              0
                              • D Davyd McColl

                                Haven't done Python UI stuff in a while, but when I did -- PyQt (I used 4, but I believe there's a 5 variant now). I really found it to be quite rewarding. IIRC you can code by hand (which I preferred) or use QtDesigner to code UIs WYSIWIG style and use them in Python. PyQt is cross-platform and, I found, looks better than wxPython, which I also found to be way more difficult and restraining, since it tries to fit a generic paradigm to GTK on linux, Windows native UI and Darwin native UI. Qt has the freedom to provide a unified way to work on things and stuff actually works -- then the output is styled by default to feel native on the hosting platform.

                                ------------------------------------------------ If you say that getting the money is the most important thing You will spend your life completely wasting your time You will be doing things you don't like doing In order to go on living That is, to go on doing things you don't like doing Which is stupid. - Alan Watts https://www.youtube.com/watch?v=-gXTZM\_uPMY

                                A Offline
                                A Offline
                                Asday
                                wrote on last edited by
                                #18

                                I actually quite like wx's native widget implementation - it buys you the learnt familiarity with the conventions of the platform your user uses, for free.

                                1 Reply Last reply
                                0
                                • A Asday

                                  I don't think wxPython is part of the stdlib at all, is it? That's news to me. I also don't particularly agree with you that there "isn't a great way to add a GUI on top of Python". When you use Visual Studio to make a XAML or WinForms interface, the code that gets written by that is still really mealy awful code, but because the tool writes it for you, you don't notice as much. It's the same with wxFormBuilder, it just happens to be third party. I understand you can do similar with Glade and GTK.

                                  R Offline
                                  R Offline
                                  raddevus
                                  wrote on last edited by
                                  #19

                                  Asday wrote:

                                  I don't think wxPython is part of the stdlib at all, is it? That's news to me.

                                  I believe you are correct. However, it was quite easy to get it installed in my Anaconda environment.

                                  conda install -c conda-forge wxpython

                                  After that there is a very simple example that worked great.

                                  # First things, first. Import the wxPython package.
                                  import wx

                                  Next, create an application object.

                                  app = wx.App()

                                  Then a frame.

                                  frm = wx.Frame(None, title="Hello World")

                                  Show it.

                                  frm.Show()

                                  Start the event loop.

                                  app.MainLoop()

                                  Worked great! wxPython, for the win! :)

                                  A 1 Reply Last reply
                                  0
                                  • R raddevus

                                    Asday wrote:

                                    I don't think wxPython is part of the stdlib at all, is it? That's news to me.

                                    I believe you are correct. However, it was quite easy to get it installed in my Anaconda environment.

                                    conda install -c conda-forge wxpython

                                    After that there is a very simple example that worked great.

                                    # First things, first. Import the wxPython package.
                                    import wx

                                    Next, create an application object.

                                    app = wx.App()

                                    Then a frame.

                                    frm = wx.Frame(None, title="Hello World")

                                    Show it.

                                    frm.Show()

                                    Start the event loop.

                                    app.MainLoop()

                                    Worked great! wxPython, for the win! :)

                                    A Offline
                                    A Offline
                                    Asday
                                    wrote on last edited by
                                    #20

                                    Indeed. You'll wanna make sure you've got phoenix (wxPython version >=4) installed, and definitely for sure use wxFormBuilder instead of writing your interfaces by hand.

                                    1 Reply Last reply
                                    0
                                    • U User 10655931

                                      PyQT

                                      M Offline
                                      M Offline
                                      Member 13584377
                                      wrote on last edited by
                                      #21

                                      kivy works for me - good results on windows & android

                                      1 Reply Last reply
                                      0
                                      • R raddevus

                                        This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

                                        B Offline
                                        B Offline
                                        B Alex Robinson
                                        wrote on last edited by
                                        #22

                                        Over the last 15 or 20 years, I've used wxPython and web-browser UI. Alternatives haven't filled the bill for one reason or another. Question: How have I chosen between wx and browser? Answer: Which was used for the most recent project? Use the other. Seriously, the grass has been oddly greener over several cycles. So, apparently, my next project will be browser-based. Because the last one was wx. Note: I've wanted to use Tkinter because it comes with Python. But, jeez. Have you experienced its out-of-box?

                                        1 Reply Last reply
                                        0
                                        • R raddevus

                                          This really is more of a poll and not a technical question. I'm wondering what is _really_ used to build the User Interface for python programs? I know there is Django (web-based python that would use HTML), but what about desktop apps? Is it still 95% Tkinter? Just curious what you Professional Python Devs are using. EDIT Secondary: Maybe desktop apps are just out for Python??? In that case, is that the answer...Most Python is just used for command-line scripting type of apps, data-type apps that work on data with no graphical output?

                                          U Offline
                                          U Offline
                                          User 8058264
                                          wrote on last edited by
                                          #23

                                          We build GUIs for Desktop in Python all the time in the visual effects industry, using Qt as the main library. While Qt is primarily C++, there are full python bindings (official as well) that you can use to create your interfaces without ever leaving Python.

                                          1 Reply Last reply
                                          0
                                          Reply
                                          • Reply as topic
                                          Log in to reply
                                          • Oldest to Newest
                                          • Newest to Oldest
                                          • Most Votes


                                          • Login

                                          • Don't have an account? Register

                                          • Login or register to search.
                                          • First post
                                            Last post
                                          0
                                          • Categories
                                          • Recent
                                          • Tags
                                          • Popular
                                          • World
                                          • Users
                                          • Groups