[Gpephone-devel] Adding new entry to .desktop file

Nils Faerber nils.faerber at kernelconcepts.de
Mon Jan 7 12:24:13 CET 2008


YU Yijun RD-ILAB-PEK schrieb:
> Hi,
Hi!

> It seems that we have a heated discussion on the mimetype/verb format and I also think it is very important and urgent. Considering the time constraint, I think it is time for us to draw a conclusion. Based on the previous discussion, I propose we may try the following temporary solution first and we can see what will happen in the freedesktop.org later.

Well, I would not call it heated ;)

> X-MimeTypeActions = text/html:open,edit;text/plain:open,edit;text/pdf:open;
> 
> Obviously it is not far away for your guys' suggestion. Comments?

It is reasonable - maintainable and not confusing.

So if there is the urgent need to have something *now* then I would
agree with it. Realistically it will take several days (if not weeks) to
get some conclusive answer.

> Regards
> Yu Yijun
Cheers
  nils

>> -----Original Message-----
>> From: gpephone-devel-bounces at linuxtogo.org
>> [mailto:gpephone-devel-bounces at linuxtogo.org] On Behalf Of Florian Boor
>> Sent: 2008年1月3日 22:22
>> To: Nils Faerber
>> Cc: gpephone-devel at linuxtogo.org
>> Subject: Re: [Gpephone-devel] Adding new entry to .desktop file
>>
>> Hi,
>>
>> Nils Faerber schrieb:
>>> For me this translates as, the desktop file will contain all mimetype an
>>> application can handle. Then there is the mimetype database where
>>> applications can add the "verbs", i.e. actions. The tutorial (above)
>>> shows an example for Gimp:
>>> 	<desktop:can-edit-with>gimp.desktop</desktop:can-edit-with>
>>>
>>> It is not clear to me yet where this information will end and how to use
>>> it. But it seems to me the correct start of the track - if there is
>>> already a standard wayof doing it, we should try to use it.
>> I'm not sure if this is exactly what we want to use. That means that we use the
>> shared mime database and application provided overrides to it instead of
>> providing the data in the desktop files themselves. We could do this but then
>> we
>> get a lot of additional complexity such as a second database that needs to be
>> merged from several files and the need to provide an xml file for each
>> application that handles a mime type.
>> The desktop file standard allows extending the desktop files by custom data
>> fields where the name of these fields has to start with 'X-' indicating a
>> non-standard entry. That means we can extend the desktop files without breaking
>> standard compatibility.
>> An alternative way to provide both mime types and related actions could be
>> something like this:
>>
>> MimeType = text/html;text/plain;text/pdf
>> X-MimeCapabilities = open,edit;open,edit;open
>>
>> Once we are sure our solution is useful in real life we could propose it as an
>> extension to the standard.
>>
>> A related problem is the desired way of selecting the right application for an
>> action. The mime database supports to put a priority into the xml file but that
>> means that the information which application to use is shipped with the
>> application itself. For security and reliability reasons we need a way to teach
>> gpe-applauncher only to use a predefined application for some mime type. This
>> information should never be part of the application package itself. For all
>> types/actions that are not bound to a single handler we need to offer some user
>> interface to allow the user to select the preferred handler for these.
>>
>> Greetings
>>
>> Florian
>>

-- 
kernel concepts GbR        Tel: +49-271-771091-12
Sieghuetter Hauptweg 48    Fax: +49-271-771091-19
D-57072 Siegen             Mob: +49-176-21024535
--



More information about the Gpephone-devel mailing list