Bug 5602 - StyledText - page down causes IllegalArgumentException in invisible/small widget
Summary: StyledText - page down causes IllegalArgumentException in invisible/small widget
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows NT
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Knut Radloff CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2001-11-06 18:58 EST by Knut Radloff CLA
Modified: 2001-11-07 10:59 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Knut Radloff CLA 2001-11-06 18:58:32 EST
The doPageDown method assumes that there is always at least one line visible. 
This is not true if the widget has not been displayed yet or if it is resized 
to less than an entire line height.
The IllegalArgumentException is thrown in DefaultContent when calling 
invokeAction(ST.PAGE_DOWN) or when pressing page down.
Comment 1 Knut Radloff CLA 2001-11-07 10:01:35 EST
In addition, page down only works when there are at least two lines fully 
visible. It should work even if there is only one line partially visible. In 
that case it should scroll just one line.
Comment 2 Knut Radloff CLA 2001-11-07 10:59:23 EST
Fixed doPageDown to always scroll at least one line. Changed doPageUp to match 
new behavior in reverse direction.