Tag Archives: plasma

Flicking around

Software

For KDE 4.4, we’re giving a bit of touchscreen friendliness around Plasma, a thing common on touchscreen based uis is the so called flick lists and scroll views. They can be web browsers, simle item views, image explorers and so on.

You just touch (or drag with the mouse, it’s not limited to touchscreens of course) a random point of the view, drag it a bit, release and the contents will be launched with a neat animaton effect, with a resembrance of something real.

In Plasma, if you use the ScrollView widget you’ll get that for free, and if the item view contains some sub widget that wants to listend to mouse clicks as well, is sufficient to call the function ScrollView::registerAsDragHandle(QGraphicsWidget *), with some eventfilter magic, the element registered will still react to mouse click, but will pass them to the view as well. An example of this is the icon view of the Plasma netbook shell: if you click on an application icon it will launch the application, but if you press the mouse over one, move it and release, the application pointed from that icon won’t be launched, instead all the icon view will scroll and will still scroll for a while if the mouse moved over a certain speed.

There is a small video that show this behaviour over several plasmoids: the web browser, the microblog, the OpenDesktop knowledge base client and the Search and Launch interface of the netbook shell.


Ogg version

The WebView widget will behave like that as well, and if you implement a custom one and you want that behaviour -for free-, you just have to call Plasma::Animator::self()->registerScrollingManager(yourwidget), and provided you gave the proper Q_PROPERTY to your widget, all the magic will be done behind the scenes. The properties you’ll need are:

  • scrollPosition: the position in pixels of the contents relative to the viewport
  • contentsSize: the size of the contents: for instance an image could be 1680×1050 pixels big, even if the widget that is vieweing it is just 200×200
  • viewportGeometry: the actual viewport of the contents could be the bounfingRect() of the main widget or could even be something smaller: for instance excluding the area taken up by the scrollbars, if present.

Easier Plasma themes creation

Graphics

One pretty long task of plasma themes is to manually rename all the SVG sub elements with the proper names. Let’s say we want to theme a button, we will need a SVG file with the following elements: normal-top, normal-topleft, normal-left, normal-bottomleft, normal-bottom, normal-bottomright, normal-right, normal-topright and normal-center.

This is for the button in normal status, then you need the same thing with active-, pressed- and focus- prefixes

This makes Plasma themes quite powerful (and always looking pixel perfect) but it’s quite fainful to rename over a hundred of elements by hand

Since usually the themes are designed in inkscape and it has a pretty neat system to write plugins in python, i’ve decided to write a little extension that eases the ain a lot: if you select 9 elements it will rename them with the usual topleft, left, top etc names, with an optional prefix asked by a dialog. If you select 4 items, it will instead rename them as hint-top-margin, hint-left-margin etc.

The extension is located at this address, to use it you have to copy those 2 files in the ~/.inkscape/extensions folder.

Unfortunately it requires a recent snapshot of inkscape 0.47, since the python scripts used have some bugs.

As usual a video is worth 1024 words 🙂

Ogg version

Kubuntu Netbook Remix 9.10

BlaBla

So today Kubuntu 9.10 was released. I wish to the whole team my congratulations for the release 😀

I want to sped two words about a new additin in the Ubuntu fleet: Kubuntu Netbook Remix. This particular version of Kubuntu ships (and uses as the default user interface) an early preview of what will be the Plasma Netbook project.

We (as both upstream KDE people and Kubuntu people) wanted to quickly put something out of the door, to give people an easy way to test it, and make it a bit more known before the final release, and requiring people to run trunk is not really reasonable, while a livecd poses a way lower entry barrier.

While you are testing it, please keep in mind is software in a really early stage of development.Kubuntu Karmic Koala of course uses KDE 4.3, because it’s what is out at the moment :). Since some months ago the Netbook project uses some important new features that will be in the Plasma library for KDE 4.4, so the version shipped in Kubuntu is a snapshot a bit older that what is in svn now (plus some backports of more recent fixes), that’s why it looks pretty different to the last screencasts i did.

So keep in mind that the “real deal” on Kubuntu will come just with 10.04 (or as soon as KDE 4.4 packages will be released), but I’m confident that what is shipped now is something already quite fun to use, and gives an idea how it will be, so try it, have fun 🙂

Search and Launch improvements

Software

I’ve already talked about the search and launch activity for the netbook shell, so this video rather than explaining again what this is it just gives a brief description of what is changed on it and where the work is heading:

Some work has been done on keyboard navigation, on always giving the expected thing the keyboard focus.

A pretty iconview class has been written to be used in both the results and on the favourite icons on top, making it possible to scroll by “flicking” with the mouse or with the finger in both places, with many cute animations.

And of course tons and tons of fixes.

OGG version.

Random bits

Software

*Arthur makes remote widgets work on the new Nokia N900: this has really awesome implications. Rob’s work on remote widgets is really cool by itself, and if you add the possibility of exporting widgets on a small device like that it opens the doors to really cool applications, think about a really rich remote controller for your mediacenter, a way for a conference speaker to publish his slides or something related to the attendees regardless the device they’re using, a way for a teacher to control what is available in a computer lab room desktops and stuff we still did not tought about.

*KDE depends on Qt 4.6. This opens the door for us to the use of all the cool new features of this release, a thing we were drooling about since quite some time is the new animation framework. A summer of code project was done to make a really easy to use API to access it from Plasma, to have a library of stock effects that will be coherent across all the widgets. It has been merged into trunk now and when it will be put really in use expect to see fireworks 😀

*Work on the netbook interface continues, we got a pretty nice workflow model for using the newspaper activity, plus the Search and launch activity changed quite a lot since the last screencast. I should reeeally do a couple of new ones, so stay tuned 😀

Trying the netbook project made easy

Software

Since two days there is a new module in systemsettings: workspace under the Desktop category.
workspace options
Here is possible to switch between the Plasma desktop shell and the netbook shell. the switch will be done on the fly (no need to restart KDE) and it will be remembered the next KDE start.

Plasma desktop will close, Plasma netbook will start and some different settings on KWin will be applied: windows will start as maximized and there will be no border for maximized windows.

The other section is Dashboard: is now possible to configure from here if you want the dashboard with the same content of your desktop or if you want it to show an independent set of widgets.

In the same way, in the Multiple desktops section, is now possible to decide if you want a different plasma activity for each desktop, so the quite hidden config dialog reachable from the zoom interface for those two options has been removed.

Dropping in, dropping out

Software

I love when an idea starts to taking form and suddenly starts to make sense in an unexpected way… some days ago Aaron blogged about dropping remote contents inside Plasma: now is possible to drop in several types of content, even from the network and the proper plasmoid capable of doing a little preview of that content will pop up, like the picture frame for an image or the web browser for an html page.

The idea of Plasma as a canvas for some kind of smart bookmarks with live preview of your content and work is taking shape, now what was the logical step was to ask.. what about the other way around?

We now have a quite simple way in the plasma api to associate an application, or an url (with the proper application detected from the mime type) to a Plasma widget. A new button will appear in the applet handle (and a new entry in the context menu) and that application will be launched. The idea is to have a full view of what you have in the widget, as a tiny preview.


OGG version

Looking back at Tokamak 3

BlaBla

I’m starting this entry on the train on the way home from Tokamak (and finishing it at home). Looking back it was probably the best KDE event I ever been. I’m already missing each one on every person that was there.
>Fisrt of all I want to thank Mario Fux forhosting the event. It was a really big job for him and everything was gone perfectly smootly.
The place was of breathtaking beauty, I didn’t brought a camera myself but you can see from other blog entries on planetkde photos of this beautiful place. Last day we gone at the bottom of the Motterhorn mountain with the cablecar. This mountain is beautiful because it’s an huge block of rock of the exact shape you would expect from a mountain, really makes you remember how tiny human being are on this planet (yeah, sounds clich

Say something Tokamak

BlaBla

Didn’t really find much time to blog at tokamak. Anyways, what I’ve been doing?

  • The netbook shell has found a new home in kdebase, so now if you build trunk it will be here and will definitely be here for the release of KDE 4.4. This is realy important because it makes easier for people to try it right now without having to compile components from playground. Another important reason for the move is the reuse of the existing coomponents, in particular the new widgets explorer that has been merged from the Gsoc project of Ana, that makes the experience of both plasma-desktop and plasma-netbook much more pleasant. Not much to add right now but stay tuned for a screencast in the next few days.
  • The KnotificationItem library, that is the client of the new systemtray specification has been merged in the KDEUI module. This means is no more experimental and all applications can start to use it without fears of binary incompatibilities. At this point the start of a Freedesktop standardization seems much more realistic.
  • Ad oh well, we are all been busy in refactoring and moving aroundstuff, so while there could be some instabilities in trunk right now, the plasma library will become much more clean and robust in the future.
  • Anyways, many props goes to Rob and Ana that have gone trough the endeavour of merging their pretty big Gsoc projects, this did mean work and work and work, but i’m speechless about the quality of the projects. Ana’s widget explorer makes plasmamuch more usable and pleasant to use, Rob’s remore widgets are well, revolutionary, can’t find other words, but i’m not gonna to explain them here, they can do a much better job.

Progress on the netbook ui

Software

A while since last blog, so it seems nice to give some updates on the progress on the Plasma netbook shell, since in the past weeks i did some visual changes.

Netbook newspaper

Now the widgets in the newspaper activity shows their background, to achieve more opacity (and readability), and the scroll area have a neat shadow effect to make the clipped edges to look better. The widget in the newspaper containment now should also keep their aspect ratio in a better way.

Netbook newspaper

Also the search and launch interface has some fixes in its layout, and when no query is entered in the search field it spots some icons that do default queries, like all programs of a given category, all contacts and all bookmarks.

To maximize the space given to applications in those tiny screen resolutions now the panel is auto-hide, with the same sliding animation present in the main plasma desktop autohide panels (from KDE 4.4 done by my first Kwin effect, yay :D)

Here comes the usual video (the flickering of the panel is just a problem of the screencast), in the usual YouTube or OGG-o-vision, enjoy 😀