Bug 5418 bracket marker stays in editor
private void showDebugSourcePage(String typeName) { if (dialog.open() == dialog.OK) { } 1. set the cursor after the opening bracket (after dialog.OK) 2. press enter 3. The bracket box includes all characters insterted by the auto indenter
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/javaeditor/CompilationUnitEditor.java
/**
	 * Responsible for highlighting matching pairs of brackets.
	 */
	class BracketHighlighter implements KeyListener, MouseListener {		
		
		/**
		 * Highlights the brackets.
		 */
		class HighlightBrackets implements PaintListener {
						
			private boolean fHooked= false;
			private JavaPairMatcher fMatcher= new JavaPairMatcher(new char[] { '{', '}', '(', ')', '[', ']' });
			private StyledText fTextWidget;
			private Color fColor;
			
			public HighlightBrackets() {
				fTextWidget= fSourceViewer.getTextWidget();
				fColor= fTextWidget.getDisplay().getSystemColor(SWT.COLOR_MAGENTA);
			}