Opened 14 years ago

Closed 14 years ago

Last modified 12 years ago

#6147 closed Bug (wontfix)

Page up/page down jump whole document on IE8

Reported by: Steven Wood Owned by:
Priority: Normal Milestone:
Component: General Version: 3.4.1
Keywords: IBM CantFix Cc: Lynne Kues

Description

Using the page up/page down keys jumps from the top of the document all the way to the bottom or vice versa. This only happens on IE8, in IE8 mode.

To reproduce simply create a large document that requires scroll bars place the caret at the beginning and press page down.

Change History (3)

comment:1 Changed 14 years ago by Lynne Kues

You can see the behavior when running the CKEditor demo in IE8.

comment:2 Changed 14 years ago by Frederico Caldeira Knabben

Keywords: CantFix added
Resolution: wontfix
Status: newclosed

I've tested it with a simple page with <body contenteditable="true"> and this is definitely an intrinsic browser bug.

The basic cursor navigation is a feature provided by the browser itself and we have no control of it, so we're not able to fix this issue. All we can do is reporting the issue to Microsoft:
https://connect.microsoft.com/IE/feedback/details/585848/page-down-and-page-up-reacts-improperly-in-editable-document-contenteditable-true#

comment:3 Changed 12 years ago by NicHolt

Agreed. This is an M$ browser "feature" which only occurs when it is contentEditable.

Here's a workaround, in the wysiwygarea plugin. It emulates scrolling up and dowm, rather than Page Up and Page Down - i.e. the caret is NOT moved. However, for those that prefer keystrokes to mouseclicks, it's a huge improvement on the M$ "faeture".

if (env.ie && (env.ie7 || env.ie8)) {
	var docEl = editor.document.$.documentElement;
	var scrTop = docEl.scrollTop;
	var scrHgt = docEl.scrollHeight;
	var winHgt = editor.document.getWindow().getViewPaneSize().height;
	
	if (keyStroke == 33) {  // Page Up
		docEl.scrollTop = Math.max(scrTop - winHgt, 0);
	}
	else {                  // Page Down
		docEl.scrollTop = Math.min(scrTop + winHgt, scrHgt - winHgt);
	}

	evt.data.preventDefault();
}
else {
	setTimeout( function ()
	{ 
		editor.getSelection().scrollIntoView();
	}, 100 );
}

Note: See TracTickets for help on using tickets.
© 2003 – 2022, CKSource sp. z o.o. sp.k. All rights reserved. | Terms of use | Privacy policy