Bug 41868 Declaration View does not refresh when you change Java-code color preferences
org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/infoviews/SourceView.java
menu.appendToGroup(IContextMenuConstants.GROUP_OPEN, fOpen);
	}
	/*
	 * @see AbstractInfoView#setForeground(Color)
	 */
	protected void setForeground(Color color) {
		fViewer.getTextWidget().setForeground(color);
	}
	/*
	 * @see AbstractInfoView#setBackground(Color)
	 */
	protected void setBackground(Color color) {
		fViewer.getTextWidget().setBackground(color);
	}
	/**
	 * Converts the given selection to a structured selection
	 * containing Java elements.
	 * 
	 * @param selection the selection
	 * @return a structured selection with Java elements
	 */
	private IStructuredSelection convertToJavaElementSelection(ISelection selection) {
		
		if (!(selection instanceof ITextSelection && fCurrentViewInput instanceof ISourceReference))
			return StructuredSelection.EMPTY;
		ITextSelection textSelection= (ITextSelection)selection;
	
		Object codeAssist= fCurrentViewInput.getAncestor(IJavaElement.COMPILATION_UNIT); 
		if (codeAssist == null)
			codeAssist= fCurrentViewInput.getAncestor(IJavaElement.CLASS_FILE);