A few Lubuntu Menu things...

Israel israeldahl at gmail.com
Thu Dec 19 23:54:17 UTC 2013


On 12/19/2013 11:30 AM, Aere Greenway wrote:
> On 12/19/2013 07:09 AM, Israel wrote:
>> On 12/19/2013 01:20 AM, Eric Bradshaw wrote:
>>> Larger than normal (or no) icons for shortcuts/.desktop entry files in
>>> menu/Desktop - All apps (beginning with the letter "A" anyway)
>>> installed through LSC.
>>>
>>> A
>>> Abe's Amazing Adventure
>>> Icon=/usr/share/pixmaps/abe.xpm
>>> Aconnectgui
>>> Icon=/usr/share/pixmaps/aconnectgui.xpm
>>> Advanced Strategic Command (no icon)
>>> Icon=asc
>>> alevt (no icon)
>>> Icon=alevt
>>> AltOS UI
>>> Icon=/usr/share/pixmaps/altusmetrum.xpm
>>> Alleyoop Memory Checker (no icon)
>>> Icon=alleyoop
>>> Alsamixergui
>>> Icon=/usr/share/pixmaps/alsamixergui.xpm
>>> Alsaplayer (no icon)
>>> Icon=alsaplayer
>>> Amora Daemon (no icon)
>>> Icon=amora
>>> Anagramarama (no icon)
>>> Icon=
>>> Apitrace Retracer
>>> [Icon line missing completely]
>>> Artemis
>>> Icon=/usr/share/pixmaps/artemis.xpm
>>> Athena
>>> Icon=/usr/share/pixmaps/athena.xpm
>>> apvlv
>>> Icon=/usr/share/pixmaps/apvlv/apvlv.xpm
>>> ARC Certificate Utility (no icon)
>>> Icon=system-config-authentication
>>> ARC Job Submission Tool (no icon)
>>> Icon=system-config-authentication
>>> ARC Proxy Generator (no icon)
>>> Icon=system-config-authentication
>>> Aqualung
>>> Icon=aqualung.xpm
>>> AutoRenamer (no icon)
>>> [Icon line missing completely]
>>> Atris (no icon)
>>> [Icon line missing completely]
>>> Attal
>>> Icon=
>>>
>>> Childsplay
>>> Icon=logo_cp_32x32.xpm
>>> Dr.geo
>>> Icon=drgeo_32x32.xpm
>>> Linux Letters and Numbers
>>> Icon=lletters.xpm
>>> Mobile Atlas Creator
>>> Icon=/usr/share/pixmaps/mobile-atlas-creator/mobac.xpm
>>>
>>> Eric
>>>
>> woah... that is amazing!  Thanks!!
>>
> Israel, and all:
>
> I wonder if we can do something now to keep this problem from getting
> larger.
>
> As a developer (and long-time Linux user), I really don't know what I
> need to provide as an icon for my application.
>
> What I did (which works fine in all the Linux distributions I have
> tested my application in), was to look at other applications, and
> provide what they provided.
>
> Yet there is a lot of variability apparent in that 'looking at other
> applications'.
>
> Some applications provide icons of 3 different sizes.  Some provide
> SVG format icons.  Most provide a single PNG format icon.
>
> The icons you supply are different sizes when shown on the desktop, in
> the menu, and in the task-bar, even when only one size is supplied.
>
> The icon you place in the title-bar of the application (if the
> title-bar is used) needs to be such a small size that what is
> intuitively understandable as a normal-size icon, is not readable at
> the smaller size (I ended up having two different, though same
> color-scheme) icons for the small (title-bar) size, as opposed to the
> normal (menu and desktop) icon size.
>
> What I ended up supplying, was a single 64x64 (pixel) icon, in the PNG
> format.  And that seems to work in the various contexts it is used
> (including the task-bar).   But mine is not supplied as a Debian
> package, but rather, Java Web-Start sorts it out in creating a desktop
> launcher, which my installer then copies to where the menu launchers
> are expected.
>
> My case is further complicated in that the size may have been dictated
> by the Java Network Launch Protocol (JNLP) specification.
>
> Do any of you know where a standard of what needs to be supplied in
> the way of icons is documented (at least, for Debian packages)?  If
> there is, is there a way of making its existence more visible to new
> developers?
>
What I do is make an xpm and a png....  but I suppose there needs to be
a way for the menu to automatically size icons when it updates.  There
are ways you can size icons in the rules file:
for example
to fix lmms icon, I added this:

debian/lmms.png: debian/lmms.png
install: build debian/lmms.png
install: build
    dh_testdir
    dh_testroot
    dh_clean -k
    dh_installdirs
    $(MAKE) install DESTDIR=$(CURDIR)/debian/tmp
    install -D -m 644 debian/lmms.png
debian/lmms-common/usr/share/pixmaps/lmms.png
    install -D -m 644 debian/menu debian/lmms-common/usr/share/menu/lmms

but Irie does this:

ICON_SIZES = 16 22 24 32 48 64
override_dh_auto_build:
    dh_auto_build
    convert -resize 32 data/themes/default/icon.png debian/lmms.xpm
    for i in $(ICON_SIZES); do \
        convert -resize $$i data/themes/default/icon.png
debian/lmms$${i}.png; \
    done

override_dh_clean:
    dh_clean
    rm -f debian/lmms.xpm debian/lmms*.png
override_dh_install:
    dh_install
    rm -f debian/lmms/usr/lib/lmms/RemoteVstPlugin*
    install -D -m 644 debian/lmms.xpm
debian/lmms-common/usr/share/pixmaps/lmms.xpm
    for i in $(ICON_SIZES); do \
        install -D -m 644 debian/lmms$${i}.png \
           
debian/lmms-common/usr/share/icons/hicolor/$${i}x$${i}/apps/lmms.png; \
    done

So, some of it is a matter of choice, and obviously you will probably
use different parts of dh, so you will have to do some things
differently.  I have yet to find a good comprehensive explanation of all
the parts of the rules file / dh.  I know Debian packaging guide has
stuff about it, but it isn't as in depth, and descriptive as I'd like.

Though, for the menu, each time an app is installed it gets updated via
a script.  I don't know what script it uses, so if anyone is more
knowledgeable I'd appreciate it, but via scripting language you can
convert icons.  It is even possible to use inkscape from the command
line, though I am not sure if you can convert raster to svg from the
command line, but it seems possible to me.  If I remember right
Imagemagic (sp?) can convert images from the command line (and likely
resize and convert to png format).  So, since we are using GNU/Linux it
is possible to make the menu update and resize icons accordingly,
however I am not familiar enough with Bash, or the menu script, or
imagemagic.  So... I suppose we could take this to Ubuntu or AskUbuntu
or some irc channel and find out.  I have got too many things going on
right now to do that, so anyone who wants an activity can help us here

-- 
Regards




More information about the Lubuntu-users mailing list