Revert "Bug 501451: Colors in appendStyleSheet should not be hard-coded."
This reverts commit 043666743b59bda1ebadb96816b6493d8f8f4605.
Change-Id: I70941392b9a80e5d87a955c66238ac7fae7f6113
diff --git a/org.eclipse.jface.text/src/org/eclipse/jface/internal/text/html/HTMLPrinter.java b/org.eclipse.jface.text/src/org/eclipse/jface/internal/text/html/HTMLPrinter.java
index 1e49e72..04e4903 100644
--- a/org.eclipse.jface.text/src/org/eclipse/jface/internal/text/html/HTMLPrinter.java
+++ b/org.eclipse.jface.text/src/org/eclipse/jface/internal/text/html/HTMLPrinter.java
@@ -166,7 +166,7 @@
pageProlog.append("<html>"); //$NON-NLS-1$
- appendStyleSheet(pageProlog, styleSheet, fgRGB, bgRGB);
+ appendStyleSheet(pageProlog, styleSheet);
appendColors(pageProlog, fgRGB, bgRGB);
@@ -223,16 +223,16 @@
}
}
- private static void appendStyleSheet(StringBuffer buffer, String styleSheet, RGB fgRGB, RGB bgRGB) {
+ private static void appendStyleSheet(StringBuffer buffer, String styleSheet) {
if (styleSheet == null)
return;
// workaround for https://bugs.eclipse.org/318243
StringBuffer fg= new StringBuffer();
- appendColor(fg, fgRGB);
+ appendColor(fg, FG_COLOR_RGB);
styleSheet= styleSheet.replaceAll("InfoText", fg.toString()); //$NON-NLS-1$
StringBuffer bg= new StringBuffer();
- appendColor(bg, bgRGB);
+ appendColor(bg, BG_COLOR_RGB);
styleSheet= styleSheet.replaceAll("InfoBackground", bg.toString()); //$NON-NLS-1$
buffer.append("<head><style CHARSET=\"ISO-8859-1\" TYPE=\"text/css\">"); //$NON-NLS-1$