Bug 400327 - Trim Margins does not work properly when applied to files opened in different tabs
Summary: Trim Margins does not work properly when applied to files opened in different...
Status: CONFIRMED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 22.04.3
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords: investigated, triaged
Depends on:
Blocks:
 
Reported: 2018-10-26 11:24 UTC by Evgenii
Modified: 2022-07-25 13:07 UTC (History)
2 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 Evgenii 2018-10-26 11:24:00 UTC
SUMMARY
Trim Margins does not work properly when applied to pdf-files opened in different tabs

STEPS TO REPRODUCE
1. Open multiple pdf-files in tabs (e.g. file1.pdf and file2.pdf)
2. Switch to file1.pdf
3. Select View - Trim View - Trim Margins (or just click on a button on a toolbar)
4. Switch to file2.pdf
5. Select View - Trim View - Trim Margins (or just click on a button on a toolbar)
6. Switch back to file1.pdf
7. Unselect View - Trim View - Trim Margins (or just click on a button on a toolbar)

OBSERVED RESULT
After step #5 file2.pdf is not trimmed.
After step #7 file1.pdf remains trimmed.

EXPECTED RESULT
After steps #5 and #7 files to be trimmed and untrimmed respectively.

SOFTWARE VERSIONS

Operating System: Arch Linux 
KDE Plasma Version: 5.14.2
Qt Version: 5.11.2
KDE Frameworks Version: 5.51.0
Kernel Version: 4.14.78-1-lts
OS Type: 64-bit


Operating System: Microsoft Windows 10 Home Single Language 
OS Type: 64-bit
Qt Version: 5.11.2 (built against 5.11.2)
KDE Frameworks Version: 5.50.0
Comment 1 Magnus Aagaard Sørensen 2018-11-17 12:59:36 UTC
Steps taken to triage:

A: With taps
* Set Okular to open files in tabs
* Open file1.pdf and file2.pdf
* Ensure no file has trim enabled
* Trim margins on file1 with View -> Trim View -> Trim Margins
* Observe trim as expected, switch to second tab with file2
* Trim margins on file2 with View -> Trim View -> Trim Margins
* Observe no trim
* Switch to first tab with file1
* Unselect trim margins
* Observe file is still trimmed

B: With windows
* Set okular to not open files in tabs
* Open file1.pdf and file2.pdf
* Ensure no file has trim enabled
* Trim margins on file1 with View -> Trim View -> Trim Margins
* Observe trim as expected, switch to second window with file2
* Trim margins on file2 with View -> Trim View -> Trim Margins
* Observe no trim
* Switch to first window with file1
* Unselect trim margins
* Observe file is still trimmed

In both cases, to re-enable the trim feature, is must be deselected in all open files, and the file which is still trimmed, where it ought to be in default mode, can be returned to the default view by selecting trim margins, and then deselecting it again.

I'm not the developer, updating as part of the Okular Bug Day for the Bugsquad.

Application Version: 1.5.3
KDE Plasma Version: 5.14.3
KDE Frameworks Version: 5.52.0
Qt Version: 5.11.2
Comment 2 postix 2022-07-25 13:07:27 UTC
Can reproduce it on openSUSE TW with Okular 22.04.3