Bug 141340 - Pdf export of pages range adds hyperlinks from previous pages
Summary: Pdf export of pages range adds hyperlinks from previous pages
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
6.4.7.2 release
Hardware: All All
: medium normal
Assignee: Miklos Vajna
URL:
Whiteboard: target:7.4.0 target:7.3.1 target:7.2.6
Keywords: bibisected, bisected, regression
Depends on:
Blocks:
 
Reported: 2021-03-30 10:37 UTC by js2k2
Modified: 2022-01-21 12:12 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Minimal reproducable example: exported PDF (12.07 KB, application/pdf)
2021-03-30 10:39 UTC, js2k2
Details
Minimal reproducable example: odg (10.91 KB, application/vnd.oasis.opendocument.graphics)
2021-03-30 10:40 UTC, js2k2
Details
Screencast of the bug (19.58 MB, video/mp4)
2021-04-27 10:20 UTC, js2k2
Details

Note You need to log in before you can comment on or make changes to this bug.
Description js2k2 2021-03-30 10:37:48 UTC
Description:
The error occurs when exporting e.g. pages 2-3 of the document as PDF. If there is a hyperlink on page two there will be an area you can click on on page three of the exported PDF which opens this hyperlink (which should only be on page 2).

Steps to Reproduce:
1.Create at least three pages
2.Add a text-box to every page
3.The Text Box on page 2 has to contain a hyperlink and some text 
4.File > Export As > Export as PDF > Pages: 2-3

Actual Results:
One the second page of the exported PDF will be an are you can click an which opens the destination of the hyperlink on page 1. This area is not visible until you click on it or hover over it with the cursor.

Expected Results:
This area shouldn't exists


Reproducible: Always


User Profile Reset: Yes



Additional Info:
This area appears in multiple PDF Viewers such as Adobe Acrobat or Firefox.

Version: 7.1.1.2 (x64) / LibreOffice Community
Build ID: fe0b08f4af1bacafe4c7ecc87ce55bb426164676
CPU threads: 6; OS: Windows 10.0 Build 19042; UI render: Skia/Vulkan; VCL: win
Locale: de-DE (de_DE); UI: en-GB
Calc: threaded
Comment 1 js2k2 2021-03-30 10:39:27 UTC
Created attachment 170823 [details]
Minimal reproducable example: exported PDF
Comment 2 js2k2 2021-03-30 10:40:25 UTC
Created attachment 170824 [details]
Minimal reproducable example: odg
Comment 3 Harshita Nag 2021-04-24 05:49:48 UTC
Hello js2k2@gmx.de,

    I cannot reproduce this bug. I used Adobe Reader and Master PDF Editor.
    Please try with these PDF Viewers also and do tell.
    Record a screencast if the problem still occurs.
    

Version: 7.1.1.2 / LibreOffice Community
Build ID: fe0b08f4af1bacafe4c7ecc87ce55bb426164676
CPU threads: 8; OS: Linux 5.3; UI render: default; VCL: gtk3
Locale: en-IN (en_IN); UI: en-US
Calc: threaded
Comment 4 js2k2 2021-04-27 10:20:54 UTC
Created attachment 171448 [details]
Screencast of the bug

The bug still occurs using the lastest version:

Version: 7.1.2.2 (x64) / LibreOffice Community
Build ID: 8a45595d069ef5570103caea1b71cc9d82b2aae4
CPU threads: 6; OS: Windows 10.0 Build 19042; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: de-DE
Calc: threaded
Comment 5 Dmitriy Siushkin 2021-08-02 09:21:09 UTC
repro in 

Version: 7.3.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 7c38362dbe1922c9825dffb463072030948d406b
CPU threads: 4; OS: Windows 10.0 Build 19043; UI render: Skia/Raster; VCL: win
Locale: en-US (ru_RU); UI: en-US
Calc: CL
Comment 6 Timur 2022-01-11 10:21:50 UTC
Most useful, although tedious, is to find if regression and worked before. 
No repro 6.4.0, repro 6.4.7 and 7.4+.
Comment 7 raal 2022-01-16 14:29:33 UTC
This seems to have begun at the below commit.
Adding Cc: to Miklos Vajna; Could you possibly take a look at this one?
Thanks
 16f0a6ec84cd1d50623cb666210ad0e54778a59a is the first bad commit
commit 16f0a6ec84cd1d50623cb666210ad0e54778a59a
Author: Jenkins Build User <tdf@pollux.tdf>
Date:   Tue Mar 10 20:53:11 2020 +0100

    source 01dbb38680aa39a4d3bc7afd05d44a4b2c9bc6ab

https://git.libreoffice.org/core/+/01dbb38680aa39a4d3bc7afd05d44a4b2c9bc6ab
   tdf#61274 sd PDF export: fix links ending up on wrong pages with hidden slides
Comment 8 Commit Notification 2022-01-20 09:52:49 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/31bbaf478783e3a2c21bd3ea94ddf39299a63d1e

tdf#141340 PDF export: fix hyperlinks on the wrong page with page num range

It will be available in 7.4.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 9 Commit Notification 2022-01-20 11:00:41 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-7-3":

https://git.libreoffice.org/core/commit/3d60ad8c67e347f56400e3be05a3f1641f77c719

tdf#141340 PDF export: fix hyperlinks on the wrong page with page num range

It will be available in 7.3.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Commit Notification 2022-01-21 12:12:53 UTC
Miklos Vajna committed a patch related to this issue.
It has been pushed to "libreoffice-7-2":

https://git.libreoffice.org/core/commit/51f5e5fcb64c150f5dd8233b52686e54cdeac399

tdf#141340 PDF export: fix hyperlinks on the wrong page with page num range

It will be available in 7.2.6.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.