Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(feh): deassociate with xcf, pdf, dvi, txt #1224

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Maelan
Copy link
Contributor

@Maelan Maelan commented Jun 23, 2024

See commit message.

As of feh 3.10, some formats are handled by feh out-of-the-box
(by the Imlib2 library), and some other formats can be opened by
providing the option `--conversion-timeout` which falls back to
ImageMagick’s `convert` utility.

- opening *.svg works out-of-the-box;
- opening *.svgz works through ImageMagick;
- opening *.xcf (Gimp vectorial image) is mentioned in feh’s manpage
  but I have been unable to open any such file;
- I could not test *.cdr (CorelDRAW vectorial image)
  but I would doubt it works better than *.xcf;
- opening *.otf, *.ttf (font files) works through ImageMagick;
- opening *.eps works through ImageMagick;
- opening *.ps, *.pdf, *.dvi (document files) works through ImageMagick,
  but only when the document contains a single page;
  + PDF and DVI are primarily used for possibly-multipage textual
    documents, PDF viewers are widely available and they are much better
    for this purpose than an image viewer that first converts documents
    to bitmaps; it’s unlikely that a user wants to use feh for these.
  + PS, albeit similar in function to PDF, is often used for single-page
    graphics such as logos; EPS is a restriction of PS to only one page.
- opening *.txt does not work and makes no sense.

Hence the rationale for not suggesting *.xcf, *.pdf, *.dvi, *.txt .
*.cdr may also be removed if one is able to try it first.

It’s not uncommon to have homonym files side by side, differing only by
extension, *.jpg and *.pdf (e.g. scanned documents) or *.png and *.xcf
(rendered image and work-in-progress design with Gimp).

This is a partial revert of 63574c8 (from 12 years ago).
@akinomyoga
Copy link
Collaborator

- opening *.xcf (Gimp vectorial image) is mentioned in feh’s manpage
  but I have been unable to open any such file;

What is the problem in this case? According to the man page, it seems to use ImageMagick for .xcf when it is enabled by --conversion-timeout. There are many possibilities:

  • ImageMagick stopped supporting .xcf after the corresponding part of the man page of feh was written. In this case, we can drop .xcf from the list.
  • ImageMagick needs a special configuration to open .xcf. In this case, some users may set it up, so I'm not sure if we should simply drop it.
  • ImageMagick works, but feh cannot use the result of ImageMagick for some reason. In this case, maybe we should ask the upstream feh about whether this is intentional.
- opening *.ps, *.pdf, *.dvi (document files) works through ImageMagick,
  but only when the document contains a single page;
  + PDF and DVI are primarily used for possibly-multipage textual
    documents, PDF viewers are widely available and they are much better
    for this purpose than an image viewer that first converts documents
    to bitmaps; it’s unlikely that a user wants to use feh for these.

Is it? The images that will be embedded in PDFs are usually generated as single-page PDFs. I always create plots in academic papers as single-page PDFs. Although I'm not a user of feh, I'm not sure if we can easily conclude that no users use feh to preview images in the form of single-page PDFs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants