Is there a GUI IDE for programming Python just like Java has NetBeans?
I wanted one where we could drag & drop test boxes & labels just as we do with Swing components using NetBeans or Eclipse.
Or is there an add-on present in either NetBeans or Eclipse itself?
If you want a wysiwyg GUI designer, Glade is your best bet:
first, install glade
from the software centre
create your GUI, save it as, say, myapp.glade
Go to the signals tab and set up your callback, such as on_window1_destroy
In your python program, tell GTK to load the UI definitions
import gtk
class MyApp (object):
def __init__(self):
self.builder = gtk.Builder()
self.builder.add_from_file("myapp.glade")
self.builder.connect_signals(self)
def run(self):
self.builder.get_object("window1").show_all()
gtk.main()
def on_window1_destroy(self, *args):
gtk.main_quit()
MyApp().run()
After getting everything set up, you can dive straight into the Glade tutorial [2] (as Jeremy Kerr mentioned in his answer). Start by learning about the different lay–out options and signals.
When you feel comfortable with glade, you can start using it via Quickly, which is a set of programs to make the common tasks in developing software very easy. It takes care of translations, storing configuration, packaging, launchpad integration including PPAs, and lots more:
sudo apt-get install quickly
quickly create ubuntu-application hello-world
cd hello-world/
Quickly now creates a huge project with everything you need already set up. A gui, the translation files, configuration via desktopcouch [4], and so on.
You'll see quickly sets up a few windows (the main App, configuration, and an about dialogue) for you. To start editing your GUI:
quickly design
To get to the app's code, run quickly edit
Go to the HelloWorldWindow.py
file
Now start adding signal handlers and logic.
Finally, to run your application, type quickly run
.
At this point, you can get into the PyGTK documentation in order to learn about the signals, their handlers' signatures, the different widgets' methods and so on.
See also, some related questions:
PyQt [3] comes with Qt [4]'s Designer [5], which is a pretty neat graphical GUI editor, if you fancy to write your app with the Qt framework.
Qt's new IDE has full blown support both for desiging widgets (as designer above) and QtQuick applicaitons, which is better for lightweight, fluid, touch-enabled applications (i.e. tablet/mobile apps)
<![QtCreator IDE][5]>
<can't find qt-project.org/uploads/image_upload/creator_30_designer_mobile_app.png>
[1] https://packages.ubuntu.com/search?keywords=qt4-designerAre you after a full IDE (ie, code editor, runtime environment, UI layout tools), or just a utility to create the UI?
If it's a full programming environment you're after, have a look at the Quickly toolset [1].
If you're just looking to design interfaces, you can use the 'glade' designer to lay-out your interface using GTK widgets, then load that UI definition into any python program. There's a GTK+ and Glade3 GUI Programming Tutorial [2] (with both Python and C examples).
[1] https://wiki.ubuntu.com/QuicklyTry with Eric IDE. I think it's the best IDE both for Python and Qt4.
Eric is a full-featured Python IDE written in PyQt using the QScintilla editor widget.
Some highlights:
To install Eric IDE in all currently supported versions of Ubuntu open the terminal and type:
sudo apt install eric
It also depends which widget toolkit you want to use. I prefer wxWidgets [2] with python, wxPython [3].
So my preference for building the GUI's is wxFormBuilder [4], it is avaialable from following PPA:
It has the nice simple drag and drop of widgets onto a canvas, and you can quickly switch to the code tab to see what it has generated, which to my untutored eye is clean and uncluttered. As the name on the tin says it is a form builder, that's what it specializes in. So don't expect to develop a full project with it, however if you like to keep the form design separate to the analysis code then it does the job well.
[1] http://wxformbuilder.org/There is a new kid in town: Camelot [1]. It is designed to build GUI's really quickly. It helps you to focus on your application, rather than on GUI code. The maintainers say
Camelot provides components for building business applications on top of Python, SQLAlchemy and Qt. It is inspired by the Django admin interface. You can use Camelot to develop both simple and complex business applications at warp speed.
The framework has been presented several times in international python meetings. Its advantages are
Developer advantages
On top of high quality and proven technology
Views are bound to data model without writing code
Customizable through the Actions framework
Documented from introduction tutorial to report printing
Warpspeed to deployable solution
User advantages
Responsive and familiar GUI
High quality editors and controls
Tons of built in functions such as import, export, printing, backup and restore
Mapped to business processes
Check http://www.python-camelot.com/ for more info, presentations, youtube videos and more.
disclaimer: I have seen this in action and have talked with the developers. I might be biased, but I honestly believe this is great software.
[1] http://www.python-camelot.com/SharpDevelop
SharpDevelop is for developing application based on .Net Framework. It does support IronPython and has GUI designer for WinForm, Silverlight, WPF Application. While Visual Studio also has various GUI designer for IronPython, however it doesn't have GUI for WinForm.
no one has mentioned tool that has quite a lot of use in other languages, and could be be known by starting user - Eclipse has perspective for python called PyDev.
Check out PyForms, it is based on PyQt. It can be used with the Qt Designer but it is also quite easy to design GUIs directly in the Python script..
https://github.com/UmSenhorQualquer/pyforms/