Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 44959

Summary: [content assist] Importing classes causes text to jump
Product: [Eclipse Project] JDT Reporter: Brett Kotch <bkotch>
Component: TextAssignee: JDT-Text-Inbox <jdt-text-inbox>
Status: RESOLVED DUPLICATE QA Contact:
Severity: normal    
Priority: P3 CC: r.bhaskar
Version: 3.0   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Brett Kotch CLA 2003-10-15 18:23:22 EDT
When importing a class and the line where that class is to be imported is 
offscreen, there is no reason to shift the entire editor when the line is 
added. The import line should be added and current view in the editor should 
not change.
Comment 2 Rajnish Bhaskar CLA 2005-02-22 10:37:09 EST
I'll try and add some more information here, then:

I'm using Eclipse Version: 3.0.1 Build id: 200409161125.

Steps to reproduce:
1) Open an existing Java class
2) Start writing a class name in a method such that the import declarations are
off-screen.  Use ctrl+space to begin autocomplete of the class name
3) Select the correct package for your class and press enter.

Expected results: the class is added to the import declarations with no movement
of the editor

Actual results: the import declaration is added, but text in the editor jumps
down by one line
Comment 3 Dani Megert CLA 2005-02-22 12:14:04 EST
Works using 3.1 M5a with folding enabled. Does not work if folding is disabled.
Comment 4 Dani Megert CLA 2005-02-23 03:40:05 EST

*** This bug has been marked as a duplicate of 5870 ***