diff options
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common')
-rwxr-xr-x | bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java index c2d5e9e53e..5845e253a5 100755 --- a/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java +++ b/bundles/org.eclipse.swt/Eclipse SWT Custom Widgets/common/org/eclipse/swt/custom/StyledText.java @@ -6685,6 +6685,7 @@ void initializeAccessible() { if (!isListening(LineGetStyle) && st.renderer.styleCount == 0) { e.start = 0; e.end = contentLength; + e.textStyle = new TextStyle(st.getFont(), st.foreground, st.background); return; } int offset = Math.max(0, Math.min(e.offset, contentLength - 1)); @@ -6709,7 +6710,7 @@ void initializeAccessible() { if (e.textStyle == null) { e.textStyle = new TextStyle(st.getFont(), st.foreground, st.background); } else { - if (e.textStyle.foreground == null || e.textStyle.background == null) { + if (e.textStyle.foreground == null || e.textStyle.background == null || e.textStyle.font == null) { TextStyle textStyle = new TextStyle(e.textStyle); if (textStyle.foreground == null) textStyle.foreground = st.foreground; if (textStyle.background == null) textStyle.background = st.background; |