Ubuntu Forums ubuntu.com - launchpad.net - ubuntu help  

Go Back   Ubuntu Forums > The Ubuntu Forum Community > Other Community Discussions > Tutorials & Tips
Register Reset Password Forum Help Forum Council Search Today's Posts Mark Forums Read

Tutorials & Tips
The place to find Ubuntu related Tips & Tricks.

 
Thread Tools Display Modes
Old May 28th, 2006   #1
racoq
A Carafe of Ubuntu
 
racoq's Avatar
 
Join Date: Apr 2006
Location: Coimbra, Portugal
Beans: 134
Xubuntu 8.04 Hardy Heron
Lightweight Eyecandy with adesklets

Hello everyone, since i don't like gdesklets heavy requirements (because is too heavy for the hardware), i've decided to find a more lightweight alternative for gnome. So I present in this small guide how to install, and run adesklet on Gnome, KDE, and XFCE. This guide was tested in Dapper, Edgy and Feisty and Gutsy.

Requirements:
- Internet connection
- Universe repository enabled

First of all you will need to get the adesklets package by typing the folowing command in the console:

Quote:
sudo apt-get install adesklets
This will install the adesklet package and all related packages.

Important Note:
I advise the upgrade to 0.6.1 or upper, since some important,
bugs like memory leaks were adressed, for that see the folowing link:


After that, you need to download a valid desklet to use in adesklets

This can be done by two ways:

1 -
Go to http://adesklets.sourceforge.net/desklets.html, and download a valid desklet, if you want to see weather information try downloading the weatherforecast package

You will need to extract the package, and copy it to your home directory for instance:

Quote:
tar-xvf weatherforecast-0.2.0.tar.bz2
mv weatherforecast-0.2.0 /home/"you home name account"
2 -

run the folowing command and adesklets will automatically give you the option of downloading and installing the adesklets using an graphical user interface:

Quote:
adesklets -i

Either way. assuming that you've chosen to go by the first step, go to your home directory and do:

Quote:
cd weatherforecast-0.2.0
./weatherforecast.py
that batch will ask you if you want to register this desklet, say 'r' (you want to register)

This will create the file .adesklets in your home directory and it will fill it with instructions, for running weatherforecast each time adesklets is executed

after that you need to know your city code, so go to weather.com and type your city name:

Click on your city in the search results, and he will display the weather information, copy the link and copy the reference between "/local/" and "?from=", see the following example:

http://www.weather.com/outlook/trave...om=search_city

for my city the weather.com code is POXX0035

after that do inside weatherforecast directory:

Quote:
sudo nano config.txt
and replace the location default code with your code for instance i've did for my city:

Quote:
'location': 'POXX0035'
After that to run your adesklet do:

for gnome:
Quote:
adesklets --nautilus
for kde:
Quote:
adesklets --kde
for XFCE:
Quote:
adesklets --xfce4
for Enlightenment:
Quote:
adesklets --e16
If you want that adesklets load at boot time, in gnome you can go to System => Sessions, KDE and XFCE have equivalent ways of doing that, and add one of the previous lines to startup.

If you want to download and install another desklet you can do something similar what i've did to install the weatherforecast desklet, all desklet include an config.txt, and an python batch file for registering the desklet.

The following scenarios were tested in a AMD k6-II 450 Mhz, with 256 MB RAM:
- Ubuntu (Gnome), and it worked fast.
- Kubuntu (KDE), and it worked fast.
- Xubuntu (XFCE), and it was even faster.


So you can take your own conclusions


Note for BERYL and Compiz users


Some users of beryl have been experiencing transparency problems with desklets. Since there isn't yet a solution, i found a workaround. This workaround was bnased on the feisty instructions available at the beryl project homepage. If u have any file already loading bery-manager please remove it, or don't load it.

Create the following file in your home directory


Quote:
nano startcomposite.sh
after that fill it with the following info:

Quote:
#!/bin/sh
adesklets --"your DE abbreviation"
sleep 4
beryl-manager
#if you have compiz to the following
#compiz --replace&
and save the file.

The trick here is to run adesklets before beryl / compiz, and make a sleep of 4, in order to adesklets to load before beryl-manager. Pay attention if you have more applications in the startup, you should include then in that file, for instance in my system, i also load amsn at startup so my startberyl.sh file is:

Quote:
#!/bin/sh
adesklets --xfce4
sleep 4
beryl-manager
amsn
Finally i had this script in my autostarted applications (In my XFCE system, Applications > Settings > Autostarted Applications)


This workaround worked on my Xubuntu Feisty system. In other systems the you may have to adjust the time of the sleep if it isn't enough to do the trick.

--

Adesklets its the only desklets program, prepared to be installed in either Gnome, KDE and XFCE, without installing "half system" (like it would be required if you wanted to install gdesklets in another DE than Gnome).

I've uploaded the following screenshot, taken from Xubuntu Feisty, for people who want to see adesklets in action, before installing it.

Hope this guide is useful to you!
--

UPDATE

A recent change on weather.com have broken weatherforecast desklet behaviour, if you were afected by this, please visit the following post, for the resolution.

http://ubuntuforums.org/showthread.p...94#post5152994
Attached Images
File Type: jpg screenshotmp2.jpg (526.3 KB, 1931 views)

Last edited by racoq; June 9th, 2008 at 10:42 PM.. Reason: weatherforecast desklet fix!
racoq is offline   Reply With Quote
Old June 3rd, 2006   #2
yabbadabbadont
Loony Lycanthrope
 
yabbadabbadont's Avatar
 
Join Date: Jul 2005
Beans: 6,870
Ubuntu 8.04 Hardy Heron
Re: Lightweight Eyecandy with adesklets

Good guide. A quick tip for anyone in the USA, you can just use your 5 digit zipcode instead of looking up the city code as suggested.
yabbadabbadont is offline   Reply With Quote
Old June 4th, 2006   #3
Kryptizzle
First Cup of Ubuntu
 
Join Date: Mar 2006
Location: Melbourne, Australia
Beans: 9
Re: Lightweight Eyecandy with adesklets

Thanks! Nice guide. This is the first time I've tried really tried to make my desktop look good and it's looking pretty good . The next few days look cold according to this desklet :S.
Kryptizzle is offline   Reply With Quote
Old June 4th, 2006   #4
racoq
A Carafe of Ubuntu
 
racoq's Avatar
 
Join Date: Apr 2006
Location: Coimbra, Portugal
Beans: 134
Xubuntu 8.04 Hardy Heron
Re: Lightweight Eyecandy with adesklets

Thanks, this was my first guide, i'm glad someone enjoyed it.
racoq is offline   Reply With Quote
Old June 4th, 2006   #5
yabbadabbadont
Loony Lycanthrope
 
yabbadabbadont's Avatar
 
Join Date: Jul 2005
Beans: 6,870
Ubuntu 8.04 Hardy Heron
Re: Lightweight Eyecandy with adesklets

Perhaps you can point me in the right direction. I started a thread in the desktop support forum asking if any one knows how to have gnome run a user script on logoff. So far there are no takers. Do you know how to call adesklets -k on logoff so that all running desklets will be shutdown?
yabbadabbadont is offline   Reply With Quote
Old June 4th, 2006   #6
racoq
A Carafe of Ubuntu
 
racoq's Avatar
 
Join Date: Apr 2006
Location: Coimbra, Portugal
Beans: 134
Xubuntu 8.04 Hardy Heron
Re: Lightweight Eyecandy with adesklets

See the following thread, i think it will adress your issue:

http://www.ubuntuforums.org/showthread.php?t=185261
racoq is offline   Reply With Quote
Old June 4th, 2006   #7
giuliastro
Just Give Me the Beans!
 
Join Date: Apr 2006
Beans: 59
Re: Lightweight Eyecandy with adesklets

I tried this with Dapper but nothing happens launching "adesklets --nautilus". Does adesklets work under Dapper or is it just me?
giuliastro is offline   Reply With Quote
Old July 26th, 2006   #8
Poul
Just Give Me the Beans!
 
Poul's Avatar
 
Join Date: May 2005
Beans: 52
Re: Lightweight Eyecandy with adesklets

Quote:
Originally Posted by giuliastro View Post
I tried this with Dapper but nothing happens launching "adesklets --nautilus". Does adesklets work under Dapper or is it just me?
Hey
Exact same problem. I've tried running the desklet from the console. Here's the output:
Code:
pawel@pawel-p1500:~/.desklets/weatherforecast-0.2.0$ ./weatherforecast.py
Do you want to (r)egister this desklet or to (t)est it? t
Now testing...
============================================================
If you do not see anything (or just an initial flicker
in the top left corner of your screen), try `--help',
and see the FAQ: `info adesklets'.
============================================================
Traceback (most recent call last):
  File "./weatherforecast.py", line 332, in ?
    Events(dirname(__file__)).pause()
  File "./weatherforecast.py", line 97, in __init__
    adesklets.Events_handler.__init__(self)
  File "/usr/lib/python2.4/site-packages/adesklets/events_handler.py", line 157, in __init__
    self.ready()
  File "./weatherforecast.py", line 105, in ready
    join(self.basedir,'config.txt'))
  File "./weatherforecast.py", line 79, in __init__
    adesklets.ConfigFile.__init__(self,id,filename)
  File "/usr/lib/python2.4/site-packages/adesklets/configfile.py", line 162, in __init__
    self._load_and_save()
  File "/usr/lib/python2.4/site-packages/adesklets/configfile.py", line 205, in _load_and_save
    all= ConfigImport.load(buf[:])
  File "/usr/lib/python2.4/site-packages/adesklets/configfile.py", line 41, in __call__
    return dict(self._group(
  File "/usr/lib/python2.4/compiler/transformer.py", line 52, in parse
    return Transformer().parsesuite(buf)
  File "/usr/lib/python2.4/compiler/transformer.py", line 129, in parsesuite
    return self.transform(parser.suite(text))
  File "<string>", line 1
    'location': 'UKXX0085'
              ^
SyntaxError: invalid syntax
pawel@pawel-p1500:~/.desklets/weatherforecast-0.2.0$
please help.
__________________
:://ehh quidquid latinum dictum est, altum viditur\\::.
.:://Life is a tragedy for those who feel, and a comedy for those who think ;D \\::.
Poul is offline   Reply With Quote
Old July 26th, 2006   #9
racoq
A Carafe of Ubuntu
 
racoq's Avatar
 
Join Date: Apr 2006
Location: Coimbra, Portugal
Beans: 134
Xubuntu 8.04 Hardy Heron
Re: Lightweight Eyecandy with adesklets

i guess that it's a bug from the weatherforecast-0.2.0 desklet, i've had the same problem. you can try using, weather 0.0.4 instead at, http://adesklets.sourceforge.net/desklets.html. This happens because the weather info that weather.com provides in some city's, some times go down, causing this error from the desklet, however weather 0.0.4, doesn't have this problem.

The use of this desklet was just an example on how to set up adesklets. So don't worry, if you can run another desklet on adesklet that means that your configuration is just fine !

Last edited by racoq; July 27th, 2006 at 09:41 AM..
racoq is offline   Reply With Quote
Old July 26th, 2006   #10
zarathustra
A Carafe of Ubuntu
 
Join Date: Mar 2005
Location: UK
Beans: 141
Ubuntu 9.10 Karmic Koala
Send a message via MSN to zarathustra
Re: Lightweight Eyecandy with adesklets

What version of Adesklets is in the repositories? It looks like the version is older than the current one available for download off Sourceforge.
zarathustra is offline   Reply With Quote

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 11:30 PM.


vBulletin ©2000 - 2010, Jelsoft Enterprises Ltd. Ubuntu Logo, Ubuntu and Canonical © Canonical Ltd. Tango Icons © Tango Desktop Project. lingonberry