Declarative Mobile UI

Bart Cerneels bart.cerneels at kde.org
Tue Mar 23 16:42:30 CET 2010


On Fri, Mar 19, 2010 at 22:49, Jeff Mitchell <mitchell at kde.org> wrote:
> Hi guys,
>
> With commit 316911d22 I have taken my official first step towards Amarok
> Mobile  :-)
>
> This was discussed on IRC a while back, but for those not aware, the
> idea is to reuse as much code as possible...which basically means that
> two things are needed:
>
> 1) The ability to control which parts to build on a mobile system
> 2) Separation of GUI/logic
>
<snip>

It might be to early to discuss the UI for mobile, but I feel this is
GUI-separation related in the most fundamental way.

We should consider writing the whole mobile GUI in Qt Quick (former
declarative UI / QML [1]) from the start. That means making all our
none GUI components accessible by making (more) use of QProperty and
perhaps introduce a state-machine here and there. Probably is a little
harder work then that and there will be a learning curve (perhaps
downwards since we'll be waning ourselves of imperative GUI
programming)

What that gives us though is complete GUI separation and we can from
then on just hand of all GUI work to the designers. Thank of what
Enrico, Thomas, Nuno and other could do when they design in complete
freedom. And evaluating GUI design iteration will be as simple as
loading a different qml-file. Hard to bikeshed when it's backed up
with code...

I propose we start a research project to get to know and understand Qt
Quick. Something we all know and love (/hate) and haven't felt shy
experimenting with in the past: a new toolbar :)

Seriously though, I propose we make a toolbar implementation that just
runs a QML file. Except for the size (needs to fit in the mainwindow)
nothing is controlled from outside of the QML.
Enrico already demonstrated such a toolbar in the past [2] he just
wasn't using QML yet. Thomas certainly can create an independent UI
and we can all contribute our attempts. Meanwhile the developers will
be making sure as much is exposed and controllable from QML. This will
hopefully lead very fast to a good understanding of the declarative UI
concept.

If successful we can start thinking how to add our models and context
info to this mix.

Bart

[1] http://labs.trolltech.com/page/Projects/Graphics/Kinetic/DeclarativeUI
[2] http://www.enricoros.com/blog/2009/10/addiqted/


More information about the Amarok-devel mailing list