[Top][All Lists]

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

[gcmd-dev] Mime editor

From: Magnus Stålnacke
Subject: [gcmd-dev] Mime editor
Date: Mon, 19 Nov 2007 19:39:29 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv: Gecko/20061201 Firefox/

Hello all.

I have been coding some more on my mime-editor:

Latest version do _not_ work straight off as mime editor in
gcmd file properties (named as gnome-file-types-properties),
since i have made it depend on getting a filename instead
of a mimetype.

I found some problems with the earlier approach when
encountering subclass** mimetypes, to solve that would
have been.. well, a mess. So, i rewrote it, letting
gnomevfs take care about sorting out that part. I think
that it is quite easy to change the gcmd file proprty
dialog to pass filename instead of mimetype. As it is
now i have it as a program under the right-click-menu
for any type of file.

Now it works nicely, very easy to change default app.
And it reports, and works on the "right" mimetype compared
to gnome for any type of file. Do try it.

Now to a question. We all know that "Edit Mime Types.."
under the main Settings menu. That one was used under
gnome 1.x to call a general mimetype configurator that
listed all mimetypes. I plan to implement an editor like
that when the script gets called without any argument
(that would work in gcmd as is, if the script is named
gnome-file-types-properties somewhere in path). This
editor will open those *.desktop files for editing.
Do you have any thoughts about that?
Sort by mimetype or sort by application?
How to present subclasses?

** Subclass example: We all know that a shellscript is
a plain text file, but gnome reports it as
"application/x-shellscript". So, "text/plain" is the
main mime type, and x-shell... is a subclass. This way
users can have different apps for different plain text
files, and all apps registered to plain/text will also
get listed to be able to open x-shell..., but not as
default if there is a default for x-shell...

reply via email to

[Prev in Thread] Current Thread [Next in Thread]