Problem with "Open With" menu and gnome mime types?



Hi,

I hope I am addressing this to the right place.  Please redirect me if
not.  I have written a small application I am tentatively calling
"gjpegtran" (Catchy, isn't it?)  It is a front-end to the jhead and
jpegtran command line utilities that allows you to do loss-less
transformation of jpeg images that preserve all the exif information.
Quite handy for files pulled off digital cameras.

Anyway, the way I intend for this utility to work is from the Nautilus
"Open With" menu.  The idea is that for jpeg thumbnails you can open
an image with this program and easily do the transformation.  I would
like to setup the "Open With" option for this program when it is
installed.  From reading the gnome 1.x docs (I'm currently working on
a RedHat 7.2 system) it seems that placing a file with the contents:

image/jpeg:
        open.tag.Lossless JPEG Transfomer=gjpegtran %f

at the location:

/usr/share/mime-info/gjpegtrans.key

should do the trick.  However, this does not seem to work.  Even after
logging out and back in, the Nautilus "Open With" menu does not show
this option for jpeg files.  The control center File Types and
Programs capplet does not show the mapping either in the "Edit
Applications List" dialog either.  I've checked the file ownership and
permissions and they match the other entries in that directory.

If, as a user, I add the application, some cryptic information that I
don't know how to follow seems to be stuffed in the file
~/.gnome/mime-info/user.keys.  For example, an entry like:

image/jpeg
	short_list_application_user_additions=56a5acc8-bf43-48cd-8287-e6f33f60c43a,display,c9218730-08ff-4c50-a5d8-1f85286ebbd9


So, my question after all the build-up, is how, at install of
gjpegtran, can I get it listed in the "Open With" menu automatically.
My preference would be that it initially show up there, and that the
user than be able to remove it if they don't want it.  Can anyone give
me a hint?

       Thanks, Keith

P.S. -- If you are curious about gjpegtran, you can see a screenshot at:

   http://www.picnicpark.org/keith/software/gjpegtran/index.html

More information, including the download, will be posted as soon as I
resolve this problem!



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