Bug 63688 wrong indent after 'enter'
3.0 m9 quite annoing usability problem: create this: public int getFoo(){<CARET_HERE>} press Enter you get public int getFoo(){ } which is _never_ right. i get annoyed by this every 5 minutes or so. the same bug in: if(condition){<CARET_HERE>} press Enter, you get if(condition){ } which, againi, is never what you want
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/JavaAutoIndentStrategy.java
int to= from;
		while (toDelete > 0 && to < endOffset) {
			char ch= document.getChar(to);
			if (!Character.isWhitespace(ch))
				break;
			toDelete -= computeVisualLength(ch);
			if (toDelete >= 0)
				to++;
			else
				break;
		}
		
		document.replace(from, to - from, null);
	}
	/**
	 * Returns the visual length of a given <code>CharSequence</code> taking into
	 * account the visual tabulator length.
	 * 
	 * @param seq the string to measure
	 * @return the visual length of <code>seq</code>
	 */
	private static int computeVisualLength(CharSequence seq) {
		int size= 0;
		int tablen= getVisualTabLengthPreference();
		
		for (int i= 0; i < seq.length(); i++) {
			char ch= seq.charAt(i);
			if (ch == '\t')
				size += tablen - size % tablen;
			else