Bug 146575 - Writer won't export hyperlinks to pdf
Summary: Writer won't export hyperlinks to pdf
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
5.4.0.3 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: bibisected, bisected, filter:pdf, regression
: 152210 (view as bug list)
Depends on:
Blocks: PDF-Export Hyperlink
  Show dependency treegraph
 
Reported: 2022-01-04 23:06 UTC by Bob Hurt
Modified: 2024-03-15 03:20 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
source odt file with links (18.20 KB, application/vnd.oasis.opendocument.text)
2022-01-05 18:41 UTC, Bob Hurt
Details
output pdf file, contains no hyperlinks (90.48 KB, application/pdf)
2022-01-05 18:42 UTC, Bob Hurt
Details
The source docx file with the 2 first links having an InternetLink rStyle run property (10.37 KB, application/vnd.openxmlformats-officedocument.wordprocessingml.document)
2022-04-05 08:54 UTC, Simon Gaeremynck
Details
The pdf conversion for the above docx where the first 2 links have an InternetStyle rStyle run property (29.62 KB, application/pdf)
2022-04-05 08:54 UTC, Simon Gaeremynck
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Bob Hurt 2022-01-04 23:06:10 UTC
My writer document contains hyperlinks to various web sites.  Export to pdf does not export the hyperlinks, no matter what options I select in the links dialogue.  A previous version worked fine.  This one does not (7.2.4.1).
Comment 1 m_a_riosv 2022-01-05 16:04:30 UTC Comment hidden (obsolete)
Comment 2 Bob Hurt 2022-01-05 18:41:11 UTC
Created attachment 177333 [details]
source odt file with links
Comment 3 Bob Hurt 2022-01-05 18:42:40 UTC
Created attachment 177334 [details]
output pdf file, contains no hyperlinks
Comment 4 QA Administrators 2022-01-06 03:46:17 UTC Comment hidden (obsolete)
Comment 5 Timur 2022-01-11 10:01:08 UTC
It worked long ago. No repro 5.3.0. Repro LO 5.4 and 7.4+.

Linux-54
commit 6f5d6484fd8ffcc41829cd5ccb5017e7c749fe02
Date:   Wed Apr 26 03:10:33 2017 +0200
    source 157013219230f251346a5aa662c39d02f15420ec
    pre 4e3d14deb74c57632db57663d2fc2ead9d8aa0f0

author	Michael Stahl <mstahl@redhat.com>	2017-04-21
commit 157013219230f251346a5aa662c39d02f15420ec (patch)
tdf#107211 sw: ODF import: add a horrible hack to import "Default"
... character style for hyperlinks and index-entry-templates.
Comment 6 Bob Hurt 2022-01-11 17:33:16 UTC
I ran the portable version of writer, and discovered that it saves links into the exported pdf file with default settings.  I'll use the portable version from now on.
Comment 7 Timur 2022-01-17 10:49:56 UTC
Adding Michael here per bibisect result. Please see.
Comment 8 Simon Gaeremynck 2022-04-05 08:53:22 UTC Comment hidden (off-topic)
Comment 9 Simon Gaeremynck 2022-04-05 08:54:13 UTC Comment hidden (off-topic)
Comment 10 Simon Gaeremynck 2022-04-05 08:54:58 UTC Comment hidden (off-topic)
Comment 11 m_a_riosv 2022-11-26 22:48:19 UTC
*** Bug 152210 has been marked as a duplicate of this bug. ***
Comment 12 Yann Salmon 2023-01-08 10:58:07 UTC
Still present in 7.3.7.2.
Comment 13 sdc.blanco 2023-02-28 00:10:34 UTC
Works for me.... (with Windows OS and Adobe Reader)

Version: 7.2.7.2 (x64) / LibreOffice Community
Build ID: 8d71d29d553c0f7dcbfa38fbfda25ee34cce99a2
CPU threads: 8; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: da-DK (da_DK); UI: en-US
Calc: CL

also 

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: c41e872ed248f804249ecf4d65c4afc2e426e329
CPU threads: 8; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: da-DK (da_DK); UI: en-US
Calc: CL threaded


Is this linux-specific?  (reports here do not identify OS)
Comment 14 Gabor Kelemen (allotropia) 2023-03-02 13:28:36 UTC
(In reply to sdc.blanco from comment #13)
> Works for me.... (with Windows OS and Adobe Reader)
> 
> Version: 7.2.7.2 (x64) / LibreOffice Community
> Build ID: 8d71d29d553c0f7dcbfa38fbfda25ee34cce99a2
> CPU threads: 8; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL:
> win
> Locale: da-DK (da_DK); UI: en-US
> Calc: CL
> 
> also 
> 
> Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
> Build ID: c41e872ed248f804249ecf4d65c4afc2e426e329
> CPU threads: 8; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL:
> win
> Locale: da-DK (da_DK); UI: en-US
> Calc: CL threaded
> 
> 
> Is this linux-specific?  (reports here do not identify OS)

Still a problem for me with:

Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 4f7e8f0d819383a6953ccbb53f704d2265577a2f
CPU threads: 14; OS: Windows 10.0 Build 19045; UI render: Skia/Raster; VCL: win
Locale: en-US (hu_HU); UI: en-US
Calc: threaded

With the first example file none of the links are clickable.
With the second example file the first two links are clickable, the rest are not.
Comment 15 sdc.blanco 2023-03-02 14:07:07 UTC
(In reply to Gabor Kelemen (allotropia) from comment #14)
> With the first example file none of the links are clickable.
Further observations with first example file (attachment 177333 [details])

1. Navigator does not show any hyperlinks for this .odt file, even though it is 
   possible to use Crtl+click with them.
2. Added an external hyperlink to list in .odt file (and exported to PDF).
   Actual:  No links worked (i.e., both existing plus the added hyperlink).
3. All the hyperlinks are in an ordered list. 
   Removed the list formatting from all the links and exported.
   Actual:  Added hyperlink (which also appears in Navigator) worked.
            The others did not.

Tentative hypotheses (based on these tests):

1. One problem may be that hyperlinks with list numbering are not being exported (because the new/added hyperlink, was not exported when in the numbered list, but was exported when it was not in a numbered list).

2. A second possible problem may be related to the fact that the hyperlinks in the example file do not appear in Navigator (with or without list formatting). (i.e., the lack of appearance is not the cause, only a symptom). 
Also, according to Style Inspector, these hyperlinks have, as part of Character Direct Formatting, a "Visited Char Style Name" and "Unvisited Char Style" name called "Standard", which could not removed with Ctrl+M, while the new hyperlink had the values "Visited Internet Link" and "Internet Link".

Tested with 7.2.7.2 (Windows) and Adobe Reader.
Comment 16 sdc.blanco 2023-03-02 14:12:55 UTC Comment hidden (obsolete)
Comment 17 Stéphane Guillou (stragu) 2024-03-15 03:19:37 UTC
(In reply to Simon Gaeremynck from comment #8)
> I can add another example to this case (style-internet-link.docx and its
> corresponding style-internet-link.pdf).
> I've manually updated the first two links in the document ("learning" and
> "Toyota") and added the following run property style:
>   <w:rStyle w:val="InternetLink" />
> When that style is present, Writer exports the link correctly. When it's
> missing, it does not add the link annotation.
This is a different issue, a regression in version 6.3 that is tracked in bug 142133 and has a fix coming for version 24.2.3. You can test with a daily build if you want.

The issue with the original attachment 177333 [details], I can still reproduce in a recent trunk build:

Version: 24.8.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: c8b8a2c2cb34a1ae0b0aeee0564b39260258f184
CPU threads: 8; OS: Linux 6.5; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: CL threaded

I note that editing the hyperlink > not changing anything in the dialog > applying does fix the issue.

Xisco, copying you in just in case you are interested. (Michael un-CCed himself.)