Re: Registering MIME types and applications



On ven, 2004-07-02 at 00:19 +0200, Murray Cumming wrote:
> I'm trying to figure out what an application should do to register a new
> MIME type with GNOME 2.6, and to register itself as an application that
> is capable of opening that MIME type.
> 
> I have found the following techniques. Maybe there are more. I'd like to
> know which of these are outdated and which are the new approved
> techniques. Also, should an application register itself with multiple
> (old and new) MIME-type systems?
> 
> 1. Registering the MIME-type by putting a .xml file in 
> <prefix>/share/mime/packages, 
> and running update-mime-database.

This is the new way to register a mime type (in the freedesktop shared
mime db). Step 4 is obsolete and should be unnecessary.

> 
> 2. Registering the application by putting an .applications file in 
> <prefix>/share/application-registry/

Still needed in 2.6 as far as I know.

> 
> 3. Registing the application by putting a .desktop file in 
> <prefix>/share/applications/

I don't think gnome-vfs parses .desktop files for now, does it? 

> 
> 4. Registering the MIME-type by putting a .mime file in 
> <prefix>/share/mime-info/

Obsolete as I said previously

> 
> 5. Registering the application by putting a .keys file in 
> <prefix>/share/mime-info/
> 

Still necessary so that the app/mime type association is done in
Nautilus.

> I thought that 1, 2, and 3, were the new ways to do this, but it only
> causes Nautilus to show the MIME-type (e.g. application/x-glom), but not
> the MIME-type's name. 

Yeah, known bug, #140752, I started to work on fixing it, but never
finished the patch, I should resume work on it ;)

Hope that helps,

Christophe

Attachment: signature.asc
Description: Ceci est une partie de message =?ISO-8859-1?Q?num=E9riquement?= =?ISO-8859-1?Q?_sign=E9e?=



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