[SCM] eclipse - Powerful IDE written in java - Debian package. branch, master, updated. eclipse-ppa/maverick-4-g9b2fd80

Niels Thykier nthykier-guest at alioth.debian.org
Sat Jun 5 15:43:29 UTC 2010


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "eclipse - Powerful IDE written in java - Debian package.".

The branch, master has been updated
       via  9b2fd80d053932d204ae4ff16edaa7a3c4698600 (commit)
       via  4cf94fd7288243bb9e4ca7765b3744515683ee65 (commit)
      from  e84bb023789cc926a5661c231fbda347d91c835a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 9b2fd80d053932d204ae4ff16edaa7a3c4698600
Author: Niels Thykier <niels at thykier.net>
Date:   Sat Jun 5 17:42:41 2010 +0200

    Snapshot release for eclipse-ppa.

commit 4cf94fd7288243bb9e4ca7765b3744515683ee65
Author: Niels Thykier <niels at thykier.net>
Date:   Sat Jun 5 16:56:04 2010 +0200

    Backported fix for hover text visability problem.

-----------------------------------------------------------------------

Summary of changes:
 debian/changelog                                   |    7 +-
 debian/patches/bp-hover-visability.patch           |  428 ++++++++++++++++++++
 debian/patches/ecj-gccmain-java.patch              |    8 +-
 debian/patches/fix-help-contents.patch             |    6 +-
 debian/patches/fix-tooltip-color.patch             |    6 +-
 debian/patches/series                              |    2 +-
 .../java/hover/SourceViewerInformationControl.java |   48 ++-
 .../projection/SourceViewerInformationControl.java |   45 ++-
 .../jface/text/AbstractInformationControl.java     |   15 +-
 .../src/org/eclipse/jface/dialogs/PopupDialog.java |   49 +++-
 .../texteditor/SourceViewerInformationControl.java |   45 ++-
 11 files changed, 624 insertions(+), 35 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 49c6c6d..8c7f534 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,14 +1,15 @@
-eclipse (3.5.2-3ubuntu1~ppa1~3.gbpc1a05b) UNRELEASED; urgency=low
+eclipse (3.5.2-3ubuntu1~ppa1~4.gbp4cf94f) UNRELEASED; urgency=low
 
-  ** SNAPSHOT build @c1a05bfefe86d54dafc603c6c90bf816e214c02c **
+  ** SNAPSHOT build @4cf94fd7288243bb9e4ca7765b3744515683ee65 **
 
   * Added menu entry for the Debian menu.
   * Moved a lot of arch-indep plugins into eclipse-platform-data.
   * Backported fix for poor tooltip colors with certain themes. (LP:
     #540332)
   * UNRELEASED
+  * Backported fix for hover text visability problem.
 
- -- Niels Thykier <niels at thykier.net>  Sun, 30 May 2010 14:32:35 +0200
+ -- Niels Thykier <niels at thykier.net>  Sat, 05 Jun 2010 16:56:57 +0200
 
 eclipse (3.5.2-3) unstable; urgency=low
 
diff --git a/debian/patches/bp-hover-visability.patch b/debian/patches/bp-hover-visability.patch
new file mode 100644
index 0000000..6f702d4
--- /dev/null
+++ b/debian/patches/bp-hover-visability.patch
@@ -0,0 +1,428 @@
+Description: Backported fix for hover text visability problem.
+Origin: Upstream, https://bugs.eclipse.org/bugs/show_bug.cgi?id=312966
+Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/light-themes/+bug/540332
+
+--- a/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java
++++ b/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java
+@@ -1,5 +1,5 @@
+ /*******************************************************************************
+- * Copyright (c) 2000, 2008 IBM Corporation and others.
++ * Copyright (c) 2000, 2010 IBM Corporation and others.
+  * All rights reserved. This program and the accompanying materials
+  * are made available under the terms of the Eclipse Public License v1.0
+  * which accompanies this distribution, and is available at
+@@ -48,7 +48,9 @@
+ import org.eclipse.jface.text.source.ISourceViewer;
+ import org.eclipse.jface.text.source.SourceViewer;
+ 
++import org.eclipse.jdt.ui.JavaUI;
+ import org.eclipse.jdt.ui.PreferenceConstants;
++import org.eclipse.jdt.ui.text.IJavaColorConstants;
+ import org.eclipse.jdt.ui.text.IJavaPartitions;
+ 
+ import org.eclipse.jdt.internal.ui.JavaPlugin;
+@@ -90,6 +92,11 @@
+ 	 */
+ 	private Font fStatusTextFont;
+ 	/**
++	 * The color of the optional status text label or <code>null</code> if none.
++	 * @since 3.6
++	 */
++	private Color fStatusTextForegroundColor;
++	/**
+ 	 * The width size constraint.
+ 	 * @since 3.2
+ 	 */
+@@ -198,15 +205,42 @@
+ 			fStatusField.setFont(fStatusTextFont);
+ 			GridData gd2= new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_BEGINNING);
+ 			fStatusField.setLayoutData(gd2);
+-
+-			// Regarding the color see bug 41128
+-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
++			
++			RGB javaDefaultColor= JavaUI.getColorManager().getColor(IJavaColorConstants.JAVA_DEFAULT).getRGB();
++			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(fBackgroundColor.getRGB(), javaDefaultColor, 0.56f));
++			fStatusField.setForeground(fStatusTextForegroundColor);
+ 			fStatusField.setBackground(fBackgroundColor);
+ 		}
+ 
+ 		addDisposeListener(this);
+ 	}
+ 
++	/**
++	 * Returns an RGB that lies between the given foreground and background
++	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
++	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
++	 * equal to <code>bg</code>.
++	 * @param bg the background color
++	 * @param fg the foreground color
++	 * @param factor the mixing factor, must be in [0,&nbsp;1]
++	 *
++	 * @return the interpolated color
++	 * @since 3.6
++	 */
++	private static RGB blend(RGB bg, RGB fg, float factor) {
++		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
++		Assert.isLegal(bg != null);
++		Assert.isLegal(fg != null);
++		Assert.isLegal(factor >= 0f && factor <= 1f);
++		
++		float complement= 1f - factor;
++		return new RGB(
++				(int) (complement * bg.red + factor * fg.red),
++				(int) (complement * bg.green + factor * fg.green),
++				(int) (complement * bg.blue + factor * fg.blue)
++		);
++	}
++	
+ 	private void initializeColors() {
+ 		RGB bgRGB= getHoverBackgroundColorRGB();
+ 		if (bgRGB != null) {
+@@ -274,8 +308,12 @@
+ 	public void widgetDisposed(DisposeEvent event) {
+ 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
+ 			fStatusTextFont.dispose();
+-
+ 		fStatusTextFont= null;
++
++		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
++			fStatusTextForegroundColor.dispose();
++		fStatusTextForegroundColor= null;
++
+ 		fTextFont= null;
+ 		fShell= null;
+ 		fText= null;
+--- a/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java
++++ b/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java
+@@ -1,5 +1,5 @@
+ /*******************************************************************************
+- * Copyright (c) 2005, 2008 IBM Corporation and others.
++ * Copyright (c) 2005, 2010 IBM Corporation and others.
+  * All rights reserved. This program and the accompanying materials
+  * are made available under the terms of the Eclipse Public License v1.0
+  * which accompanies this distribution, and is available at
+@@ -14,6 +14,7 @@
+ import java.util.ArrayList;
+ import java.util.List;
+ 
++import org.eclipse.core.runtime.Assert;
+ import org.eclipse.jface.action.Action;
+ import org.eclipse.jface.action.GroupMarker;
+ import org.eclipse.jface.action.IAction;
+@@ -36,9 +37,11 @@
+ import org.eclipse.swt.graphics.Font;
+ import org.eclipse.swt.graphics.FontData;
+ import org.eclipse.swt.graphics.Point;
++import org.eclipse.swt.graphics.RGB;
+ import org.eclipse.swt.graphics.Rectangle;
+ import org.eclipse.swt.widgets.Composite;
+ import org.eclipse.swt.widgets.Control;
++import org.eclipse.swt.widgets.Display;
+ import org.eclipse.swt.widgets.Event;
+ import org.eclipse.swt.widgets.Label;
+ import org.eclipse.swt.widgets.Listener;
+@@ -321,6 +324,12 @@
+ 	private Control titleSeparator, infoSeparator;
+ 
+ 	/**
++	 * Color to be used for the info area text.
++	 * @since 3.6
++	 */
++	private Color infoColor;
++	
++	/**
+ 	 * Font to be used for the info area text. Computed based on the dialog's
+ 	 * font.
+ 	 */
+@@ -856,12 +865,42 @@
+ 		
+ 		GridDataFactory.fillDefaults().grab(true, false).align(SWT.FILL,
+ 				SWT.BEGINNING).applyTo(infoLabel);
+-		infoLabel.setForeground(parent.getDisplay().getSystemColor(
+-				SWT.COLOR_WIDGET_DARK_SHADOW));
++		Display display = parent.getDisplay();
++		infoColor = new Color(display, blend(
++				display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(),
++				display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(),
++				0.56f));
++		infoLabel.setForeground(infoColor);
+ 		return infoLabel;
+ 	}
+ 
+ 	/**
++	 * Returns an RGB that lies between the given foreground and background
++	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
++	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
++	 * equal to <code>bg</code>.
++	 * @param bg the background color
++	 * @param fg the foreground color
++	 * @param factor the mixing factor, must be in [0,&nbsp;1]
++	 *
++	 * @return the interpolated color
++	 * @since 3.6
++	 */
++	private static RGB blend(RGB bg, RGB fg, float factor) {
++		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
++		Assert.isLegal(bg != null);
++		Assert.isLegal(fg != null);
++		Assert.isLegal(factor >= 0f && factor <= 1f);
++		
++		float complement = 1f - factor;
++		return new RGB(
++				(int) (complement * bg.red + factor * fg.red),
++				(int) (complement * bg.green + factor * fg.green),
++				(int) (complement * bg.blue + factor * fg.blue)
++		);
++	}
++	
++	/**
+ 	 * Create a horizontal separator for the given parent.
+ 	 * 
+ 	 * @param parent
+@@ -1586,6 +1625,10 @@
+ 	 * 
+ 	 */
+ 	private void handleDispose() {
++		if (infoColor != null && !infoColor.isDisposed()) {
++			infoColor.dispose();
++		}
++		infoColor = null;
+ 		if (infoFont != null && !infoFont.isDisposed()) {
+ 			infoFont.dispose();
+ 		}
+--- a/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java
++++ b/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java
+@@ -1,5 +1,5 @@
+ /*******************************************************************************
+- * Copyright (c) 2000, 2008 IBM Corporation and others.
++ * Copyright (c) 2000, 2010 IBM Corporation and others.
+  * All rights reserved. This program and the accompanying materials
+  * are made available under the terms of the Eclipse Public License v1.0
+  * which accompanies this distribution, and is available at
+@@ -22,6 +22,7 @@
+ import org.eclipse.swt.graphics.FontData;
+ import org.eclipse.swt.graphics.GC;
+ import org.eclipse.swt.graphics.Point;
++import org.eclipse.swt.graphics.RGB;
+ import org.eclipse.swt.graphics.Rectangle;
+ import org.eclipse.swt.layout.GridData;
+ import org.eclipse.swt.layout.GridLayout;
+@@ -31,6 +32,8 @@
+ import org.eclipse.swt.widgets.Label;
+ import org.eclipse.swt.widgets.Shell;
+ 
++import org.eclipse.core.runtime.Assert;
++
+ import org.eclipse.jface.resource.JFaceResources;
+ 
+ import org.eclipse.jface.text.Document;
+@@ -67,6 +70,11 @@
+ 	private Label fSeparator;
+ 	/** The font of the optional status text label.*/
+ 	private Font fStatusTextFont;
++	/**
++	 * The color of the optional status text label or <code>null</code> if none.
++	 * @since 3.6
++	 */
++	private Color fStatusTextForegroundColor;
+ 	/** The maximal widget width. */
+ 	private int fMaxWidth;
+ 	/** The maximal widget height. */
+@@ -158,8 +166,8 @@
+ 			GridData gd2= new GridData(GridData.FILL_VERTICAL | GridData.FILL_HORIZONTAL | GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING);
+ 			fStatusField.setLayoutData(gd2);
+ 
+-			// Regarding the color see bug 41128
+-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
++			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(), display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(), 0.56f));
++			fStatusField.setForeground(fStatusTextForegroundColor);
+ 
+ 			fStatusField.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
+ 		}
+@@ -168,6 +176,32 @@
+ 	}
+ 
+ 	/**
++	 * Returns an RGB that lies between the given foreground and background
++	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
++	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
++	 * equal to <code>bg</code>.
++	 * @param bg the background color
++	 * @param fg the foreground color
++	 * @param factor the mixing factor, must be in [0,&nbsp;1]
++	 *
++	 * @return the interpolated color
++	 * @since 3.6
++	 */
++	private static RGB blend(RGB bg, RGB fg, float factor) {
++		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
++		Assert.isLegal(bg != null);
++		Assert.isLegal(fg != null);
++		Assert.isLegal(factor >= 0f && factor <= 1f);
++		
++		float complement= 1f - factor;
++		return new RGB(
++				(int) (complement * bg.red + factor * fg.red),
++				(int) (complement * bg.green + factor * fg.green),
++				(int) (complement * bg.blue + factor * fg.blue)
++		);
++	}
++	
++	/**
+ 	 * @see org.eclipse.jface.text.IInformationControlExtension2#setInput(java.lang.Object)
+ 	 * @param input the input object
+ 	 */
+@@ -204,8 +238,11 @@
+ 	public void widgetDisposed(DisposeEvent event) {
+ 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
+ 			fStatusTextFont.dispose();
+-
+ 		fStatusTextFont= null;
++		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
++			fStatusTextForegroundColor.dispose();
++		fStatusTextForegroundColor= null;
++		
+ 		fTextFont= null;
+ 		fShell= null;
+ 		fText= null;
+--- a/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java
++++ b/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java
+@@ -43,6 +43,7 @@
+ import org.eclipse.core.runtime.ListenerList;
+ 
+ import org.eclipse.jface.action.ToolBarManager;
++import org.eclipse.jface.internal.text.revisions.Colors;
+ import org.eclipse.jface.resource.JFaceResources;
+ import org.eclipse.jface.util.Geometry;
+ 
+@@ -85,6 +86,11 @@
+ 	 * @since 3.4.2
+ 	 */
+ 	private Font fStatusLabelFont;
++	/**
++	 * Color for the label in the status line or <code>null</code> if none.
++	 * @since 3.6
++	 */
++	private Color fStatusLabelForeground;
+ 	/** The toolbar manager used by the toolbar or <code>null</code> if none. */
+ 	private final ToolBarManager fToolBarManager;
+ 	/** Status line toolbar or <code>null</code> if none. */
+@@ -224,8 +230,9 @@
+ 		}
+ 		fStatusLabelFont= new Font(fStatusLabel.getDisplay(), fontDatas);
+ 		fStatusLabel.setFont(fStatusLabelFont);
+-
+-		fStatusLabel.setForeground(fStatusLabel.getDisplay().getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
++		
++		fStatusLabelForeground= new Color(fStatusLabel.getDisplay(), Colors.blend(background.getRGB(), foreground.getRGB(), 0.56f));
++		fStatusLabel.setForeground(fStatusLabelForeground);
+ 		fStatusLabel.setBackground(background);
+ 		setColor(fStatusComposite, foreground, background);
+ 	}
+@@ -672,6 +679,10 @@
+ 			fShell.removeListener(SWT.Deactivate, fShellListener);
+ 			fShellListener= null;
+ 		}
++		if (fStatusLabelForeground != null) {
++			fStatusLabelForeground.dispose();
++			fStatusLabelForeground= null;
++		}
+ 	}
+ 
+ 	/**
+--- a/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
++++ b/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
+@@ -1,5 +1,5 @@
+ /*******************************************************************************
+- * Copyright (c) 2000, 2008 IBM Corporation and others.
++ * Copyright (c) 2000, 2010 IBM Corporation and others.
+  * All rights reserved. This program and the accompanying materials
+  * are made available under the terms of the Eclipse Public License v1.0
+  * which accompanies this distribution, and is available at
+@@ -22,6 +22,7 @@
+ import org.eclipse.swt.graphics.FontData;
+ import org.eclipse.swt.graphics.GC;
+ import org.eclipse.swt.graphics.Point;
++import org.eclipse.swt.graphics.RGB;
+ import org.eclipse.swt.graphics.Rectangle;
+ import org.eclipse.swt.layout.GridData;
+ import org.eclipse.swt.layout.GridLayout;
+@@ -31,6 +32,8 @@
+ import org.eclipse.swt.widgets.Label;
+ import org.eclipse.swt.widgets.Shell;
+ 
++import org.eclipse.core.runtime.Assert;
++
+ import org.eclipse.jface.resource.JFaceResources;
+ 
+ import org.eclipse.jface.text.BadLocationException;
+@@ -73,6 +76,11 @@
+ 	private Label fSeparator;
+ 	/** The font of the optional status text label.*/
+ 	private Font fStatusTextFont;
++	/**
++	 * The color of the optional status text label or <code>null</code> if none.
++	 * @since 3.6
++	 */
++	private Color fStatusTextForegroundColor;
+ 	/** The maximal widget width. */
+ 	private int fMaxWidth;
+ 	/** The maximal widget height. */
+@@ -167,8 +175,8 @@
+ 			GridData gd2= new GridData(GridData.FILL_VERTICAL | GridData.FILL_HORIZONTAL | GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING);
+ 			fStatusField.setLayoutData(gd2);
+ 
+-			// Regarding the color see bug 41128
+-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
++			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(), display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(), 0.56f));
++			fStatusField.setForeground(fStatusTextForegroundColor);
+ 
+ 			fStatusField.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
+ 		}
+@@ -176,6 +184,32 @@
+ 		addDisposeListener(this);
+ 	}
+ 
++	/**
++	 * Returns an RGB that lies between the given foreground and background
++	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
++	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
++	 * equal to <code>bg</code>.
++	 * @param bg the background color
++	 * @param fg the foreground color
++	 * @param factor the mixing factor, must be in [0,&nbsp;1]
++	 *
++	 * @return the interpolated color
++	 * @since 3.6
++	 */
++	private static RGB blend(RGB bg, RGB fg, float factor) {
++		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
++		Assert.isLegal(bg != null);
++		Assert.isLegal(fg != null);
++		Assert.isLegal(factor >= 0f && factor <= 1f);
++		
++		float complement= 1f - factor;
++		return new RGB(
++				(int) (complement * bg.red + factor * fg.red),
++				(int) (complement * bg.green + factor * fg.green),
++				(int) (complement * bg.blue + factor * fg.blue)
++		);
++	}
++	
+ 	/*
+ 	 * @see org.eclipse.jface.text.IInformationControlExtension2#setInput(java.lang.Object)
+ 	 */
+@@ -217,8 +251,11 @@
+ 	public void widgetDisposed(DisposeEvent event) {
+ 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
+ 			fStatusTextFont.dispose();
+-
+ 		fStatusTextFont= null;
++		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
++			fStatusTextForegroundColor.dispose();
++		fStatusTextForegroundColor= null;
++		
+ 		fTextFont= null;
+ 		fShell= null;
+ 		fText= null;
diff --git a/debian/patches/ecj-gccmain-java.patch b/debian/patches/ecj-gccmain-java.patch
index 25d74b3..5f765e1 100644
--- a/debian/patches/ecj-gccmain-java.patch
+++ b/debian/patches/ecj-gccmain-java.patch
@@ -1,8 +1,8 @@
 Description: Adds better support for gcc.
 Origin: Vendor, http://packages.qa.debian.org/e/ecj.html
 
---- ecj-3.5.1.orig/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/GCCMain.java
-+++ ecj-3.5.1/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/GCCMain.java
+--- /dev/null
++++ b/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/GCCMain.java
 @@ -0,0 +1,501 @@
 +/**
 + * 
@@ -505,11 +505,9 @@ Origin: Vendor, http://packages.qa.debian.org/e/ecj.html
 +		System.exit(result ? 0 : 1);
 +	}
 +}
-diff --git a/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/messages.properties b/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/messages.properties
-index bf5dedd..76420d7 100644
 --- a/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/messages.properties
 +++ b/eclipse/plugins/org.eclipse.jdt.core/batch/org/eclipse/jdt/internal/compiler/batch/messages.properties
-@@ -300,3 +300,8 @@ misc.usage.warn = {1} {2}\n\
+@@ -300,3 +300,8 @@
  \      uselessTypeCheck     unnecessary cast/instanceof operation\n\
  \      varargsCast        + varargs argument need explicit cast\n\
  \      warningToken       + unsupported or unnecessary @SuppressWarnings\n
diff --git a/debian/patches/fix-help-contents.patch b/debian/patches/fix-help-contents.patch
index 4e82d43..920d0ff 100644
--- a/debian/patches/fix-help-contents.patch
+++ b/debian/patches/fix-help-contents.patch
@@ -5,11 +5,9 @@ Description: Fixes the problem with the servlet compiler being unable
 Author: Niels Thykier <niels at thykier.net>
 Forwarded: not needed
 
-diff --git a/eclipse/plugins/org.eclipse.equinox.jsp.jasper/src/org/eclipse/equinox/internal/jsp/jasper/JspClassLoader.java b/eclipse/plugins/org.eclipse.equinox.jsp.jasper/src/org/eclipse/equinox/internal/jsp/jasper/JspClassLoader.java
-index 3303026..61cb9c0 100644
 --- a/eclipse/plugins/org.eclipse.equinox.jsp.jasper/src/org/eclipse/equinox/internal/jsp/jasper/JspClassLoader.java
 +++ b/eclipse/plugins/org.eclipse.equinox.jsp.jasper/src/org/eclipse/equinox/internal/jsp/jasper/JspClassLoader.java
-@@ -20,6 +20,7 @@ import java.util.Enumeration;
+@@ -20,6 +20,7 @@
  import java.util.StringTokenizer;
  
  import org.osgi.framework.Bundle;
@@ -17,7 +15,7 @@ index 3303026..61cb9c0 100644
  import org.osgi.framework.Constants;
  
  /**
-@@ -75,6 +76,20 @@ public class JspClassLoader extends URLClassLoader {
+@@ -75,6 +76,20 @@
  	private void addBundleClassPathJars(Bundle bundle) {
  		Dictionary headers = bundle.getHeaders();
  		String classPath = (String) headers.get(Constants.BUNDLE_CLASSPATH);
diff --git a/debian/patches/fix-tooltip-color.patch b/debian/patches/fix-tooltip-color.patch
index 82e9cf6..aab3461 100644
--- a/debian/patches/fix-tooltip-color.patch
+++ b/debian/patches/fix-tooltip-color.patch
@@ -3,8 +3,6 @@ Description: Backported fix for LP: #540332, poor tooltip text colors
 Origin: Upstream, https://bugs.eclipse.org/bugs/show_bug.cgi?id=309907
 Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/light-themes/+bug/540332
 
-diff --git a/build.xml b/build.xml
-index 13c9d83..d3f5c90 100644
 --- a/build.xml
 +++ b/build.xml
 @@ -263,6 +263,7 @@
@@ -15,8 +13,8 @@ index 13c9d83..d3f5c90 100644
  		<replace file="${buildDirectory}/plugins/org.eclipse.pde.build/templates/package-build/build.properties" token="/usr/share/eclipse" value="/usr/${libDir}/eclipse" />
  		<chmod dir="${buildDirectory}/plugins/org.eclipse.pde.build/templates/package-build" includes="*.sh" perm="a+x" />
  		<!-- end eclipse-build-only patches -->
---- /dev/null	2010-05-12 21:34:59.208556227 +0200
-+++ b/patches/tooltip-color.patch	2010-05-29 18:20:48.358013482 +0200
+--- /dev/null
++++ b/patches/tooltip-color.patch
 @@ -0,0 +1,47 @@
 +diff -u -r1.25 ToolTip.java
 +--- a/plugins/org.eclipse.swt/Eclipse SWT/gtk/org/eclipse/swt/widgets/ToolTip.java	2 Dec 2009 15:52:39 -0000
diff --git a/debian/patches/series b/debian/patches/series
index fed4b95..a9df4b5 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -1,4 +1,3 @@
-bashism.patch
 upstream-eclipse-build-repack.patch
 osgi-util.patch
 osgi-services.patch
@@ -17,3 +16,4 @@ osgi-services-symlink-javax.patch
 ecj-gccmain-java.patch
 fix-help-contents.patch
 fix-tooltip-color.patch
+bp-hover-visability.patch
diff --git a/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java b/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java
index 88e6c42..6a576d5 100644
--- a/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java
+++ b/eclipse/plugins/org.eclipse.jdt.ui/ui/org/eclipse/jdt/internal/ui/text/java/hover/SourceViewerInformationControl.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2000, 2008 IBM Corporation and others.
+ * Copyright (c) 2000, 2010 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -48,7 +48,9 @@ import org.eclipse.jface.text.IInformationControlExtension5;
 import org.eclipse.jface.text.source.ISourceViewer;
 import org.eclipse.jface.text.source.SourceViewer;
 
+import org.eclipse.jdt.ui.JavaUI;
 import org.eclipse.jdt.ui.PreferenceConstants;
+import org.eclipse.jdt.ui.text.IJavaColorConstants;
 import org.eclipse.jdt.ui.text.IJavaPartitions;
 
 import org.eclipse.jdt.internal.ui.JavaPlugin;
@@ -90,6 +92,11 @@ public class SourceViewerInformationControl implements IInformationControl, IInf
 	 */
 	private Font fStatusTextFont;
 	/**
+	 * The color of the optional status text label or <code>null</code> if none.
+	 * @since 3.6
+	 */
+	private Color fStatusTextForegroundColor;
+	/**
 	 * The width size constraint.
 	 * @since 3.2
 	 */
@@ -198,15 +205,42 @@ public class SourceViewerInformationControl implements IInformationControl, IInf
 			fStatusField.setFont(fStatusTextFont);
 			GridData gd2= new GridData(GridData.FILL_HORIZONTAL | GridData.VERTICAL_ALIGN_BEGINNING);
 			fStatusField.setLayoutData(gd2);
-
-			// Regarding the color see bug 41128
-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
+			
+			RGB javaDefaultColor= JavaUI.getColorManager().getColor(IJavaColorConstants.JAVA_DEFAULT).getRGB();
+			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(fBackgroundColor.getRGB(), javaDefaultColor, 0.56f));
+			fStatusField.setForeground(fStatusTextForegroundColor);
 			fStatusField.setBackground(fBackgroundColor);
 		}
 
 		addDisposeListener(this);
 	}
 
+	/**
+	 * Returns an RGB that lies between the given foreground and background
+	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
+	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
+	 * equal to <code>bg</code>.
+	 * @param bg the background color
+	 * @param fg the foreground color
+	 * @param factor the mixing factor, must be in [0,&nbsp;1]
+	 *
+	 * @return the interpolated color
+	 * @since 3.6
+	 */
+	private static RGB blend(RGB bg, RGB fg, float factor) {
+		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
+		Assert.isLegal(bg != null);
+		Assert.isLegal(fg != null);
+		Assert.isLegal(factor >= 0f && factor <= 1f);
+		
+		float complement= 1f - factor;
+		return new RGB(
+				(int) (complement * bg.red + factor * fg.red),
+				(int) (complement * bg.green + factor * fg.green),
+				(int) (complement * bg.blue + factor * fg.blue)
+		);
+	}
+	
 	private void initializeColors() {
 		RGB bgRGB= getHoverBackgroundColorRGB();
 		if (bgRGB != null) {
@@ -274,8 +308,12 @@ public class SourceViewerInformationControl implements IInformationControl, IInf
 	public void widgetDisposed(DisposeEvent event) {
 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
 			fStatusTextFont.dispose();
-
 		fStatusTextFont= null;
+
+		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
+			fStatusTextForegroundColor.dispose();
+		fStatusTextForegroundColor= null;
+
 		fTextFont= null;
 		fShell= null;
 		fText= null;
diff --git a/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java b/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java
index 92882fc..e9adbe7 100644
--- a/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java
+++ b/eclipse/plugins/org.eclipse.jface.text/projection/org/eclipse/jface/text/source/projection/SourceViewerInformationControl.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2000, 2008 IBM Corporation and others.
+ * Copyright (c) 2000, 2010 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -22,6 +22,7 @@ import org.eclipse.swt.graphics.Font;
 import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.graphics.GC;
 import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.graphics.RGB;
 import org.eclipse.swt.graphics.Rectangle;
 import org.eclipse.swt.layout.GridData;
 import org.eclipse.swt.layout.GridLayout;
@@ -31,6 +32,8 @@ import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Label;
 import org.eclipse.swt.widgets.Shell;
 
+import org.eclipse.core.runtime.Assert;
+
 import org.eclipse.jface.resource.JFaceResources;
 
 import org.eclipse.jface.text.Document;
@@ -67,6 +70,11 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 	private Label fSeparator;
 	/** The font of the optional status text label.*/
 	private Font fStatusTextFont;
+	/**
+	 * The color of the optional status text label or <code>null</code> if none.
+	 * @since 3.6
+	 */
+	private Color fStatusTextForegroundColor;
 	/** The maximal widget width. */
 	private int fMaxWidth;
 	/** The maximal widget height. */
@@ -158,8 +166,8 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 			GridData gd2= new GridData(GridData.FILL_VERTICAL | GridData.FILL_HORIZONTAL | GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING);
 			fStatusField.setLayoutData(gd2);
 
-			// Regarding the color see bug 41128
-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
+			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(), display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(), 0.56f));
+			fStatusField.setForeground(fStatusTextForegroundColor);
 
 			fStatusField.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
 		}
@@ -168,6 +176,32 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 	}
 
 	/**
+	 * Returns an RGB that lies between the given foreground and background
+	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
+	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
+	 * equal to <code>bg</code>.
+	 * @param bg the background color
+	 * @param fg the foreground color
+	 * @param factor the mixing factor, must be in [0,&nbsp;1]
+	 *
+	 * @return the interpolated color
+	 * @since 3.6
+	 */
+	private static RGB blend(RGB bg, RGB fg, float factor) {
+		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
+		Assert.isLegal(bg != null);
+		Assert.isLegal(fg != null);
+		Assert.isLegal(factor >= 0f && factor <= 1f);
+		
+		float complement= 1f - factor;
+		return new RGB(
+				(int) (complement * bg.red + factor * fg.red),
+				(int) (complement * bg.green + factor * fg.green),
+				(int) (complement * bg.blue + factor * fg.blue)
+		);
+	}
+	
+	/**
 	 * @see org.eclipse.jface.text.IInformationControlExtension2#setInput(java.lang.Object)
 	 * @param input the input object
 	 */
@@ -204,8 +238,11 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 	public void widgetDisposed(DisposeEvent event) {
 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
 			fStatusTextFont.dispose();
-
 		fStatusTextFont= null;
+		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
+			fStatusTextForegroundColor.dispose();
+		fStatusTextForegroundColor= null;
+		
 		fTextFont= null;
 		fShell= null;
 		fText= null;
diff --git a/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java b/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java
index a64b1cb..462837e 100644
--- a/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java
+++ b/eclipse/plugins/org.eclipse.jface.text/src/org/eclipse/jface/text/AbstractInformationControl.java
@@ -43,6 +43,7 @@ import org.eclipse.core.runtime.Assert;
 import org.eclipse.core.runtime.ListenerList;
 
 import org.eclipse.jface.action.ToolBarManager;
+import org.eclipse.jface.internal.text.revisions.Colors;
 import org.eclipse.jface.resource.JFaceResources;
 import org.eclipse.jface.util.Geometry;
 
@@ -85,6 +86,11 @@ public abstract class AbstractInformationControl implements IInformationControl,
 	 * @since 3.4.2
 	 */
 	private Font fStatusLabelFont;
+	/**
+	 * Color for the label in the status line or <code>null</code> if none.
+	 * @since 3.6
+	 */
+	private Color fStatusLabelForeground;
 	/** The toolbar manager used by the toolbar or <code>null</code> if none. */
 	private final ToolBarManager fToolBarManager;
 	/** Status line toolbar or <code>null</code> if none. */
@@ -224,8 +230,9 @@ public abstract class AbstractInformationControl implements IInformationControl,
 		}
 		fStatusLabelFont= new Font(fStatusLabel.getDisplay(), fontDatas);
 		fStatusLabel.setFont(fStatusLabelFont);
-
-		fStatusLabel.setForeground(fStatusLabel.getDisplay().getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
+		
+		fStatusLabelForeground= new Color(fStatusLabel.getDisplay(), Colors.blend(background.getRGB(), foreground.getRGB(), 0.56f));
+		fStatusLabel.setForeground(fStatusLabelForeground);
 		fStatusLabel.setBackground(background);
 		setColor(fStatusComposite, foreground, background);
 	}
@@ -672,6 +679,10 @@ public abstract class AbstractInformationControl implements IInformationControl,
 			fShell.removeListener(SWT.Deactivate, fShellListener);
 			fShellListener= null;
 		}
+		if (fStatusLabelForeground != null) {
+			fStatusLabelForeground.dispose();
+			fStatusLabelForeground= null;
+		}
 	}
 
 	/**
diff --git a/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java b/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java
index b2f6df6..09a31ac 100644
--- a/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java
+++ b/eclipse/plugins/org.eclipse.jface/src/org/eclipse/jface/dialogs/PopupDialog.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2005, 2008 IBM Corporation and others.
+ * Copyright (c) 2005, 2010 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -14,6 +14,7 @@ package org.eclipse.jface.dialogs;
 import java.util.ArrayList;
 import java.util.List;
 
+import org.eclipse.core.runtime.Assert;
 import org.eclipse.jface.action.Action;
 import org.eclipse.jface.action.GroupMarker;
 import org.eclipse.jface.action.IAction;
@@ -36,9 +37,11 @@ import org.eclipse.swt.graphics.Color;
 import org.eclipse.swt.graphics.Font;
 import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.graphics.RGB;
 import org.eclipse.swt.graphics.Rectangle;
 import org.eclipse.swt.widgets.Composite;
 import org.eclipse.swt.widgets.Control;
+import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Event;
 import org.eclipse.swt.widgets.Label;
 import org.eclipse.swt.widgets.Listener;
@@ -321,6 +324,12 @@ public class PopupDialog extends Window {
 	private Control titleSeparator, infoSeparator;
 
 	/**
+	 * Color to be used for the info area text.
+	 * @since 3.6
+	 */
+	private Color infoColor;
+	
+	/**
 	 * Font to be used for the info area text. Computed based on the dialog's
 	 * font.
 	 */
@@ -856,12 +865,42 @@ public class PopupDialog extends Window {
 		
 		GridDataFactory.fillDefaults().grab(true, false).align(SWT.FILL,
 				SWT.BEGINNING).applyTo(infoLabel);
-		infoLabel.setForeground(parent.getDisplay().getSystemColor(
-				SWT.COLOR_WIDGET_DARK_SHADOW));
+		Display display = parent.getDisplay();
+		infoColor = new Color(display, blend(
+				display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(),
+				display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(),
+				0.56f));
+		infoLabel.setForeground(infoColor);
 		return infoLabel;
 	}
 
 	/**
+	 * Returns an RGB that lies between the given foreground and background
+	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
+	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
+	 * equal to <code>bg</code>.
+	 * @param bg the background color
+	 * @param fg the foreground color
+	 * @param factor the mixing factor, must be in [0,&nbsp;1]
+	 *
+	 * @return the interpolated color
+	 * @since 3.6
+	 */
+	private static RGB blend(RGB bg, RGB fg, float factor) {
+		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
+		Assert.isLegal(bg != null);
+		Assert.isLegal(fg != null);
+		Assert.isLegal(factor >= 0f && factor <= 1f);
+		
+		float complement = 1f - factor;
+		return new RGB(
+				(int) (complement * bg.red + factor * fg.red),
+				(int) (complement * bg.green + factor * fg.green),
+				(int) (complement * bg.blue + factor * fg.blue)
+		);
+	}
+	
+	/**
 	 * Create a horizontal separator for the given parent.
 	 * 
 	 * @param parent
@@ -1586,6 +1625,10 @@ public class PopupDialog extends Window {
 	 * 
 	 */
 	private void handleDispose() {
+		if (infoColor != null && !infoColor.isDisposed()) {
+			infoColor.dispose();
+		}
+		infoColor = null;
 		if (infoFont != null && !infoFont.isDisposed()) {
 			infoFont.dispose();
 		}
diff --git a/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java b/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
index 0c6c559..95f55c2 100644
--- a/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
+++ b/eclipse/plugins/org.eclipse.ui.editors/src/org/eclipse/ui/internal/texteditor/SourceViewerInformationControl.java
@@ -1,5 +1,5 @@
 /*******************************************************************************
- * Copyright (c) 2000, 2008 IBM Corporation and others.
+ * Copyright (c) 2000, 2010 IBM Corporation and others.
  * All rights reserved. This program and the accompanying materials
  * are made available under the terms of the Eclipse Public License v1.0
  * which accompanies this distribution, and is available at
@@ -22,6 +22,7 @@ import org.eclipse.swt.graphics.Font;
 import org.eclipse.swt.graphics.FontData;
 import org.eclipse.swt.graphics.GC;
 import org.eclipse.swt.graphics.Point;
+import org.eclipse.swt.graphics.RGB;
 import org.eclipse.swt.graphics.Rectangle;
 import org.eclipse.swt.layout.GridData;
 import org.eclipse.swt.layout.GridLayout;
@@ -31,6 +32,8 @@ import org.eclipse.swt.widgets.Display;
 import org.eclipse.swt.widgets.Label;
 import org.eclipse.swt.widgets.Shell;
 
+import org.eclipse.core.runtime.Assert;
+
 import org.eclipse.jface.resource.JFaceResources;
 
 import org.eclipse.jface.text.BadLocationException;
@@ -73,6 +76,11 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 	private Label fSeparator;
 	/** The font of the optional status text label.*/
 	private Font fStatusTextFont;
+	/**
+	 * The color of the optional status text label or <code>null</code> if none.
+	 * @since 3.6
+	 */
+	private Color fStatusTextForegroundColor;
 	/** The maximal widget width. */
 	private int fMaxWidth;
 	/** The maximal widget height. */
@@ -167,8 +175,8 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 			GridData gd2= new GridData(GridData.FILL_VERTICAL | GridData.FILL_HORIZONTAL | GridData.HORIZONTAL_ALIGN_BEGINNING | GridData.VERTICAL_ALIGN_BEGINNING);
 			fStatusField.setLayoutData(gd2);
 
-			// Regarding the color see bug 41128
-			fStatusField.setForeground(display.getSystemColor(SWT.COLOR_WIDGET_DARK_SHADOW));
+			fStatusTextForegroundColor= new Color(fStatusField.getDisplay(), blend(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND).getRGB(), display.getSystemColor(SWT.COLOR_INFO_FOREGROUND).getRGB(), 0.56f));
+			fStatusField.setForeground(fStatusTextForegroundColor);
 
 			fStatusField.setBackground(display.getSystemColor(SWT.COLOR_INFO_BACKGROUND));
 		}
@@ -176,6 +184,32 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 		addDisposeListener(this);
 	}
 
+	/**
+	 * Returns an RGB that lies between the given foreground and background
+	 * colors using the given mixing factor. A <code>factor</code> of 1.0 will produce a
+	 * color equal to <code>fg</code>, while a <code>factor</code> of 0.0 will produce one
+	 * equal to <code>bg</code>.
+	 * @param bg the background color
+	 * @param fg the foreground color
+	 * @param factor the mixing factor, must be in [0,&nbsp;1]
+	 *
+	 * @return the interpolated color
+	 * @since 3.6
+	 */
+	private static RGB blend(RGB bg, RGB fg, float factor) {
+		// copy of org.eclipse.jface.internal.text.revisions.Colors#blend(..)
+		Assert.isLegal(bg != null);
+		Assert.isLegal(fg != null);
+		Assert.isLegal(factor >= 0f && factor <= 1f);
+		
+		float complement= 1f - factor;
+		return new RGB(
+				(int) (complement * bg.red + factor * fg.red),
+				(int) (complement * bg.green + factor * fg.green),
+				(int) (complement * bg.blue + factor * fg.blue)
+		);
+	}
+	
 	/*
 	 * @see org.eclipse.jface.text.IInformationControlExtension2#setInput(java.lang.Object)
 	 */
@@ -217,8 +251,11 @@ class SourceViewerInformationControl implements IInformationControl, IInformatio
 	public void widgetDisposed(DisposeEvent event) {
 		if (fStatusTextFont != null && !fStatusTextFont.isDisposed())
 			fStatusTextFont.dispose();
-
 		fStatusTextFont= null;
+		if (fStatusTextForegroundColor != null && !fStatusTextForegroundColor.isDisposed())
+			fStatusTextForegroundColor.dispose();
+		fStatusTextForegroundColor= null;
+		
 		fTextFont= null;
 		fShell= null;
 		fText= null;


hooks/post-receive
-- 
eclipse - Powerful IDE written in java - Debian package.



More information about the pkg-java-commits mailing list