mime and freedesktop (was: Desktop Icons)
edscott wilson garcia
edscott at imp.mx
Tue Sep 30 17:10:01 CEST 2003
On Mon, 2003-09-29 at 22:36, Biju Chacko wrote:
> > BTW, what's the freedesktop icon spec?
> Good grief, Edscott. You really need to browse freedesktop.org sometime. There
> are several standards that impact on the behavior of a filemanager. The
> shared-mime-info spec is probably the most important.
/me goes to look at freedesktop.org.
Well, well, well.
Freedesktop proposes using xml for mime information. That's good. Xffm
does that. But there are some differences. Xffm uses a single file
(following the gnome way), while freedesktop uses twenty thousand score
files (following the kde way). Keeping tabs on twenty thousand score
files is very inefficient, so freedesktop suggests hacking up a binary
database. But Benny does not like hacks...
And there is one thorn drawing blood...
If mime info boils down to one file (xml or binary) shared by all
desktops, which desktop in a multi-desktop environment, will provide for
"I will!", says K.
"No", says G., with arms raising to the sky. "I will!".
But B. in the corner mumbles "Kids... Don't you recognise me?"
- mime info in xml: good.
- single file for all: bad. That's B.'s game.
Nonetheless, there is a current "de facto" MIME standard by M. ---and
which even B. follows:
mime information contains the following elements:
- (char *) application mime-type according to simple file extension.
- (char *) associated executable program for each mime-type
- (char *) associated icon for each mime-type
K.'s implementation adds the indispensable bloat factor:
- (array of char *) program description, one for each language
While xffm accommodates all by using
- (array of char *) associated executable programs for each mime-type
No trouble exists to make xffm able to read mime info provided by G., K.
and B. on the fly. But is that really necessary? The bloat reduction
formula calls for this to be done beforehand so that the extra code is
not necessary. And since the mime format of G. and K. are still moving
targets, I would much rather do that than deal with the subsequent bugs
which nobody will have time to fix.
More information about the Xfce4-dev