Bug 339651 - right-clicking on the last word in a sentence clears the squiggly lines
Summary: right-clicking on the last word in a sentence clears the squiggly lines
Status: RESOLVED FIXED
Alias: None
Product: frameworks-sonnet
Classification: Frameworks and Libraries
Component: general (show other bugs)
Version: unspecified
Platform: Other Other
: NOR major
Target Milestone: ---
Assignee: Martin Sandsmark
URL:
Keywords:
: 340442 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-10-03 19:13 UTC by Martin Sandsmark
Modified: 2023-03-28 17:57 UTC (History)
3 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Sandsmark 2014-10-03 19:13:38 UTC
if you right click on the last word in the first sentence in a qtextedit it clears the red squigglies.

Reproducible: Always

Steps to Reproduce:
1. type in "foo foo."
2. right click on the last foo.
3. bam.
Comment 1 Andrew Crouthamel 2018-11-12 02:58:07 UTC
Dear Bug Submitter,

This bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? I am setting the status to NEEDSINFO pending your response, please change the Status back to REPORTED when you respond.

Thank you for helping us make KDE software even better for everyone!
Comment 2 Andrew Crouthamel 2018-11-21 04:34:49 UTC
Dear Bug Submitter,

This is a reminder that this bug has been stagnant for a long time. Could you help us out and re-test if the bug is valid in the latest version? This bug will be moved back to REPORTED Status for manual review later, which may take a while. If you are able to, please lend us a hand.

Thank you for helping us make KDE software even better for everyone!
Comment 3 Ahmad Samir 2018-12-28 06:35:07 UTC
*** Bug 340442 has been marked as a duplicate of this bug. ***
Comment 4 Ahmad Samir 2018-12-28 06:35:40 UTC
Comment from the other bug report:
"Still happens with KF 5.52".
Comment 5 David Faure 2019-01-02 09:02:29 UTC
Transferring some information from bug 340442 :

Steps to Reproduce:
1. Start textedit example from sonnet/examples
2. Select all in the bottom textedit (or the top one, doesn't matter)
3. Type "abc abc." (without the quotes).
4. Right-click on the second abc

Actual Results:  
The underlines disappear on both words.

Expected Results:  
The underlines should stay :)

Note that this only happens with the final dot.

(So maybe this is due to the formatting of the last character being applied?)
Comment 6 Bug Janitor Service 2022-05-30 20:28:08 UTC
A possibly relevant merge request was started @ https://invent.kde.org/frameworks/sonnet/-/merge_requests/54
Comment 7 Christoph Cullmann 2023-03-28 17:57:59 UTC
Git commit a10499f7a56e88e8b5cccda20314a4f9a4cda0de by Christoph Cullmann, on behalf of loh tar.
Committed on 28/03/2023 at 17:57.
Pushed by cullmann into branch 'master'.

Remove obscure cursor magic

These calculations looks like an attempt to do some optimizations but
they have no further consequences. It's always the whole passed text
new highlighted.

And in this bug-case is "index = lengthPosition" and nothing will
highlighted.

- Code is not yet reformatted (to my surprise no complain at commit)
- Start textedit example from sonnet/examples
- It's enough to add/remove a char in upper text box after "Whih." and call the context menu

M  +0    -12   src/ui/highlighter.cpp

https://invent.kde.org/frameworks/sonnet/commit/a10499f7a56e88e8b5cccda20314a4f9a4cda0de