Bug 25169 Eating CA: visual indication remains
1) set preference: Insert Proposals 2) open TestCase.java 3) enable segmentated view 4) select TestCase(String) 5) place cursor at Stri>I<ng 6) activate code assist 7) select String from the proposal list 8) press Ctrl 9) press Enter -> color indication remains although content assist window closed
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/JavaCompletionProposal.java
if (offset >  fReplacementOffset + wordLength)
			return false;
		
		try {
			int length= offset - fReplacementOffset;
			String start= document.get(fReplacementOffset, length);
			return word.substring(0, length).equalsIgnoreCase(start);
		} catch (BadLocationException x) {
		}
		
		return false;	
	}	
	private static boolean insertCompletion() {
		IPreferenceStore preference= JavaPlugin.getDefault().getPreferenceStore();
		return preference.getBoolean(ContentAssistPreference.INSERT_COMPLETION);
	}
	/*
	 * @see org.eclipse.jface.text.contentassist.ICompletionProposalExtension1#apply(org.eclipse.jface.text.ITextViewer, char, int, int)
	 */
	public void apply(ITextViewer viewer, char trigger, int stateMask, int offset) {
		IDocument document= viewer.getDocument();
		fToggleEating= (stateMask & SWT.CTRL) != 0;
		if (insertCompletion() ^ fToggleEating)
			fReplacementLength= offset - fReplacementOffset;
		
		apply(document, trigger, offset);
		fToggleEating= false;
	}
	private static Color getForegroundColor(StyledText text) {
		IPreferenceStore preference= JavaPlugin.getDefault().getPreferenceStore();