Class GraphicsUtil

java.lang.Object
org.csstudio.swt.widgets.util.GraphicsUtil

public class GraphicsUtil extends Object
The utility class contains functions that all related with graphics.
  • Constructor Details

    • GraphicsUtil

      public GraphicsUtil()
  • Method Details

    • testPatternSupported

      public static boolean testPatternSupported(org.eclipse.draw2d.Graphics graphics)
    • createScaledPattern

      public static Pattern createScaledPattern(org.eclipse.draw2d.Graphics graphics, Device device, float x1, float y1, float x2, float y2, Color color1, int alpha1, Color color2, int alpha2)
    • createScaledPattern

      public static Pattern createScaledPattern(org.eclipse.draw2d.Graphics graphics, Device device, float x1, float y1, float x2, float y2, Color color1, Color color2)
    • mixColors

      public static RGB mixColors(RGB c1, RGB c2, double weight)
      Mixes the passed Colors and returns the resulting Color.
      Parameters:
      c1 - the first color
      c2 - the second color
      weight - the first color's weight from 0-1
      Returns:
      the new color