3

I have recently changed my Operating System from windows 11 to Ubuntu 20.04. I have transferred the data from my old system. The problem is that Ubuntu is recognising PDF files as images and opening in photo viewer. I have tried by downloading files from the internet too. Even the downloaded files are recognised as images.

When I open the properties of the file its showing like this. When I open the properties of the file its showing like this.

This is the icon shown. This is the icon shown.

The type is shown as Image in file explorer.

This is how its shown in file explorer This is how its shown in file explorer

Edit : Now I have upgraded to 22.04.Still the problem exists.What should I do?

4 Answers 4

7

Open properties of the pdf file.

Then go to the "open with" tab and select Document Viewer or Evince.

7
  • When I upload the same file to google drive its uploading as an image.How should I solve that? and why is it showing image/pdf in properties?
    – epicman25
    Aug 13, 2022 at 5:47
  • 5
    Google Drive has a different file handling protocol. Whatever is happening in Google Drive is not related to your file handling in Ubuntu unless you are changing the file extension before uploading to Google Drive. Please focus on the issue at hand-- telling us about issues in Google Drive is not a relevant response to this answer. If you have a comment on this answer, it should be about the results of using this answer-- not some other problem
    – Nmath
    Aug 13, 2022 at 6:31
  • 2
    Linux is more interested in the content of a file than of its name and extension. An image file will still be seen as an image by Linux, even when renamed with the extension pdf. Check with the command file name.pdf on the problematic file.
    – sudodus
    Aug 13, 2022 at 10:50
  • 1
    I tried it and its showing PDF document, version 1.4.Still the icon is an image icon.
    – epicman25
    Aug 13, 2022 at 12:46
  • 1
    My guess was wrong. Sorry I don't know why this is happening. It does not work like that for me. Sometimes the old trick will fix things: Reboot (maybe worthwhile trying it).
    – sudodus
    Aug 13, 2022 at 13:39
2

Well its kind of my fault.So when I installed Ubuntu I don't know why but photopea got installed.So when I saw its settings,there was a permission for it to access .pdf files also.After uninstalling it problem got solved.

2

I encounter this same issue and I found out it is from Photopea. @epicman25 is right.

When you install Photopea from your browser. It gets permission to access (and modify) image, pdf and text files.

You have to uninstall Photopea from your system through the browser.

  • Go to https://www.photopea.com
  • On the URL address bar, there will be an icon to install / uninstall Photopea (PWA)
  • If it is not installed and you are encountering this issue, install it, so you could remove it properly
  • Now, that it is installed, go back to that icon (on the browser address bar) and uninstall it.
  • When you get a prompt to remove all data from your system, please accept.
  • After this, Photopea will stop accessing and modifying your precious files.

PS: Once you have successfully removed Photopea from your system, you will be able to see an actual preview of new images and pdfs (no longer an image icon).

0

If the solution by John Johnson does not work, try this (worked for me on Ubuntu 22/Google Chrome): In the address bar, type about://apps, look for Photopea, right-click, Remove from Chrome.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .