Documentation of 'org.jdesktop.swingx.util.ShapeUtils' Java class
ShapeUtils
org.jdesktop.swingx.util

Class ShapeUtils



  • public final class ShapeUtils
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method and Description
      static java.awt.Shape generatePolygon(int sides, int outsideRadius, boolean normalize) 
      static java.awt.Shape generatePolygon(int sides, int outsideRadius, int insideRadius) 
      static java.awt.Shape generatePolygon(int sides, int outsideRadius, int insideRadius, boolean normalize) 
      static java.awt.Shape generateShapeFromText(java.awt.Font font, char ch) 
      static java.awt.Shape generateShapeFromText(java.awt.Font font, java.lang.String string) 
      static java.awt.Shape mergeClip(java.awt.Graphics g, java.awt.Shape clip)
      Sets the clip on a graphics object by merging a supplied clip with the existing one.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • generatePolygon

        public static java.awt.Shape generatePolygon(int sides,
                                                     int outsideRadius,
                                                     boolean normalize)
      • generatePolygon

        public static java.awt.Shape generatePolygon(int sides,
                                                     int outsideRadius,
                                                     int insideRadius,
                                                     boolean normalize)
      • generatePolygon

        public static java.awt.Shape generatePolygon(int sides,
                                                     int outsideRadius,
                                                     int insideRadius)
      • generateShapeFromText

        public static java.awt.Shape generateShapeFromText(java.awt.Font font,
                                                           char ch)
      • generateShapeFromText

        public static java.awt.Shape generateShapeFromText(java.awt.Font font,
                                                           java.lang.String string)
      • mergeClip

        public static java.awt.Shape mergeClip(java.awt.Graphics g,
                                               java.awt.Shape clip)
        Sets the clip on a graphics object by merging a supplied clip with the existing one. The new clip will be an intersection of the old clip and the supplied clip. The old clip shape will be returned. This is useful for resetting the old clip after an operation is performed.
        Parameters:
        g - the graphics object to update
        clip - a new clipping region to add to the graphics clip.
        Returns:
        the current clipping region of the supplied graphics object. This may return null if the current clip is null.
        Throws:
        java.lang.NullPointerException - if any parameter is null

DataMelt 3.0 © DataMelt by jWork.ORG

Ads help maintain this website.