https://bugs.kde.org/show_bug.cgi?id=451226

            Bug ID: 451226
           Summary: No thumbnail for EPUB3 files
           Product: kio-extras
           Version: 21.12.3
          Platform: Archlinux Packages
                OS: Linux
            Status: REPORTED
          Severity: normal
          Priority: NOR
         Component: Thumbnails and previews
          Assignee: plasma-b...@kde.org
          Reporter: ecthel...@o2.pl
  Target Milestone: ---

The thumbnailer for Epub 3.0 does not work properly. The file from IDPF (the
spec creators) has no cover in Dolphin, even though one is in the file:
https://github.com/IDPF/epub3-samples/releases/download/20170606/epub30-spec.epub

STEPS TO REPRODUCE
1. Put the file into Dolphin
2. Enable previews

OBSERVED RESULT

Generic file icon

EXPECTED RESULT

Cover from the EPUB file itself.

SOFTWARE/OS VERSIONS
Windows: 
macOS: 
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.24.2
KDE Frameworks Version: 5.91.0
Qt Version: 5.15.3

ADDITIONAL INFORMATION

I have done some debugging using the code from
https://github.com/KDE/kio-extras/blob/master/thumbnail/ebookcreator.cpp

It seems that coverHref is found properly here:

https://github.com/KDE/kio-extras/blob/20f476fabfc3f5c50e514c075cea429f62f59652/thumbnail/ebookcreator.cpp#L157

But then the break on the next line skips the assignment itemHrefs[id] = href
(this is ok, as we have already found the proper cover file).

Nonetheless, in the end, it's the (now broken) itemHrefs map that is used as
the source for final coverHref, not the coverHref variable that was
meticulously found before:

https://github.com/KDE/kio-extras/blob/20f476fabfc3f5c50e514c075cea429f62f59652/thumbnail/ebookcreator.cpp#L203

I suppose that line 203 should rather read:

QByteArray encoded = coverHref.toUtf8();

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to