Bug 202446 - [formatter] Format operation move the cursor
Summary: [formatter] Format operation move the cursor
Status: VERIFIED WORKSFORME
Alias: None
Product: JDT
Classification: Eclipse Project
Component: Core (show other bugs)
Version: 3.3   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.4 RC4   Edit
Assignee: Eric Jodet CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-09-06 09:45 EDT by David Audel CLA
Modified: 2008-06-06 09:12 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description David Audel CLA 2007-09-06 09:45:01 EDT
build I20070904-0800

1) create Test.java
public class Test {
	/**
	 * blabla
	 * 
	 * 
	 * bla
	 * 
	 * 
	 * @return
	 */
	public int foo() {
		return 0;
	}
}
2) place the cursor at | location
	/**
	 * blabla
	 * |
	 * 
	 * bla

3) format the whole file 

Then the file is edited but there is no visible modifications and the cursor has been moved at the beginning of the next line.

	/**
	 * blabla
|	 * 
	 * 
	 * bla


If you format the file another time then the cursor moves to the next character.

	/**
	 * blabla
	| * 
	 * 
	 * bla


These behaviors look strange. The file should not be edited and the cursor should not be moved.
Comment 1 Eric Jodet CLA 2008-06-06 04:17:33 EDT
Using build I20080603-2000, the given javadoc seems to be formatted as
expected.
The new formatter (see bug 102780) seems to behave better.

closing as WORKSFORME
Comment 2 Frederic Fusier CLA 2008-06-06 09:12:08 EDT
Verified for 3.4RC4 using I20080606-0100.