Bug 94261 [typing] Correct indent on paste broken?
20050509-2010 - select a method in the editor so that the selection contains the full lines (including indents before method) - press enter after the closing bracket (indent added) and paste - result is class A { void foo() { } void foo() { } }
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/JavaAutoIndentStrategy.java
refOffset= Math.min(refOffset, peerOffset);
			
			int firstLine= 1; 
			IRegion line= document.getLineInformationOfOffset(offset);
			String notSelected= document.get(line.getOffset(), offset - line.getOffset());
			if (notSelected.trim().length() == 0) {
				newLength += notSelected.length();
				newOffset= line.getOffset();
				firstLine= 0;
			}
			
			IRegion refLine= document.getLineInformationOfOffset(refOffset);
			String prefix= document.get(refLine.getOffset(), newOffset - refLine.getOffset());
			
			Document temp= new Document(prefix + newText);
			DocumentRewriteSession session= temp.startRewriteSession(DocumentRewriteSessionType.STRICTLY_SEQUENTIAL);
			scanner= new JavaHeuristicScanner(temp);
			indenter= new JavaIndenter(temp, scanner, fProject);
			installJavaStuff(temp);
			
			
			
			
			boolean isIndentDetected= false;
			StringBuffer addition= new StringBuffer();
			int insertLength= 0;
			int first= document.computeNumberOfLines(prefix) + firstLine; 
			int lines= temp.getNumberOfLines();
			for (int l= first; l < lines; l++) { 
				IRegion r= temp.getLineInformation(l);