10

As I understand it, Qt - C++ and QML - or HTML5 are recommended for writing Ubuntu for Phones applications.

Also, correct me if I'm wrong, but Python is the preferred language for Ubuntu Desktop. Does this mean Python 3?

However, I can't find any documentation stating what widget toolkit, GTK+ or Qt, is preferred. Additionally, what version/generation of these is recommended? I don't know anything about recent Qt versions, but I know that GTK+2 and GTK+3 are distinct and different to code for. Am I to assume that if the preferred toolkit is GTK+, we're talking about GTK+3?

This page states that PyGTK is recommended. However, I can't tell what exactly this entails - does it mean that Python is recommended, GTK+ is recommended, or both, using PyGTK for GTK+ bindings?

1
  • 3
    I personally feel that answers to this question should mention their sources.
    – don.joey
    Apr 5, 2013 at 14:35

4 Answers 4

7
+50

The future: Nothing has officially been declared. However, Canonical is pursuing a convergent strategy for its Ubuntu OS. This suggests that in the future its SDK which uses the QML language (javascript like) and Qt toolkit will end up being the preferred choices for multiplatform development. The SDK should allow one application to scale to many form factors. It's also significant to note that Mir, the new compositing window manager they are developing will have Qt bindings by default.

Currently: As things currently stand, development on the desktop is supported by almost any language and toolkit you'd like. However, Canonical recommends GTK+ 3.0 and python2.7 for beginners (despite old docs saying pygtk, it's really pygi - also known as python with gobject introspection). The default python in Ubuntu is 2.7 not 3.0. They have created a tool for developers called "quickly" that allows you to easily design, code, package and distribute your app. By default apps depend on pygi (GTK3) and the user interface is designed with Glade.

One thing you might notice with GTK3 and pyGI is that there aren't a lot of good documentation for it yet. Here is a palce to get started, but it's missing a lot of stuff. I find that I can translate many of the C++ Gtk docs and the seed docs into the appropriate functions in python by some experimentation. Often if I can find out how to do it with the old pygtk, it's not too different in the newer pyGI. Finally, you can always post to AskUbuntu or StackOverflow for help from the community.

Finally, ubuntu has some specific APIs to interact with Unity. Check out the developer resources page for more info.

2
  • 1
    Please update this answer
    – Tachyons
    Jun 17, 2013 at 9:23
  • isn't Mir a display server, not a window manager?
    – strugee
    Jun 17, 2013 at 23:07
2

What I understand is that both are recomended, GTK+ and python, using PyGTK for bindings. GTK+ is still the main toolkit used in the unity interface, python is a very easy and powerfull language, and integration with unity is also easy with python.

0

The Ubuntu SDK is recommanded if you want to target the Ubuntu platform. If not, write your software in any language of your choice.

-1

Ubuntu now recommends ubuntu toolkit . It is based on qt quick2 . The apps written in this toolkit will support all the ubuntu devices . Python and GTK will be available for desktop specific applications

1
  • downvoting until you explain what "ubuntu toolkit" and "qt quick2" are, or at least give links.
    – strugee
    Jun 17, 2013 at 23:05

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .