Bug 465009

Summary: [Feature request] Option to enforce a font for ePUBs despite their own ones
Product: [Applications] okular Reporter: davidkacerek
Component: EPub backendAssignee: Okular developers <okular-devel>
Status: REPORTED ---    
Severity: wishlist CC: davidkacerek
Priority: NOR    
Version First Reported In: 22.12.1   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: openSUSE Leap 15.4 Reference Guide
Pro Git

Description davidkacerek 2023-01-29 21:19:58 UTC
SUMMARY:
The current state of the ePUB backend is to allow for a custom font in the "Configure Backends" window. This however, I've found only works for ePUBs w/o their own embedded fonts and the CSS style declaring the @font-face statement. In such case, my custom font configured in Okular is ignored and the displayed text looks usually worse that e.g. a carefully picked font from the Google Fonts catalog. I'd like the option to enforce my own font despite the ePUB's own embedded & declared one.

STEPS TO REPRODUCE
1. Okular -> Settings -> Configure Backends... -> EPub -> Default Font
2. Open an ePUB w/ its own fonts embedded & declared. You can check it by unpacking the file w/ the 7-Zip archiver for example.
3. Check the difference of the displayed text when switching the default font.

OBSERVED RESULT:
Ugly looking font rendering. No change.

EXPECTED RESULT:
Well rendered font of one's own choosing.

SOFTWARE/OS VERSIONS:
Windows: Windows 10 x64

ADDITIONAL INFORMATION:
Tested on Windows but I suppose it behaves the same on other platform like GNU/Linux where I'd like to see the feature as well.

Thank you.
Comment 1 davidkacerek 2023-01-29 23:06:42 UTC
Created attachment 155773 [details]
openSUSE Leap 15.4 Reference Guide

No fonts embedded or declared. Default font configured in the Okular ePUB backend is honored.
Comment 2 davidkacerek 2023-01-29 23:08:08 UTC
Comment on attachment 155773 [details]
openSUSE Leap 15.4 Reference Guide

No fonts embedded or declared. Default font configured in the Okular ePUB backend is honored.
Comment 3 davidkacerek 2023-01-29 23:13:35 UTC
Created attachment 155774 [details]
Pro Git

Fonts embedded and declared. Default font configured in the Okular ePUB backend is ignored.