Your SlideShare is downloading. ×
0
Marc Ordinas i Llopis marcoil My first desktop widget
Desktop Widgets <ul><li>Normal windows with special type: </li></ul><ul><ul><li>_NET_WM_WINDOW_TYPE:  _HILDON_WM_WINDOW_TY...
libhildondesktop <ul><li>Lifetime management and positioning </li></ul><ul><li>Utility class HDHomePluginItem </li></ul><u...
Lifetime management <ul><li>Desktop file describes the widget </li></ul><ul><li>Library loaded by hildon-home </li></ul><u...
HDHomePluginItem <ul><li>Base class for desktop widgets </li></ul><ul><li>Derived from  GtkWindow </li></ul><ul><ul><li>Us...
Energy saving <ul><li>is-on-current-desktop  property </li></ul><ul><li>Listen to notification changes </li></ul><ul><ul><...
Settings <ul><li>Set property </li></ul><ul><ul><li>HDHomePluginItem::settings </li></ul></ul><ul><li>Listen to signal </l...
Transparency <ul><li>In the  realize  method </li></ul><ul><ul><li>Set colormap to RGBA. </li></ul></ul><ul><ul><li>Set ap...
Questions? Examples at https://garage.maemo.org/projects/maemoexamples/
Upcoming SlideShare
Loading in...5
×

My first Maemo desktop widget

2,638

Published on

Presentation given at the Maemo Barcelona Long Weekend on how to develop desktop widgets.

Published in: Technology
0 Comments
3 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
2,638
On Slideshare
0
From Embeds
0
Number of Embeds
1
Actions
Shares
0
Downloads
17
Comments
0
Likes
3
Embeds 0
No embeds

No notes for slide

Transcript of "My first Maemo desktop widget"

  1. 1. Marc Ordinas i Llopis marcoil My first desktop widget
  2. 2. Desktop Widgets <ul><li>Normal windows with special type: </li></ul><ul><ul><li>_NET_WM_WINDOW_TYPE: _HILDON_WM_WINDOW_TYPE_HOME_APPLET </li></ul></ul><ul><li>Composited by the desktop on home </li></ul>
  3. 3. libhildondesktop <ul><li>Lifetime management and positioning </li></ul><ul><li>Utility class HDHomePluginItem </li></ul><ul><li>Visibility and settings </li></ul><ul><li>Code at http://maemo.gitorious.org/fremantle-hildon-desktop/libhildondesktop </li></ul>
  4. 4. Lifetime management <ul><li>Desktop file describes the widget </li></ul><ul><li>Library loaded by hildon-home </li></ul><ul><li>Position kept in GConf </li></ul><ul><li>Please see the example at </li></ul><ul><li>https://garage.maemo.org/svn/maemoexamples/trunk/example_desktop_widget/ </li></ul>
  5. 5. HDHomePluginItem <ul><li>Base class for desktop widgets </li></ul><ul><li>Derived from GtkWindow </li></ul><ul><ul><li>Use as a container. </li></ul></ul><ul><ul><li>Or, draw directly using cairo. </li></ul></ul>
  6. 6. Energy saving <ul><li>is-on-current-desktop property </li></ul><ul><li>Listen to notification changes </li></ul><ul><ul><li>notify::is-on-current-desktop </li></ul></ul><ul><li>If not visible </li></ul><ul><ul><li>Don't draw </li></ul></ul><ul><ul><li>Use as few resources as possible </li></ul></ul>
  7. 7. Settings <ul><li>Set property </li></ul><ul><ul><li>HDHomePluginItem::settings </li></ul></ul><ul><li>Listen to signal </li></ul><ul><ul><li>HDHomePluginItem::show-settings </li></ul></ul>
  8. 8. Transparency <ul><li>In the realize method </li></ul><ul><ul><li>Set colormap to RGBA. </li></ul></ul><ul><ul><li>Set app paintable to true. </li></ul></ul><ul><li>In the expose_event method </li></ul><ul><ul><li>Draw directly (using cairo, for example). </li></ul></ul>
  9. 9. Questions? Examples at https://garage.maemo.org/projects/maemoexamples/
  1. A particular slide catching your eye?

    Clipping is a handy way to collect important slides you want to go back to later.

×