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

count fired on keypress occurs before changes #27

Closed
paul-butcher opened this issue Sep 13, 2013 · 2 comments
Closed

count fired on keypress occurs before changes #27

paul-butcher opened this issue Sep 13, 2013 · 2 comments

Comments

@paul-butcher
Copy link

When pressing a key in the editor, the "key" event fires prior to the text being updated by the corresponding action. This means that the wordcount update is always based on the number of words/characters present before the key was pressed, rather than after.

In the case of simply typing in text, this manifests as a slightly jarring lag, where a new word is not counted until its second character is typed (or some other key event occurs).

However, if a large quantity of text is deleted, (e.g. by selecting with the mouse, and using the delete or backspace keys), the word count can be left drastically wrong, even after focus is lost by the editor.

@w8tcha
Copy link
Owner

w8tcha commented Sep 14, 2013

Are you using the latest version from Github or from the Plugins repository on CKEditor.com? I can not reproduce this with the latest version from github

@paul-butcher
Copy link
Author

From the plugins repository. Version 1.0.7. I see the problem is related to the commented-out lines starting at 172 editor.on("change"...

These lines have been reinstated in the latest github version.

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

No branches or pull requests

2 participants