Bug 44035 [formatting] Error in formatting parts of java code snippets in comment
This is for build I20030930. The Java code formatter options are set to Format java code snippets. Taking the following comment: /** * The following is a Java snipet. * * <pre> * while ((size = availableSize(stream, size)) > 0) { * System.out.println("available"); * } * </pre> */ public void test() { } And trying to format it here is what we got: /** * The following is a Java snipet. * * <pre> * while ((size = availableSize(stream, size)) > 0) { * System.out.println("available"); } * </pre> */ public void test() { }
org.eclipse.jdt.ui/ui/org/eclipse/jdt/ui/text/JavaSourceViewerConfiguration.java
int shellStyle= SWT.RESIZE;
				int style= SWT.V_SCROLL | SWT.H_SCROLL;
				return new DefaultInformationControl(parent, shellStyle, style, new HTMLTextPresenter(false));
				
			}
		};
	}
	/**
	 * Returns the outline presenter control creator. The creator is a factory creating outline
	 * presenter controls for the given source viewer. This implementation always returns a creator
	 * for <code>JavaOutlineInformationControl</code> instances.
	 * 
	 * @param sourceViewer the source viewer to be configured by this configuration
	 * @return an information control creator
	 * @since 2.1
	 */
	private IInformationControlCreator getOutlinePresenterControlCreator(ISourceViewer sourceViewer) {
		return new IInformationControlCreator() {
			public IInformationControl createInformationControl(Shell parent) {
				int shellStyle= SWT.RESIZE;
				int treeStyle= SWT.V_SCROLL | SWT.H_SCROLL;
				return new JavaOutlineInformationControl(parent, shellStyle, treeStyle);
			}
		};
	}
	
	private IInformationControlCreator getHierarchyPresenterControlCreator(ISourceViewer sourceViewer) {
		return new IInformationControlCreator() {
			public IInformationControl createInformationControl(Shell parent) {
				int shellStyle= SWT.RESIZE;