Re: .desktop



Hi Ulrik,

So maybe I confuse but it does not seems to parse those for me the from code :

In [13]: cat /home/chmouel/Desktop/Thunderbird.desktop
#!/usr/bin/env xdg-open

[Desktop Entry]
Encoding=UTF-8
Version=1.0
Type=Application
Terminal=false
Icon[en_GB]=gnome-panel-launcher
Name[en_GB]=Thunderbird
Exec=/opt/thunderbird/thunderbird
Name=Thunderbird
Icon=/home/chmouel/Photos/Icons/icon_thunderbird.png

In [14]: 'thunderbird' in [ x.get_name().lower() for x in
gio.app_info_get_all() ]
Out[14]: False

am I looking on the wrong part of the code ?

Chmouel.

2009/11/24 Ulrik Sverdrup <ulrik sverdrup gmail com>:
> 2009/11/24 Chmouel Boudjnah <chmouel chmouel com>:
>> ~/Desktop the default desktop folder showing in Gnome and KDE it's a
>> standard by the freedesktop crowd :
>>
>> http://standards.freedesktop.org/desktop-entry-spec/latest/
>
>
> This is very confusing. Now you mention ~/Desktop which is the folder
> whose contents are spread over the desktop background. But you link to
> the desktop entry specification (which I have read carefully) which is
> about defining application and localtion description files. Like.
> gedit.desktop
>
>
>>
>> Basically when you have a desktop on Gnome or KDE and you have a
>> background desktop every icon you see on the desktop are .desktop file
>> due application.
>
> What do you mean? You can have programs on the desktop, say, I create
> vim.desktop and put it in ~/Desktop/vim.desktop  . Now I have a
> clickable application icon on my desktop background. But not all files
> there are like that -- there are files, folders and symlinks in my
> ~/Desktop as well.
>
>>
>> For now kupfer (via gio) parse only the standard offered application
>> not the customize ones (ie: the one on the Desktop).
>>
>
> This is not true. I'm not so happy with it, but Kupfer reads all
> .desktop files it finds, in any included catalogs! (by default, ~ and
> ~/Desktop)
>
> Why this is not optimal is that there is no indication that the
> program came from a file. And it might give you duplicate applications
> -- if you duplicate the ones in the normal application directories.
>
> Let me emphasize -- if you add ~/  as a directory in the catalog
> (there by default in Kupfer), found .desktop files will be parsed
> (ConstructFileLeaf, object.py, line 312).
>
> The best way to add custom applications to kupfer is to define
> .desktop files and add in ~/.local/share/applications
>


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]