maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Development (https://talk.maemo.org/forumdisplay.php?f=13)
-   -   Application icon in startup menu (https://talk.maemo.org/showthread.php?t=27702)

fma 2009-03-20 12:49

Application icon in startup menu
 
Hi,

Could someone explain me how to have a big icon in the startup menu on OS2008? I read several things, and it is always a 26x26 icon which is used. But I can see that other applications have bigger icons than mine. I tried to use a 40x40 (like some other do) icon, but it remains small.

My desktop entry looks like:

Code:

[Desktop Entry]
Version=1.0
Encoding=UTF-8
Name=Papywizard
Exec=/usr/bin/papywizard.sh
Icon=papywizard
Type=Application

My icon, named papywizard.png is located in /usr/share/pixmaps.

I tried many things, but it never worked. I'm puzzled...

Thanks,

Jaffa 2009-03-20 13:05

Re: Application icon in startup menu
 
The following should be three useful sources of info:
  1. http://mud-builder.garage.maemo.org/...ge.html#extras
  2. http://thpinfo.com/2008/02/maemo-icon-sizes.html (note the missing "hicolor", though)
  3. https://garage.maemo.org/viewvc/trun...ot=mud-builder

HTH,

Andrew

fma 2009-03-20 14:06

Re: Application icon in startup menu
 
Ok, after many tries, I finally got it work! But it is really a pain in the bottom!!! In fact, it does not work with my desktop entry; I had to change the Name to 'papywizard' (lower-case) to fit the Icon name. But if I switch both name (and icon one) to Papywizard, it does not work. If I want to have a P (capitalized) in the name, and a p (lower case) in the icon, I have to add:

X-Window-Icon=papywizard
X-Window-Icon-dimmed=papywizard

And I only need the icon in the scalable dir...

Ouf!

Thanks for the links :)

fma 2009-03-20 14:12

Re: Application icon in startup menu
 
Another question: How do I have my application icon displayed in the taskbar? Is it also managed by the desktop entry? Or should it be embedded in the window? In fact, I have it, but it may need a specific size?

Jaffa 2009-03-20 22:43

Re: Application icon in startup menu
 
Quote:

Originally Posted by fma (Post 273215)
Another question: How do I have my application icon displayed in the taskbar? Is it also managed by the desktop entry? Or should it be embedded in the window? In fact, I have it, but it may need a specific size?

The task bar one is 26x26, and there are a number of different mechanisms by which the icon is selected.

There've been a number of threads on maemo-developers about it in the past, and I'm afraid I don't have the links to hand (or the time to search for them); however I'd strongly suggest you take this opportunity to see if there's a wiki page (perhaps http://wiki.maemo.org/Application_icons?) and - if not - create one pulling together these nuances you're finding.

Even having a first draft will give something the community to rally round and improve.

fma 2009-03-20 23:11

Re: Application icon in startup menu
 
I searched in the archives, and all questions related to that problem never get an answer :(

Jaffa 2009-03-20 23:16

Re: Application icon in startup menu
 
http://www.mail-archive.com/maemo-de.../msg17012.html looks like a relevant, and in-depth, thread.

fma 2009-03-20 23:59

Re: Application icon in startup menu
 
Ok, I found: I needed to add the StartupWMClass param, with the name of the main window (Papywizard, capitalized). And it now works :)

As I only have the scalable icon (a 64x64 png file), so it is huge. But I guess adding a 40x40 one should do the trick.

fma 2009-03-23 08:15

Re: Application icon in startup menu
 
Unfotunally, I can't find the way to have a big icon in the startup menu, and a small one in the task bar... I know it is possible, because other applications do this, but I don't know how :(

fanoush 2009-03-23 08:50

Re: Application icon in startup menu
 
I had similar problem with bigger icons with scummvm and did not find sufficient documentation and filed bug https://bugs.maemo.org/show_bug.cgi?id=3619

In ScummVM the issue was that OS2008 system for some reason preferred small icon in /usr/share/icons over the big ones in other icon folders. Sadly OS2006 did not support small icon in those new folders so my final solution was to keep both and remove /usr/share/icons/scummvm.xpm in postinstall script for OS2008.

Also there is icon cache so without flushing/updating the cache via gtk-update-icon-cache the final result varies.

daperl 2009-03-23 14:14

Re: Application icon in startup menu
 
It should be as simple as this:

Icon=foo in /usr/share/applications/hildon/foo.desktop

a 26x26 in 26X26/hildon/foo.png
a 40x40 in 40x40/hildon/foo.png
a 64x64 in scalable/hildon/foo.png

no cheating, exact image sizes

exit all programs
gtk-update-icon-cache -f /usr/share/icons/hicolor
reboot

Works for me every time.

fma 2009-03-23 17:04

Re: Application icon in startup menu
 
That's exactly what I did, and it does not work. Both locations use the icons in this order:

scalable
64x64
40x40
26x26

So, I have 2 bigs icons, or 2 small ones... Don't understand why. My code is here:

http://trac.gbiloba.org/papywizard/browser/trunk/maemo

daperl 2009-03-23 19:01

Re: Application icon in startup menu
 
I couldn't seem to svn your project, but if your latest 2.1 deb is close enough, then your icons look fine.

But I'm just a simple caveman and your desktop ways scare me. If your project was mine, here is how my tablet desktop file would look:

[Desktop Entry]
Encoding=UTF-8
Name=Papywizard
Icon=papywizard
Comment=We put the Pap back in Wizard
Exec=/usr/bin/papywizard.sh
Terminal=false
Type=Application
Categories=Application;Internet;
X-Osso-Type=application/x-executable

Maybe just give this a try with my other steps above. And just to be safe, after updating the icon cache, go straight to reboot; don't go lookin' at icons.

Also, not that it matters, but it couldn't hurt to have a '!' after the '#' at the top of papywizard.sh.

fma 2009-03-23 19:14

Re: Application icon in startup menu
 
I will try your desktop file...


All times are GMT. The time now is 20:07.

vBulletin® Version 3.8.8