Bug 45949 - SPELL check does not work for words with hyperlink
Summary: SPELL check does not work for words with hyperlink
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Linguistic (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: Other Windows (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard: target:7.6.0 target:7.5.0.0.beta2
Keywords:
Depends on:
Blocks: Spell-Checking Hyperlink
  Show dependency treegraph
 
Reported: 2012-02-12 00:40 UTC by Rainer Bielefeld Retired
Modified: 2023-02-02 07:45 UTC (History)
4 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
Sample Document. (10.44 KB, application/vnd.oasis.opendocument.text)
2012-02-12 00:40 UTC, Rainer Bielefeld Retired
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Bielefeld Retired 2012-02-12 00:40:54 UTC
Created attachment 56908 [details]
Sample Document.

Steps to reproduce with "LibreOffice 3.4.5 German UI [Build ID: OOO340m1 (Build:502)]" parallel Server installation on German WIN7 Home Premium (64bit).

1. open a WRITER document with misspelled words containing a hyperlink, for 
   example attached sample.odt
2. Run spell check with <f7>
   Expected: spell check should indicate misspelled words and allow correction
   Actual: only misspelled words without hyperlink will be recognized and can be
           corrected

Also auto spell check has problems. When you add a hyperlink to a misspelled word the red wavy underline remains, but when you close / reopen the document the misspelled words will no longer be indicated.

I use LT Language Tool extension, but I think the problem also will appear with the default spell check.

[Reproducible] with "LibreOffice Portable 3.3.0  - WIN7  Home Premium (64bit) German UI [OOO330m19 (Build:6) tag libreoffice-3.3.0.4]", seems inherited from OOo.
Comment 1 Rainer Bielefeld Retired 2012-02-12 00:48:49 UTC
NEW due to AOOo Issue.

BTW, worked fine with OOo 1.1.4
Comment 2 QA Administrators 2014-10-24 03:18:20 UTC Comment hidden (noise)
Comment 3 tommy27 2015-08-23 09:15:47 UTC
still reproducible with LibO 4.4.5.1 and 5.0.0.4 under Win8.1 x64
Comment 4 QA Administrators 2016-09-20 10:26:13 UTC Comment hidden (noise, obsolete)
Comment 5 Thomas Lendo 2017-06-06 22:11:00 UTC
Reproduces with Version: 5.5.0.0.alpha0+
Build-ID: 200a566cf106fc724b99c373f16da0058163b28d
CPU-Threads: 4; Betriebssystem:Linux 4.8; UI-Render: Standard; VCL: gtk2; 
TinderBox: Linux-rpm_deb-x86_64@70-TDF, Branch:master, Time: 2017-06-05_23:01:35
Gebietsschema: de-DE (de_DE.UTF-8); Calc: group
Comment 6 QA Administrators 2018-08-22 02:35:16 UTC Comment hidden (noise, obsolete)
Comment 7 Dieter 2020-04-24 07:25:40 UTC
Still present in

Version: 6.4.3.2 (x64)
Build-ID: 747b5d0ebf89f41c860ec2a39efd7cb15b54f2d8
CPU-Threads: 4; BS: Windows 10.0 Build 18363; UI-Render: Standard; VCL: win; 
Gebietsschema: de-DE (de_DE); UI-Sprache: de-DE
Calc: threaded
Comment 8 utilsites 2020-05-18 14:57:04 UTC
There is also another problem, sometimes after doing spell checker, the hyperlinks are removed from whole word but stays on a leeter for example.
Comment 9 QA Administrators 2022-05-19 03:37:37 UTC Comment hidden (noise, obsolete)
Comment 10 Rainer Bielefeld Retired 2022-05-19 04:52:39 UTC
😥
Comment 11 Christophe Strobbe 2022-05-19 10:45:12 UTC
I confirm this bug using LibreOffice 7.1.4.2 on OpenSUSE:

Version: 7.1.4.2 / LibreOffice Community
Build ID: 10(Build:2)
CPU threads: 8; OS: Linux 5.5; UI render: default; VCL: kf5
Locale: en-GB (en_GB.utf8); UI: en-GB
Calc: threaded

Note that there is a workaround for this: change the language of the hyperlink from "[None]" to an actual language and rerun the spellchecker.

Hyperlinks have their language set to "[None]" by default instead of, e.g., the document language. This has been reported in Bug 39794.
Comment 12 Dieter 2022-05-19 14:58:13 UTC
Still present in

Version: 7.3.3.2 (x64) / LibreOffice Community
Build ID: d1d0ea68f081ee2800a922cac8f79445e4603348
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Raster; VCL: win
Locale: de-DE (de_DE); UI: en-GB
Calc: CL
Comment 13 Commit Notification 2022-12-13 14:43:05 UTC
László Németh committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/71dc8a291ecc5bdae541fce41c8895d6b3302082

tdf#45949 sw: add spell checking to hyperlinked text

It will be available in 7.6.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 14 خالد حسني 2022-12-13 14:45:19 UTC
This was “fixed” for new documents in https://gerrit.libreoffice.org/c/core/+/140958, but it caused the regreddtion in bug 152492.
Comment 15 László Németh 2022-12-13 14:46:05 UTC
Commit description:

tdf#45949 sw: add spell checking to hyperlinked text

Recognize plain words within hyperlinks and
check their spelling.

Not only URLs and e-mail addresses, but plain
text of hyperlinks were removed from spell checking,
which didn't conform to the specification:

"URLs are skipped during spell checking

Spelling of URLs in document doesn't make sense, because the words
are not separated and often they aren't natural words at all.
Since we can only decide what we know, we will only except URLs
from spelling already recognized/formatted as URLs and if the URL
and the text representation are equal."

http://specs.openoffice.org/appwide/linguistic/Spellcheckdialog.sxw,
see also https://bz.apache.org/ooo/show_bug.cgi?id=40133.

Follow-up to commit ec8fdffec29de7c80da0c2a440e467c35a297119
"tdf#152492 sw: fix unwanted spell checking of parts of URLs"
and commit 2cca160f8bfc4597cf0ad3aaaf0017a5210ea0ec
"tdf#126657, tdf#145104: Don’t set language to none on defined
styles".
Comment 16 László Németh 2022-12-13 15:00:09 UTC
Note: Possible improvement: add Check URL option to Language Settings->Writing Aids to check skipped URL parts.
Comment 17 Commit Notification 2022-12-17 15:09:19 UTC
László Németh committed a patch related to this issue.
It has been pushed to "libreoffice-7-5":

https://git.libreoffice.org/core/commit/621e8c413d10fcd1c28573d75d13934e949deb0c

tdf#45949 sw: add spell checking to hyperlinked text

It will be available in 7.5.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.
Comment 18 NISZ LibreOffice Team 2022-12-19 13:26:10 UTC
Verified in:
Version: 7.6.0.0.alpha0+ (X86_64) / LibreOffice Community
Build ID: ad387d5b984c6666906505d25685065f710ed55d
CPU threads: 4; OS: Windows 10.0 Build 19044; UI render: Skia/Vulkan; VCL: win
Locale: hu-HU (hu_HU); UI: en-US
Calc: CL threaded
Comment 19 Mike Kaganski 2023-02-02 07:42:29 UTC
Is there a tracker for other components (Calc, Impress) - since this is fixed for Writer, but its component is Linguistic?
Comment 20 Mike Kaganski 2023-02-02 07:45:19 UTC
(In reply to László Németh from comment #15)
> http://specs.openoffice.org/appwide/linguistic/Spellcheckdialog.sxw,
> see also https://bz.apache.org/ooo/show_bug.cgi?id=40133.

... and these two also talk about general implementations, applicable to all components.