Recommendations for Python GUI application [closed] - python

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
What are your recommendations for GUI libraries for Python. My own research has me looking at TKinter, but I am open to suggestions.
FYI, the Python application will serve as a kind of bridge between 2 applications. It will use the third party API to extract data, then move and rename the data into a canonical folder structure, use Robocopy to transfer the exported into our in-house processing environment and make proper entries into our in-house database.

Just googling "GUI libraries for Python" you can get "GUI Programming in Python":
https://wiki.python.org/moin/GuiProgramming
Due to this site -- Python has a huge number of GUI frameworks available for it, from TkInter to a number of other cross-platform solutions ... Please, have a look at them ... and find out a suitable tool :)

Have a look at this for a list of some GUI development platforms.
Tkinter
Standard builds of Python include an object-oriented interface to the Tcl/Tk widget set, called Tkinter. This is probably the easiest to install and use. For more info about Tk, including pointers to the source, see the Tcl/Tk home page at http://www.tcl.tk. Tcl/Tk is fully portable to the Mac OS X, Windows, and Unix platforms.
wxWidgets
wxWidgets (http://www.wxwidgets.org) is a free, portable GUI class library written in C++ that provides a native look and feel on a number of platforms, with Windows, Mac OS X, GTK, X11, all listed as current stable targets. Language bindings are available for a number of languages including Python, Perl, Ruby, etc.
wxPython (http://www.wxpython.org) is the Python binding for wxwidgets. While it often lags slightly behind the official wxWidgets releases, it also offers a number of features via pure Python extensions that are not available in other language bindings. There is an active wxPython user and developer community.
Both wxWidgets and wxPython are free, open source, software with permissive licences that allow their use in commercial products as well as in freeware or shareware.
Qt
There are bindings available for the Qt toolkit (using either PyQt or PySide) and for KDE (PyKDE). PyQt is currently more mature than PySide, but you must buy a PyQt license from Riverbank Computing if you want to write proprietary applications. PySide is free for all applications.
Qt 4.5 upwards is licensed under the LGPL license; also, commercial licenses are available from The Qt Company.
These three are probably the most common ones but you can try others if you wish.
Having only used Tkinter and PyQt I would recommend PyQt, however this may not be what you need so I recomend doing some research to find out which will best suit your needs.

Related

Python vs Iron Python [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 5 years ago.
Improve this question
I have to make a GUI for some testing teams. I have been asked to do it in Python, but when I Google, all I see is about Iron Python.
I also was asked not to use Visual Studio because it is too expensive for the company. So if you have any idea to avoid that I would be very happy.
I am still new to Python and programming overall so not any to advanced solutions.
If you have any questions just ask.
GUI PART: with would you use when using windows and mac(most windows) I would like some drag and drop so I don't waste to much time making the display part
Python is the name of a programming language, there are various implementations of it:
CPython: the standard Python interpreter, written in C
Jython: Python interpreter for Java
IronPython: Python interpreter for the .NET framework
PyPy: Python interpreter written in Python
All of them are free (in the sense of not having to buy a license to use them), and can be used to create GUI programs. It really depends what you want to do and which OS you use.
There are various GUI frameworks/bindings for Python: Tkinter, PyGtk, PyQt, WinForms/WPF (IronPython) and the Java UI frameworks.
You also don't have to use Visual Studio for compiling .NET languages, there are open source alternatives like MonoDevelop.
IronPython is a implementation of Python running on .NET - however it is not the implementation that is in general referred to when someone mentions Python - that would be cPython: Website for (normal) cPython.
Now as to creating a UI - there are many ways that you can use to create a UI in Python.
If you only want to use what is available in a normal installation you could use the TK bindings: TKInter. This wiki entry holds a wealth of information about getting started with TKInter.
Apart from TKInter there are bindings to many popular frameworks like QT, GTK and more (see here for a list).
If cost is your concern, you can use a free version of visual studio together with PTVS: https://pytools.codeplex.com/wikipage?title=PTVS%20Installation
If you're just trying to create a GUI that runs on Windows, C# on Visual Studio is the easiest way to go. Their free version, Community (used to be Express) provides all the Windows controls you're used to using with a drag and drop GUI builder.
All implementations can run on Eclipse via PyDev. So it kills the argument of which one to use as it is all the same language, implementations other than this instance are more domain specific. Iron Python targets Microsoft, Jython targets Java, Python targets itself. Each environment naturally has its own complier/library all you are doing is trading environments by choosing one over the other. Each has its positives and negatives but naturally you would want to give Python a try before touching other environments as a beginners rule.

Which console library to use in Python? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 6 years ago.
Improve this question
I have very simple task to accomplish in python. Need to draw textual data (Unicode) as rows on the screen, navigatable and user can select/deselect row. However, this should work on headless Linux, as well as Windows or Mac OS. Curses doesn't have Windows port. Console module from Fredrik Lundh works only on Windows. I could use both libraries and check OS, but then it takes double effort to make/maintain the same functionality on 2 different libraries.
I'm looking for simple multiplatform console library to draw what I've described.
At a lower level you will have to use curses and there are several choices for the underlying curses library on Windows which may or may not work. You won't have any real problems with curses on UNIX so if I were you, I would get it working on Windows first and if a particular feature doesn't work their, program around it. The UNIX port should be painless.
PDCurses for Windows is available as a DLL or source code and it is possible to interface directly to any DLL using the ctypes module. There is a tool which can automatically generate a ctypes wrapper for you called ctypesgen.py http://wavetossed.blogspot.com/2011/07/asynchronous-gnu-readline.html I'm not sure if that works for a Windows DLL quite so automatically, but it does work from header files so it is worth a try.
For more background on ctypes, have a look at some of the questions here like Scheduling function calls in a Python curses UI
I recently had a similar issue for a package I was putting together (https://github.com/peterbrittain/asciimatics). I wasn't very happy with the solutions that required you to install (or worse) build separate binary executables like PDCurses or cygwin, so I created a unified API that provides console colours, cursor positioning and keyboard input for Windows and UNIX platforms.
There is a gallery of sample applications here. In more recent releases, I have also added a set of widget objects to allow you to create TUIs like this:
This is now live and has been tested on CentOS 6/7 and Windows 7/8. You can install it from PYPI using pip and then use the Screen class to do exactly what you want. If not, please post an enhancement request on GitHub and I'll see what I can do.
I use urwid. It's documentation is poor, but on the other hand, its source base is very compact. It supports Unicode well and works fine on Cygwin. Doesn't seem work in native CMD.exe, but it's worth closer investigating seeing how the curses dependency is only optional.
Examples from the project site:
(source: urwid.org)

Is there a good IDE for building GUI apps with Python [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
I am a beginner programmer and have learned most of what I know thus far from using delphi for the past couple of months. A month or so back I decided to give python a try as I was told it may be easier to learn and I really like the language. I guess I just seem to pick things up easier using it.
The only problem is that I can't seem to find a good IDE for it that works in the way that Delphi does. I want to create desktop apps with nice GUIs so it would be nice to have something similar to Delphi/Visual studio to work with.
I have searched around and could find anything. Was wondering if anyone could lend a hand.
Also, from what I have gathered Ironpython seems to be the same as python coding wise. I don't mind my apps only being able to work on windows. Is Python Tools a good option. I mean is it basically like using visual studio but with python code instead?
Any help is much appreciated.
Thanks.
Boa Constructor is a classic RAD IDE for GUI applications (wxpython, both linux and windows). People is still using it but seems that development stopped some years ago. PythonCard is another RAD IDE I used in the past but also unmaintained right now
Although they are not IDEs, some tools are very helpful for GUI design like:
- wxglade (wxpython, included as a pluging in Stani Python Editor, only python2.x)
- qtdesigner (qt-pyqt or pyside, included in pyqt. Spyder IDE, build on pyqt, has a dedicated link to it. Works also for python 3.x)
I use PyGTK to interact with GTK.
http://www.pygtk.org/docs/pygtk/gtk-class-reference.html
http://www.pygtk.org/pygtk2tutorial/
But there is also QT, and WXpython, that are worthy.
http://thekompany.com/products/blackadder/
I always liked BoaConstructor which is a wxPython GUI Builder.
Doesn't seems to be actively maintained any longer though...
wxpython is very active though...
Python Tools is basically just like using VS but with Python. It's got intellisense, debugging, profiling, etc... When working w/ IronPython the .NET debugger is a little rough (you'll see internal implementation details) but you can still use the pure Python debugger which gives you a Pythonic view.
The intellisense engine is aware of the GUI designer so you'll get completions against the controls defined in XAML. And you'll get auto-definition of handler methods when you do things like double click on buttons in the GUI designer or select to define an event handler in the properties pane. Probably the biggest missing thing is that there's no support for user controls and there's also no designer support for WinForms.

Import a library that imports a GPL library? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about programming within the scope defined in the help center.
Closed 7 years ago.
Improve this question
So I am importing a library (reportlab), which is licensed BSD, but itself uses some libraries that are licensed GPL.
My question is, if I import reportlab into python - do I have to abide by BSD or GPL license?
IANAL. You have to abide by the licenses of all the packages you're using.
However, most would say if you only use the public API of those libraries, and they could theoretically be swapped out for other libraries implementing the same API, your code does not fall under the GPL, only any modifications you make to those libraries.
This is the point of view taken by the Linux kernel development community, for example.
Edit: After looking at the site of reportlab, it is clear that if you don't use the PyXML parser then you're only bound by the BSD license, as you're not using any GPL'd code.
Also, the question was raised in the comments whether your code is affected by the GPL if you don't distribute any GPL'd packages because the GPL primarily deals with modification of the code under the license and redistribution of that code. The answer is that if your code is a derivative work of the GPL'd code, you have to license your code under the GPL whether or not you're redistributing the original GPL'd code.
IANAL. From section 1.3 of the reportlab page here:reportlab licensing you can see they want you to talk to them about a commercial license.
GPL code when linked to BSD code requires you to license the BSD code under GPL - I'm talking static linking here. Dynamic linking to GPLed code is not allowed by non-GPL software - in fact, this is the reason for the existence of the LGPL license which allows dynamic linking from non-(L)GPL code. There is also an exception in the glibc license because they want you to be able to build commercial software with it.
The Linux Kernel developers do not all agree on all aspects of linking issues. If you're building against a standard API (POSIX) then it seems obvious you don't need to be GPL. But their arguments go deeper than that, so I don't think there is a direct comparison.
From the link above: "yRXP, our XML parser, is under the GNU General Public License. This is because the RXP parser underneath it is under this license. If you want to use pyRXP in a closed source project, you have to negotiate with us." This suggests they own pyRPX and can give or sell you a different license for it.
That's similar to the pyQT issue. You can make GPLed software with it, but for commercial stuff you need to pay up. Unless you want to make a commercial product that is GPLed of course.
IANAL either, but I think it doesn't even come into play as long as you are not going to distribute the other software as well. For example, if you just tell your users "you have to install pyRXP in order to use this" (maybe easier if you make that "reportlab"), I think the GPL does not apply to your own code.
EDIT: While there is no problem with using the reportlab toolkit in this particular case, the above interpretation does not seem to be correct (see agf's comments on this answer below, as well as his own answer)
Note that the reportlab toolkit (although it's by the same company "ReportLab") doesn't necessarily use pyRXP. They are two different things, each with it's own license.
Looking at reportlab's source code, in reportlab.lib.rparsexml, it seems that pyRXP is only imported if it is installed (separately, because it is not included), and it uses another xml parser if pyRXP is not available. (I guess this is their way of allowing pyRXP to be used, and still keeping reportlab under BSD license)
But maybe you'd best ask on the reportlab mailing list...

Nice IDE with GUI designer for wxPython or Tkinter [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Questions asking us to recommend or find a tool, library or favorite off-site resource are off-topic for Stack Overflow as they tend to attract opinionated answers and spam. Instead, describe the problem and what has been done so far to solve it.
Closed 9 years ago.
Improve this question
I have a little experience developing small command-line applications with Python. I want to move on to developing GUIs with Python. From the available GUI toolkits for Python, the ones I feel the most inclined to are wxPython and Tkinter; but I don't want to code all of the GUI by myself all of the time.
Are there any good GUI IDEs for any of these toolkits? It doesn't need to be free or open source.
I will talk only about WxPython because it's the only toolkit I have experience with. TkInter is nice to write small programs (then it doesn't require a GUI Designer), but is not really appropriate for large application development.
wxFormBuilder is really good: it generates .XRC files you need to load in your program, and it can generate .py files by subclassing them when you use.
DialogBlocks and wxDesigner are two commercial software which can generate Python code directly. I didn't tested these much because of their price.
wxGlade is (I think) not yet mature enough for large programs, but it's worth a try.
After trying all these, I realized they had all flaws and that nothing is better than just writing the GUI in an editor. The problem is the extended learning curve. But then you will be much more faster and your code will be much more flexible than when using a GUI designer.
Have a look at this list of major applications written with wxPython. You will probably see that none of these use a GUI Designer, there must be a reason for this.
You then understand gs is right when saying that either you switch to PyQt or you write your application by hand. I had a look at Qt Designer in the past and thought this was what I needed. Unfortunately PyQt has some license restrictions.
This may not answer your question directly, but I chose PyQt because there were no good UI designers for wxPython.
Apparently you either write your GUIs by hand or switch to PyQt.
Because Nokia and Riverbankcomputing couldn't agree on a LGPL solution, Nokia decided to build its own bindings: PySide.
Boa Constructor has a WxPython GUI builder.
I use xrced (comes with wxPython). The GUI is defined in xml files, you have an autogenerated python file that automates some initialization then you subclass those autogenerated classes and do the rest of the initialization by hand. I find that this is a good way to blend the elegance of hand-written GUI code with ease of GUI code generation.
For the code I use WingIDE, it's helpfull to have a good debuger and good source code completion when dealing with large libraries (or frameworks if you will) like wxPython.
If you want more automation (and so, uglier code) try the latest version of Boa, there are some nice introductory screencasts for it at ShowMeDo.com
I use Eclipse with PyDev as my Python IDE (Which is probably not the best solution out there, but it is quite decent)
For GUI developement, I have used wxGlade for a mid-sized project and found it to be quite easy to use one you've grasped the concepts of WxPython. The XML generation is very useful for separating actual GUI design from program logic.
All of the these are free.
Try VisualWx. I think the GUI designer is very good; however the IDE is fairly rudimentary (no code completion, debugging, etc.). My work pattern is to have VisualWx and a good editor like Komodo Edit/Netbeans/etc. open at the same time and switch between them as needed.
I've used wxGlade for a few mission-critical apps. If you're a little weak in wx, it can be rough, but once you get used to it, its a great tool.
Not really a GUI IDE but it leds you define Tkinter GUIs in a JSON file: https://github.com/tmetsch/pytkgen

Categories