String replacement= CodeFormatterUtil.format(CodeFormatter.K_EXPRESSION, buf.toString(), 0, null, lineDelim, fSuperType.getJavaProject());
String replacement= CodeFormatterUtil.format(CodeFormatter.K_EXPRESSION, buf.toString(), 0, null, lineDelim, project);
	protected boolean updateReplacementString(IDocument document, char trigger, int offset, ImportRewrite impRewrite) throws CoreException, BadLocationException {		String replacementString= getReplacementString();		// construct replacement text: an expression to be formatted		StringBuffer buf= new StringBuffer("new A("); //$NON-NLS-1$		buf.append(replacementString);		if (!replacementString.endsWith(")")) { //$NON-NLS-1$			buf.append(')');		}		if (!createStubs(buf, impRewrite)) {			return false;		}		if (document.getChar(offset) != ')')			buf.append(';');		// use the code formatter		String lineDelim= TextUtilities.getDefaultLineDelimiter(document);		final IJavaProject project= fCompilationUnit.getJavaProject();		IRegion region= document.getLineInformationOfOffset(getReplacementOffset());		int indent= Strings.computeIndentUnits(document.get(region.getOffset(), region.getLength()), project);		String replacement= CodeFormatterUtil.format(CodeFormatter.K_EXPRESSION, buf.toString(), 0, null, lineDelim, fSuperType.getJavaProject());		replacement= Strings.changeIndent(replacement, 0, project, CodeFormatterUtil.createIndentString(indent, project), lineDelim);		setReplacementString(replacement.substring(replacement.indexOf('(') + 1));		int pos= offset;		while (pos < document.getLength() && Character.isWhitespace(document.getChar(pos))) {			pos++;		}		if (pos < document.getLength() && document.getChar(pos) == ')') {			setReplacementLength(pos - offset + 1);		}		return true;	}