sleemanj / xinha

WYSIWYG HTML Editor Component (turns <textarea> into HTML editors)
http://trac.xinha.org/
Other
13 stars 2 forks source link

auto scroll on enter (Trac #1600) #1600

Closed sleemanj closed 3 years ago

sleemanj commented 11 years ago

Hello, I've found a bug in Xinha. This is how and what happens: Go into HTML mode paste some text in, exit HTML mode click anywhere inside the text, and press enter. '''What is expected to happen:''' move the text following the cursor into a new line. '''What happens:''' it moves the text following the cursor into a new line and ''scrolls down until the new line is the first line in the editor''.

This is very disturbing when you try to write something. This happens on all major browsers: Chrome, Firefox and Opera.

Also on Opera, when I do this xinha also adds from 3 to 7 or more new lines before the newly created line, just like I would press enter multiple times.(I'm not holding the enter key pressed for to long) This happens just in Opera.

Reported by guest, migrated from http://trac.xinha.org/ticket/1600

sleemanj commented 11 years ago

guest changed keywords to enter, auto, scroll, new line

sleemanj commented 11 years ago

ejucovy changed cc to ejucovy

sleemanj commented 11 years ago

1340 improves this behaviour by only scrolling when the cursor is nearly or outside the viewport, in which case it will scroll the viewport to have the cursor nearer the top but not right AT the top

Don't know why I've never come across this behaviour before, maybe I just mostly write smaller texts or use full screen so it can't be scrolling anyway.