Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Selecting a word with double click also selects one leading newline character #5867

Closed
Tsourdox opened this issue Sep 6, 2019 · 2 comments · Fixed by #6011
Closed

Selecting a word with double click also selects one leading newline character #5867

Tsourdox opened this issue Sep 6, 2019 · 2 comments · Fixed by #6011
Milestone

Comments

@Tsourdox
Copy link

Tsourdox commented Sep 6, 2019

Version

2.7.0

Test Case

http://jsfiddle.net/79ubyp1a/

Information about environment

All it seems

Steps to reproduce

Create a texbox and enter two words with a newline character in between so second word ends up on a new row. Now select the second word by double clicking that word (and remove it to see the effect of this).

Expected Behavior

Only the word is selected so that the cursor stays on the second row when removed.

Actual Behavior

The word (including the newline char) is selected which puts the cursor is back on the top row when removing/replacing what's selected.

(This does not happen if you click and drag to select the second word)

@asturur
Copy link
Member

asturur commented Sep 19, 2019

Hi @Tsourdox the fiddle posted works correctly in chrome.
You open the issue quoting version 2.7.0 but the fiddle is build on latest master ( 3.4.0 ).
Is that a typo? are you referring to 2.7.0 or 3.4.0?

@eldstrom
Copy link

eldstrom commented Nov 29, 2019

@asturur I work on the same project as Tsourdox and i can reproduce the problem in the fiddle by just doubleclicking on the last word. It is more obvious if you put a blank line in between the two words.
Double click on last lines word gives this marking
image

Have reproduced it also in our own product thats using FabricJS 3.4.0
When this bugg was created here in Github we were running 2.7.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants