Bug 352359 - A really wrong way to retrieve screen resolution for calculating annotation bounding box
Summary: A really wrong way to retrieve screen resolution for calculating annotation b...
Status: RESOLVED WORKSFORME
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 0.21.3
Platform: openSUSE Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-09-06 19:01 UTC by S. Janczewski
Modified: 2024-03-26 02:48 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description S. Janczewski 2015-09-06 19:01:54 UTC
A had a real puzzle with Okular annotation bounding box. I have same software on many computers, and on only one Okular annotations worked incorrectly: the drawn bounding box of the annotations would be always about 4 times taller than necessary.

After a lot of playing with it, I figured out what is wrong (I think). I probably will eventually fix it myself, but probably will not have time to get involved with submitting the fix formally, so someone might want to put it in while doing other fixes.

As you may have noticed some people complained that the bounding box does not work as it should and others cannot reproduce it. Since I think they all bark up the wrong tree, I will describe what I think is going on in a new bug report.

The problem occurs ONLY on a system that overwrites monitor EDID info within xorg.conf with something like this:

Section "Monitor"    
    Option    "UseEdidDpi"  "FALSE"
    Option    "DPI"  "96 x 96"
EndSection

This is a fix for a really tiny font being used if EDID is used to determine proper screen DPI. Some people think it is the problem with video drivers - it isn't. The monitor that pretends to be a very large TV is the problem.  Such monitors return resolution say 1920x1080 and 30 DPI. This is NOT a setting that is usable for use of monitor for a personal computer, and this is why people have to overwrite it in xorg.conf. 
 
The problem with Okular is that it appears someone used get-edid HW call to read in the screen resolution and uses it to calculate proper size of bounding box - in my case - I work with 96x96 and get-edid returns 30x30. This obviously is wrong in many circumstances, because it assumes that high level use of monitor (as in for PDF viewing, for example) always uses the DPI coded in monitor EDID information - which obviously is not true in described circumstances.  

Reproducible: Always

Steps to Reproduce:
1. Find a monitor that returns strange EDID info - say 1920x1080 30 DPI. Verify it with monitor-edid utility, for example.
2. Make such monitor work as a linux screen without tiny fonts
3. On Okular try to draw annotation box with only single line of text.

Actual Results:  
Bounding box intended to be 1 line high ends up to be 5 lines high

Expected Results:  
One line high box - as with the computers that do not have to overwrite EDID dpi. 

Obviously, when okular comes up with ability to allow changing of bounding box size, this new capability will be a workaround. Now - it is not possible to make annotations as needed on computers with such a problem.
Comment 1 Justin Zobel 2020-11-08 03:05:23 UTC
Are you able to please confirm if this issue was resolved with a patch since you originally tried it?
Comment 2 Bug Janitor Service 2020-11-23 04:33:54 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 3 Bug Janitor Service 2020-12-08 04:34:18 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!