Humboldt Alignment Editor 2.5.0

eu.esdihumboldt.hale.ui.util.swing
Class SwingRcpUtilities

java.lang.Object
  extended by eu.esdihumboldt.hale.ui.util.swing.SwingRcpUtilities

public class SwingRcpUtilities
extends Object

Utilities for working with Swing and SWT

Author:
Simon Templer, Thorsten Reitz
Partner:
01 / Fraunhofer Institute for Computer Graphics Research

Constructor Summary
SwingRcpUtilities()
           
 
Method Summary
static BufferedImage convertToAWT(org.eclipse.swt.graphics.ImageData data)
          Convert a SWT Image to a BufferedImage "http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet156.java?view=co"
static Color convertToColor(org.eclipse.swt.graphics.RGB rgb)
          Convert a RGB to an AWT color
static org.eclipse.swt.graphics.ImageData convertToSWT(BufferedImage bufferedImage)
          Convert a BufferedImage to a SWT Image.
static org.eclipse.swt.graphics.ImageData convertToSWT(ImageIcon icon)
          Create a SWT Image from an ImageIcon "http://www.eclipseproject.de/modules.php?name=Forums&file=viewtopic&t=5489" "http://www.9php.com/FAQ/cxsjl/java/2007/11/5033330101296.html"
static void setup()
          Swing setup, should be called before any AWT/Swing Component is created
static void setupLookAndFeel()
          Setup Look and Feel to match SWT looks
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SwingRcpUtilities

public SwingRcpUtilities()
Method Detail

setup

public static void setup()
Swing setup, should be called before any AWT/Swing Component is created


setupLookAndFeel

public static void setupLookAndFeel()
Setup Look and Feel to match SWT looks


convertToAWT

public static BufferedImage convertToAWT(org.eclipse.swt.graphics.ImageData data)
Convert a SWT Image to a BufferedImage "http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet156.java?view=co"

Parameters:
data - the SWT ImageData
Returns:
the AWT BufferedImage

convertToSWT

public static org.eclipse.swt.graphics.ImageData convertToSWT(BufferedImage bufferedImage)
Convert a BufferedImage to a SWT Image. "http://dev.eclipse.org/viewcvs/index.cgi/org.eclipse.swt.snippets/src/org/eclipse/swt/snippets/Snippet156.java?view=co"

Parameters:
bufferedImage - the AWT BufferedImage
Returns:
the SWT ImageData

convertToSWT

public static org.eclipse.swt.graphics.ImageData convertToSWT(ImageIcon icon)
Create a SWT Image from an ImageIcon "http://www.eclipseproject.de/modules.php?name=Forums&file=viewtopic&t=5489" "http://www.9php.com/FAQ/cxsjl/java/2007/11/5033330101296.html"

Parameters:
icon - the ImageIcon
Returns:
the SWT ImageData

convertToColor

public static Color convertToColor(org.eclipse.swt.graphics.RGB rgb)
Convert a RGB to an AWT color

Parameters:
rgb - the RGB
Returns:
the color

Humboldt Alignment Editor 2.5.0

Build 2012-12-03_12-30-59
Revision 9d2dd4b0318cda9f1393b1ddd390f7f792d70a2d