List of usage examples for javax.swing JTextArea setSelectionColor
@BeanProperty(preferred = true, description = "color used to render selection background") public void setSelectionColor(Color c)
From source file:com.mindcognition.mindraider.ui.swing.concept.annotation.renderer.AbstractTextAnnotationRenderer.java
private void configureEditor(JTextArea annotationTextArea) { // TODO use colors from the configuration annotationTextArea.setForeground(Color.WHITE); annotationTextArea.setBackground(Color.BLACK); annotationTextArea.setCaretColor(Color.RED); annotationTextArea.setSelectionColor(Color.YELLOW); annotationTextArea.setLineWrap(true); annotationTextArea.setWrapStyleWord(true); annotationTextArea.setFont(TEXTAREA_FONT); ;/*w w w . j av a 2 s . c om*/ // undo and redo undoManager = new UndoManager(); annotationTextArea.getDocument().addUndoableEditListener(new EditorUndoListner(undoManager, toolbar)); }