pkgsrc-Bugs archive

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

Re: pkg/53541: gimp hijacks pdfs



The following reply was made to PR pkg/53541; it has been noted by GNATS.

From: Leonardo Taccari <leot%NetBSD.org@localhost>
To: gnats-bugs%NetBSD.org@localhost
Cc: 
Subject: Re: pkg/53541: gimp hijacks pdfs
Date: Fri, 31 Aug 2018 17:13:22 +0200

 Hello David,
 
 dholland%NetBSD.org@localhost writes:
 > [...]
 > Building the latest gimp (or, maybe, one of the dozen or two new
 > things it depends on) did something that causes seamonkey, and
 > probably firefox as well, to always open pdf downloads in gimp without
 > asking what to do. This means the only way to actually *download* a
 > pdf is to wait for gimp to start (which takes ages), then fetch the
 > file by hand out of /tmp/mozilla_*, where hopefully (a) it didn't fill
 > /tmp, (b) has a recognizable name, and (c) hasn't been garbaged by
 > gimp.
 >
 > This kind of hijacking is entirely unacceptable. This would be true
 > even if gimp were a pdf viewer.
 >
 
 AFAIK (at least for www/firefox52 but I think that www/seamonkey
 is similar) this is handled via `~/.mozilla/firefox/<profile/mimeType.rdf'.
 
 Can you please try to `mv mimeType.rdf mimeType.rdf.bak' or similar
 and see if this avoid automatically open the PDF without prior
 asking to download?
 
 
 Thanks!
 
 > It seems that the file /usr/pkg/share/applications/mimeinfo.cache
 > contains the line
 > 	 application/pdf=gimp.desktop;
 > but it's not clear to me what this specifically means or why it would
 > suddenly cause this behavior if it hasn't in the past.
 > [...]
 
 (The following is probably mostly unrelated to the issue, so feel
 free to ignore it! :))
 
 I'm not sure if mimeinfo.cache is directly honored or not but I
 think all `MimeType=' in *.desktop files are. E.g. ktruss-ing
 `xdg-mime':
 
  % xdg-mime query default 'video/x-theora'
  mpv.desktop
 
 show that all *.desktop files are opened.
 Unfortunately, I think that there is not any "prority" or similar
 so if `gimp' is automa{g,t}ically picked up for application/pdf
 the only way to override that and use a different PDF viewer is to
 adjust ~/.local/share/applications/defaults.list. E.g. here I have (I
 will just trim it to a single entry, all other lines are similar):
 
  % cat ~/.local/share/applications/defaults.list
  [Default Applications]
  application/pdf=mupdf.desktop;
 
 and - because mupdf does not provide any .desktop file I have added one:
 
  % cat ~/.local/share/applications/mupdf.list
  [Desktop Entry]
  Version=1.0
  Encoding=UTF-8
  Type=Application
  Name=mupdf
  NoDisplay=true
  Exec=mupdf
 


Home | Main Index | Thread Index | Old Index