Skip to content

Commit cd92ed5

Browse files
DenisUngemachvogella
authored andcommitted
Abstract Text Editor: don't change StyledText by CSS.
Fix for #869
1 parent d84f6fd commit cd92ed5

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

bundles/org.eclipse.ui.workbench.texteditor/src/org/eclipse/ui/texteditor/AbstractTextEditor.java

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -2276,11 +2276,6 @@ private int computeOffsetAtLocation(ITextViewer textViewer, int x, int y) {
22762276
/** The width of the vertical ruler. */
22772277
protected static final int VERTICAL_RULER_WIDTH= 12;
22782278

2279-
/*
2280-
* The colors of AbstractTextEditor can be configured by the "Text Editors"
2281-
* preferences. This color configuration will be changed by theming. This means
2282-
* no need for CSS basecolors here.
2283-
*/
22842279
private static final String DISABLE_CSS = "org.eclipse.e4.ui.css.disabled"; //$NON-NLS-1$
22852280

22862281
/**
@@ -3373,6 +3368,9 @@ public void createPartControl(Composite parent) {
33733368
int styles= SWT.V_SCROLL | SWT.H_SCROLL | SWT.MULTI | SWT.BORDER | SWT.FULL_SELECTION;
33743369
fSourceViewer= createSourceViewer(parent, fVerticalRuler, styles);
33753370

3371+
// We're managing our appearance from our preferences. Disable CSS styling.
3372+
// The CSS engine does set the editor preferences on theme switches, so we
3373+
// will pick up changes.
33763374
fSourceViewer.getTextWidget().setData(DISABLE_CSS, Boolean.TRUE);
33773375

33783376
if (fConfiguration == null)

0 commit comments

Comments
 (0)