Bug 25700 - Shift right/undo not restoring properly
Summary: Shift right/undo not restoring properly
Status: RESOLVED FIXED
Alias: None
Product: JDT
Classification: Eclipse Project
Component: UI (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows 2000
: P2 major (vote)
Target Milestone: 2.1 M3   Edit
Assignee: Claude Knaus CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 26398 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-11-04 15:38 EST by Lynne Kues CLA
Modified: 2002-11-15 04:50 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Lynne Kues CLA 2002-11-04 15:38:24 EST
Build 20021029

I have a java file where the beginning is defined as follows:

package code.snippets;

/*
 * Copyright (c) 2000, 2002 IBM Corp.  All rights reserved. Tis file is made
 * available under the terms of the Common Public License v1.0 wich accompanies
 * this distribution, and is available at htp://www. eclipse. org/legal/cpl-v10.
 * htm
 */

Note that the the comment starts at the beginning of a line (not indented).

1. Drag select the lines in the block comment so the caret is at the beginning 
of the line after the last line in the block comment.
2. Source-->Shift Right, Source-->Shift Right.
3. Edit-->Undo, Edit-->Undo

My comment is restored as follows, the last line is not restored correctly.

/*
 * Copyright (c) 2000, 2002 IBM Corp.  All rights reserved. Tis file is made
 * available under the terms of the Common Public License v1.0 wich accompanies
 * this distribution, and is available at htp://www. eclipse. org/legal/cpl-v10.
 * htm
    */

Note that after the second undo occurs, a tab character and a space exist 
before the "*/".
Comment 1 Dani Megert CLA 2002-11-05 05:50:34 EST
The new Javadoc format feature introduces this bug. There are two issues here
1) Javadoc formatter should not format block comments
2) the Javadoc formatter must handle undo correctly.

Comment 2 Kai-Uwe Maetzel CLA 2002-11-14 13:34:56 EST
Fixed for M3.
Comment 3 Kai-Uwe Maetzel CLA 2002-11-15 04:50:23 EST
*** Bug 26398 has been marked as a duplicate of this bug. ***