GIMP dumping on mimetypes
FedoraForum.org - Fedora Support Forums and Community
Results 1 to 9 of 9
  1. #1
    Join Date
    Nov 2009
    Posts
    371
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    GIMP dumping on mimetypes

    Hi,

    this issue seems to have been ongoing since about 2010 according to searches but I don't find anything but a local hack. Why has this not been fixed.

    It seems like the GIMP package is being allowed to grab just about anything it can read and install itself as the default handler. This is often the most inappropriate thing to do.

    For example , images like png and jpeg get grabbed but the most common thing I want to do with an image is VIEW it , not start doing advance image manipulation.

    Worse still, pdf format. I want to READ the damned thing not start editing it in an image processing tool.

    This is madness, Why is GIMP being allowed to get away wtth this IEXPLORE mentality on Linux?

    If GIMP devs are trying to force feed us GIMP by spamming mimetype setting the distro needs to clean this up in the Fedora packages and tell gimp dev to get back in their box and stop messing with system files.
    Code:
    cat  /usr/share/applications/mimeinfo.cache | grep pdf
    application/pdf=gimp.desktop;kde4-okularApplication_pdf.desktop;
    application/x-bzpdf=kde4-okularApplication_pdf.desktop;
    application/x-gzpdf=kde4-okularApplication_pdf.desktop;
    application/x-wwf=kde4-okularApplication_pdf.desktop;
    Presumably if I reset this , next time install gimp updates it will come back.

    This is most annoying in Firefox where I invariably want to just open the pdf for viewing in okular. I have all firefox settings set to okular or "always aks" but this is not being respected.

    If I want GIMP, I will fire it up to do a job . How can I get it out of my hair and stop it grabbing all these file formats?

    TIA.

  2. #2
    Join Date
    Jun 2007
    Location
    Aubagne France
    Age
    66
    Posts
    673
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes


  3. #3
    Join Date
    Jun 2007
    Location
    Lytham St Annes, Lancashire, UK
    Posts
    687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    On my (Cinnamon Desktop) installation, "/usr/share/applications/mimeinfo.cache" is the system-wide list of programs that can process the various mime-types. I also have a file in my home directory ".local/share/applications/mimeinfo.cache" which holds the single program I have set to deal with various mime-types.

    It looks like "/usr/share/applications/mimeinfo.cache" simply lists programs in the order installed - Gimp was the last insalled of the three listed on my system:
    Code:
    application/pdf=evince.desktop;evince-previewer.desktop;pdfmod.desktop;gimp.desktop;
    I have not set a specific application for PDF documents as Evince is my preferred PDF viewer and it is first on the list.

    Have you tried accessing a PDF file via a file manager? Right-clicking the file and selecting "Properties" should allow you to set your default application to deal with that mime-type. As this should be saved to ".local/share/applications/mimeinfo.cache" in your home directory, subsequent upgrades to Gimp (or other PDF-capable programs) should not affect your personal selection.

  4. #4
    Join Date
    Nov 2009
    Posts
    371
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    Thanks. Actually it's the opposite. Gimp installs itself at the front of the list. Like a $PATH variable it seems to be the first one which taken.

    I just fixed the one in /usr/share , did a re-installation of Gimp and it was back at the head of the list.

    I'm using the LXDE spin and xfe is my FM. That has the correct file associations but they do not seem to trump Gimp setting itself up.

    This is a bit of a mess, since it really does not even depend upon the order of installation but the program with the most recent update. This is really getting back the browser wars when IE was constantly resetting itself as the default browser with out even a nod to the user.

  5. #5
    Join Date
    Nov 2009
    Posts
    371
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    while I was in there I notice all this cruft that WINE has put in there. Seems like this is global problem in that way packets are allowed to mess with user settings.

    Code:
    application/rtf=wine-extension-rtf.desktop;
    application/vnd.ms-htmlhelp=wine-extension-chm.desktop;
    application/x-mswinurl=wine-extension-url.desktop;
    application/x-mswrite=wine-extension-wri.desktop;
    application/x-shockwave-flash=wine-extension-mfp.desktop;
    application/x-wine-extension-hlp=wine-extension-hlp.desktop;
    application/x-wine-extension-idb=wine-extension-idb.desktop;
    application/x-wine-extension-ini=wine-extension-ini.desktop;
    application/x-wine-extension-msp=wine-extension-msp.desktop;
    application/x-wine-extension-rom=wine-extension-rom.desktop;
    application/x-wine-extension-vbs=wine-extension-vbs.desktop;
    application/xml=wine-extension-xml.desktop;
    image/gif=wine-extension-gif.desktop;
    image/jpeg=wine-extension-jpg.desktop;wine-extension-jpe.desktop;wine-extension-jfif.desktop;wine-extension-jpeg$
    image/png=wine-extension-png.desktop;
    The 'x-wine-extension' ones are fine but now we have gif and jpeg defined as opening via WINE. WTF?

  6. #6
    Join Date
    Jun 2007
    Location
    Lytham St Annes, Lancashire, UK
    Posts
    687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    "rpm -q --scripts gimp" shows that on installing and uninstalling Gimp the program "update-desktop-database" is used to update the mime-types. The manual page for this program has the following Note:
    The order of the desktop files found for a MIME type is not significant. Therefore, an external mechanism must be used to determine what is the preferred desktop file for a MIME type.
    Based on that, it looks like this "external mechanism" (such as a user-specific mimeinfo.cache file in the home directory) is not being honoured, at least under LXDE.

  7. #7
    Join Date
    Nov 2009
    Posts
    371
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    Good work, that led me to this:


    https://lkubaski.wordpress.com/2012/...e-and-pcmanfm/


    So what I find is that if I double click a plain text file it it fires up Wine , WTF? So now it get some dumb emulation of a 30y old dumb M$ text editor fired up on my new Fedora Linux system. How dumb is that?

    It still seems to come down to the last man aboard gets to rewrite my user prefs. In fact WINE has spammed that file , which is apparently the top of the preference tree, with a crate load of mimetypes it is now hogging.

    The more I learn, the worse it gets.

  8. #8
    Join Date
    Jun 2007
    Location
    Lytham St Annes, Lancashire, UK
    Posts
    687
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    The mime types in /usr/share/applications/mimeinfo.cache are not your "user" prefs - they are the system's list of all the mime types listed against the "MimeType" parameter in the application ".desktop" files in that directory.

    Your user prefs will need to be logged somewhere under your home directory otherwise all users of a system would have to share the same one set of preferences. For Cinnamon desktop, this is /home/<user>/.local/share/application/mimeinfo.cache. Your link in the previous post says LXDE uses the same location.

    If you only have one program listed against a mime type in /usr/share/applications/mimeinfo.cache, then you have only installed one program that has a ".desktop" file that lists that mime type as being supported.

  9. #9
    Join Date
    Nov 2009
    Posts
    371
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: GIMP dumping on mimetypes

    The mime types in /usr/share/applications/mimeinfo.cache are not your "user" prefs
    Thanks, I did not think they were. The WINE cruft was in the user file ( I've had to clean it out manually since dnf remove wine-core did not remove it ):



    Code:
    cat ~/.local/share/applications/mimeinfo.cache
    [MIME Cache]
    application/rtf=wine-extension-rtf.desktop;
    application/vnd.ms-htmlhelp=wine-extension-chm.desktop;
    application/x-mswinurl=wine-extension-url.desktop;
    application/x-mswrite=wine-extension-wri.desktop;
    application/x-shockwave-flash=wine-extension-mfp.desktop;
    application/x-wine-extension-hlp=wine-extension-hlp.desktop;
    application/x-wine-extension-idb=wine-extension-idb.desktop;
    application/x-wine-extension-ini=wine-extension-ini.desktop;
    application/x-wine-extension-msp=wine-extension-msp.desktop;
    application/x-wine-extension-rom=wine-extension-rom.desktop;
    application/x-wine-extension-vbs=wine-extension-vbs.desktop;
    application/xml=wine-extension-xml.desktop;
    image/gif=wine-extension-gif.desktop;
    image/jpeg=wine-extension-jpg.desktop;wine-extension-jpe.desktop;wine-extension-jfif.desktop;wine-extension-jpeg.desktop;
    image/png=wine-extension-png.desktop;
    message/rfc822=mozilla-thunderbird.desktop;
    text/html=wine-extension-html.desktop;wine-extension-htm.desktop;
    text/plain=wine-extension-txt.desktop;
    x-scheme-handler/mailto=mozilla-thunderbird.desktop;

    That's what I meant about it being at the top of the tree. They are not putting it in as a global pref. but at the user level. In fact, now you mention it I wonder how that works. It can't be part of the dnf installation process which is run as root, so it must be something it does when wine is first run.

    That presumably explains why it does not get cleaned up when wine gets uninstalled.

    This probably needs a bug filing against WINE package, since it leaves broken mimetypes when removed and probably should not be inserting itself ahead of everything thing else at run-time either.

    Hijacking plain-text seems well out of order to start with.
    Last edited by feddy; 2nd March 2016 at 02:59 PM.

Similar Threads

  1. How do I Install GIMP Plugin Registry for GIMP 2.8
    By cobber in forum Using Fedora
    Replies: 3
    Last Post: 31st August 2015, 11:44 AM
  2. Adding mimetypes to Fedora theme
    By selateh98 in forum Using Fedora
    Replies: 0
    Last Post: 15th April 2011, 12:23 AM
  3. Fedora Change KDE mimetypes
    By marcelkraan in forum Using Fedora
    Replies: 0
    Last Post: 15th January 2007, 09:46 AM
  4. no mimetypes in firefox 1.5
    By wpyung in forum Using Fedora
    Replies: 2
    Last Post: 27th November 2006, 11:25 AM

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •