Bug 310227 - Okular does not open TGA files if libqtga.so is present
Summary: Okular does not open TGA files if libqtga.so is present
Status: RESOLVED UPSTREAM
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 0.15.2
Platform: Ubuntu Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-16 20:21 UTC by Sergiu Bivol
Modified: 2012-11-17 15:09 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
Test file (365.64 KB, application/octet-stream)
2012-11-17 00:43 UTC, Sergiu Bivol
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Sergiu Bivol 2012-11-16 20:21:13 UTC
Okular does not open TGA files unless libqtga.so is removed from the system.

Reproducible: Always

Steps to Reproduce:
Try to open a TGA image in Kubuntu 12.10 with Okular.
Actual Results:  
Okular throws an error window: "Could not open /tmp/logo.tga"
Another error is in the Okular main window: "Unable to load document: Unable to read image data"

Expected Results:  
Okular would open the image.

I have the same problem with Gwenview.
I suspect it is the fault of Qt's libqtga.so, because KDE's kimg_tga.so work reliably for both Okular and Gwenview.

I'm reporting the bug in Okular since I believe it should try all the plugins registered for a given image format before giving up with an error.
Comment 1 Albert Astals Cid 2012-11-16 21:36:01 UTC
Can you attach a tga file?
Comment 2 Sergiu Bivol 2012-11-17 00:43:14 UTC
Created attachment 75307 [details]
Test file

Added a sample TGA file, as requested.
Comment 3 Bogdan Cristea 2012-11-17 07:58:12 UTC
okular 0.15.70 opens this file
Comment 4 Bogdan Cristea 2012-11-17 10:57:46 UTC
sorry, I have forgotten to check for qtga library existence. On my system, openSUSE 12.2, where libqtga.so is present, the attached file cannot be opened.
Comment 5 Albert Astals Cid 2012-11-17 14:15:51 UTC
Which package provides libtga.so for you?
Comment 6 Sergiu Bivol 2012-11-17 14:35:19 UTC
It's libqtgui4 (version 4.8.3) that provides libqtga.so.

~$ dpkg -S /usr/lib/x86_64-linux-gnu/qt4/plugins/imageformats/libqtga.so
libqtgui4:amd64: /usr/lib/x86_64-linux-gnu/qt4/plugins/imageformats/libqtga.so

~$ dpkg --status libqtgui4:amd64
Package: libqtgui4
Status: install ok installed
Priority: optional
Section: libs
Installed-Size: 12343
Maintainer: Kubuntu Developers <kubuntu-devel@lists.ubuntu.com>
Architecture: amd64
Multi-Arch: same
Source: qt4-x11
Version: 4:4.8.3+dfsg-0ubuntu3
Comment 7 Albert Astals Cid 2012-11-17 15:09:33 UTC
Qt does not have a way to specify which plugin to use to use for loading a QImage so this is QImageReaders fault for not trying will all the plugins (Besides the tga plugin for not loading the image)

I suggest you report this bug at https://bugreports.qt-project.org