Bug 99912 - Writer creates a new hyperlink when proofing hyperlink text
Summary: Writer creates a new hyperlink when proofing hyperlink text
Status: RESOLVED DUPLICATE of bug 148198
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
3.6.0.4 release
Hardware: All All
: medium minor
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: notBibisectable, regression
Depends on:
Blocks: Hyperlink
  Show dependency treegraph
 
Reported: 2016-05-17 14:38 UTC by Nicolas Mailhot
Modified: 2022-07-11 20:50 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Nicolas Mailhot 2016-05-17 14:38:50 UTC
When one changes the displayed text of hyperlinks in the wysiwyg interface, writer creates new additional hyperlinks instead of fixing old ones.

For example:
1. create an hyperlink on the word smart
2. add an s to smart → smarts in the editing window
3. look in the navigator: you now have a "smart" hyperlink and a "s" hyperlink with the same target

Writer should extend the existing hyperlink instead of adding new ones

Writer should automerge consecutive runs of text with the same hyperlink target in a single hyperlink
Comment 1 Buovjaga 2016-05-18 10:09:10 UTC
Me no repro.

In step 2 I edit the link.

Win 7 Pro 64-bit, Version: 5.1.3.2 (x64)
Build ID: 644e4637d1d8544fd9f56425bd6cec110e49301b
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
Locale: fi-FI (fi_FI)

Version: 5.2.0.0.alpha1+
Build ID: f688acfdae00ebdd891737e533d54368810185e1
CPU Threads: 4; OS Version: Windows 6.1; UI Render: default; 
TinderBox: Win-x86@62-merge-TDF, Branch:MASTER, Time: 2016-05-18_00:11:31
Locale: fi-FI (fi_FI)
Comment 2 Nicolas Mailhot 2016-05-18 12:59:12 UTC
To be honest I don't really know what causes writer to cut links in small bits, but you have some example of the result in 
https://bugs.documentfoundation.org/attachment.cgi?id=125012

(look at the one-letter hyperlinks in the navigator, be aware writer takes a long time to open the file)
Comment 3 Buovjaga 2016-05-20 10:52:15 UTC
No repro on Linux either.

Nicolas: so you reproduce this with a completely new document as well?

Arch Linux 64-bit, KDE Plasma 5
Version: 5.2.0.0.alpha1+
Build ID: 6c785f65ea5cc961c0a079455973f3086731b2c9
CPU Threads: 8; OS Version: Linux 4.5; UI Render: default; 
Locale: fi-FI (fi_FI.UTF-8)
Built on May 20th 2016
Comment 4 Stanislav Horacek 2016-05-20 15:46:47 UTC
I am able to reproduce the fragmentation with the following steps:
1. Open a new text document.
2. Type the words "twenty-six dog and cat" into it.
3. Select the whole text and add a hyperlink to it (Insert - Hyperlink, e.g. "http://libreoffice.org").
4. Save the document.
5. Change the text to "twenty-seven dogs and cats" - i.e. replace "ix" by "even", add "s" after "dog" and place cursor after "cat", type "ts" and remove "s".
6. Save and close the document.
7. Reopen the document -> the hyperlink is fragmented to "twenty-s", "even", " dogs ", " and ca" and "ts".

Tested and observed in: 5.2 master (2016-05-19), 5.1.3, 5.0.5 (Ubuntu 15.10), 4.4.5, 4.2.6, 4.0.6, 3.6.5 (Windows 7).
NOT observed in 3.5.4 (Windows 7) -> seems to be a regression between 3.5 and 3.6.
Comment 5 Buovjaga 2016-05-20 16:36:09 UTC
Nicolas: is comment 4 how you did it?
I was doing the editing in the hyperlink editing dialog, not in the text itself.

I can reproduce with steps in comment 4.

Let's set to NEW, then.

Arch Linux 64-bit, KDE Plasma 5
Version: 5.2.0.0.alpha1+
Build ID: 6c785f65ea5cc961c0a079455973f3086731b2c9
CPU Threads: 8; OS Version: Linux 4.5; UI Render: default; 
Locale: fi-FI (fi_FI.UTF-8)
Built on May 20th 2016
Comment 6 Nicolas Mailhot 2016-05-20 18:17:19 UTC
Can't say if I did it exactly this way, but I do edit text including links in the main screen
Comment 7 QA Administrators 2017-05-22 13:39:32 UTC Comment hidden (obsolete)
Comment 8 Stanislav Horacek 2017-11-21 18:56:16 UTC
Still reproducible in: Version: 6.0.0.0.alpha0+
Build ID: 141fe1c5e7fbf67a083b34e49e19b6ea78a0eb2b
Comment 9 Buovjaga 2018-06-28 14:32:09 UTC
Bibisecting on Linux with 43all I get this massive range, which is pretty useless (Feb 6 2012 to Dec 12 2011): https://cgit.freedesktop.org/libreoffice/core/log/?qt=range&q=ce97851773a06103504972eb2771eecd7dd81e36...43c7830b03d141ae11d8617c0fdabefa32dd243c&ofs=550

(In reply to Stanislav Horacek from comment #4)
> 5. Change the text to "twenty-seven dogs and cats" - i.e. replace "ix" by
> "even", add "s" after "dog" and place cursor after "cat", type "ts" and
> remove "s".

This should read: place cursor before the "t" in cat, type "ts" and remove the "t" from the end.

Reminder for testers: check the links in Navigator
Comment 10 QA Administrators 2019-06-29 02:58:02 UTC Comment hidden (obsolete)
Comment 11 Aron Budea 2020-04-05 05:40:11 UTC
(In reply to Buovjaga from comment #9)
> Bibisecting on Linux with 43all I get this massive range, which is pretty
> useless (Feb 6 2012 to Dec 12 2011):
Let's use keyword notBibisectable, then.

Still occurs with 7.0.0.0.alpha0+ (aa191f35978ea48bbacc0e613ae8f0e6536ebcfc).
Comment 12 QA Administrators 2022-04-06 03:45:40 UTC Comment hidden (obsolete)
Comment 13 Mike Kaganski 2022-07-11 13:38:33 UTC

*** This bug has been marked as a duplicate of bug 148198 ***
Comment 14 Stanislav Horacek 2022-07-11 20:06:15 UTC
Just wondering - shouldn't be new duplicates closed in favor of the older issues? For instance, here we have information about regression and "not bibisectable" which is missing in the new one.
Comment 15 Mike Kaganski 2022-07-11 20:39:32 UTC
(In reply to Stanislav Horacek from comment #14)
> Just wondering - shouldn't be new duplicates closed in favor of the older
> issues?

Not always. 

> For instance, here we have information about regression and "not
> bibisectable" which is missing in the new one.

... And in the other one there is

> It was introduced in
>  https://git.libreoffice.org/core/+/062eaeffe7cb986255063bb9b0a5f3fb3fc8e34c
> in 2011 (for version 3.6); then it was made optional in version 5.0 [1].
Comment 16 Mike Kaganski 2022-07-11 20:50:04 UTC
Also - this is not a regression, strictly speaking. In 3.6, a special character property was introduced (rsid) helping comparing document versions. But the real problem was already there long before, inherited from OOo, that any different character formatting of parts of a link splits the link. So the rsids applied now during edits behaves the same way as if you marked part of the link with italics (see another duplicate bug 149949). Or - say, if you add a new property like 3d character, and mark parts of links with that new property, it would split the link the same way, with the same "regression" logic.