Bug 156112 - Footnotes and endnotes can be hyperlinked by drag-and-drop from Navigator, but link is not functional
Summary: Footnotes and endnotes can be hyperlinked by drag-and-drop from Navigator, bu...
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.3.0.0 alpha0+
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:24.2.0 target:7.6.0.0.beta2
Keywords: implementationError
Depends on:
Blocks: Navigator Footnote-Endnote
  Show dependency treegraph
 
Reported: 2023-06-30 23:23 UTC by Stéphane Guillou (stragu)
Modified: 2023-07-04 19:08 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:


Attachments
sample ODT with useless hyperlinks (32.54 KB, application/vnd.oasis.opendocument.text)
2023-06-30 23:23 UTC, Stéphane Guillou (stragu)
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Stéphane Guillou (stragu) 2023-06-30 23:23:48 UTC
Created attachment 188144 [details]
sample ODT with useless hyperlinks

Steps:
1. Open Writer.
2. Insert > Footnote and Endnote, pick one.
3. Drag and drop the footnote or endnote from the navigator sidebar onto the document (using the "hyperlink" drag mode).

Or see attachment.

Result: hyperlink is inserted but is not functional. It uses the bookmark "#" syntax, and can potentially conflict with bookmark if they share a name.

Expected: not possible to hyperlink by drag and drop (given that they can't be selected in Insert > Hyperlink > Document > Target in Document).

Note that other drag modes "copy" and "link" insert empty sections. Not sure if these are useful at all, given that endnotes and footnotes should only have one anchor. Maybe drag-and-drop should be entirely deactivated for those, like it already is for e.g. comments?

Started in 7.3 with fix for bug 144788, when footnotes and endnotes started being listed in the navigator.
Jim, can you please have a look?

Version: 24.2.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: 3551d18404cb19cdaa8edb170a549f5c5405d0cb
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-AU (en_AU.UTF-8); UI: en-US
Calc: threaded
Comment 1 Jim Raykowski 2023-07-02 03:57:22 UTC
Patch to not allow footnote and endnote dnd:
https://gerrit.libreoffice.org/c/core/+/153855
Comment 2 Commit Notification 2023-07-02 20:47:30 UTC
Jim Raykowski committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/4f9294ec702a82765c04c8652dddec4dda1e6075

tdf#156112 SwNavigator: Disallow footnote and endnote dnd

It will be available in 24.2.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 3 Stéphane Guillou (stragu) 2023-07-03 08:53:58 UTC
Fix verified in:

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

Thanks for the quick response, Jim! :)
Comment 4 Commit Notification 2023-07-04 19:08:17 UTC
Jim Raykowski committed a patch related to this issue.
It has been pushed to "libreoffice-7-6":

https://git.libreoffice.org/core/commit/3813aa6c8306fce85bb9b9d090ee48766ae87653

tdf#156112 SwNavigator: Disallow footnote and endnote dnd

It will be available in 7.6.0.0.beta2.

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.