All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.pushingpixels.photon.api.transcoder.java.SvgTranscoderTemplatePlain.templ Maven / Gradle / Ivy

The newest version!
TOKEN_PACKAGE

import java.awt.*;
import java.awt.geom.*;
import java.lang.ref.WeakReference;
import java.util.Stack;

/**
 * This class has been automatically generated using Photon SVG transcoder.
 */
public class TOKEN_CLASSNAME {
    private static Shape shape = null;
    private static Paint paint = null;
    private static Stroke stroke = null;
    private static Shape clip = null;
    private static Stack transformsStack = new Stack<>();

    TOKEN_RASTER_CODE

	TOKEN_PAINTING_CODE

	/**
	 * Paints the transcoded SVG image on the specified graphics context. You
	 * can install a custom transformation on the graphics context to scale the
	 * image.
	 * 
	 * @param g
	 *            Graphics context.
	 */
    @SuppressWarnings("unused")
	public static void paint(Graphics2D g) {
        float origAlpha = 1.0f;
        Composite origComposite = g.getComposite();
        if (origComposite instanceof AlphaComposite) {
            AlphaComposite origAlphaComposite = 
                (AlphaComposite)origComposite;
            if (origAlphaComposite.getRule() == AlphaComposite.SRC_OVER) {
                origAlpha = origAlphaComposite.getAlpha();
            }
        }
        
        TOKEN_PAINTING_INVOCATIONS

        shape = null;
        paint = null;
        stroke = null;
        clip = null;
        transformsStack.clear();
	}

    /**
     * Returns the X of the bounding box of the original SVG image.
     * 
     * @return The X of the bounding box of the original SVG image.
     */
    public static double getOrigX() {
        return TOKEN_ORIG_X;
    }

    /**
     * Returns the Y of the bounding box of the original SVG image.
     * 
     * @return The Y of the bounding box of the original SVG image.
     */
    public static double getOrigY() {
        return TOKEN_ORIG_Y;
    }

    /**
     * Returns the width of the bounding box of the original SVG image.
     * 
     * @return The width of the bounding box of the original SVG image.
     */
    public static double getOrigWidth() {
        return TOKEN_ORIG_WIDTH;
    }

    /**
     * Returns the height of the bounding box of the original SVG image.
     * 
     * @return The height of the bounding box of the original SVG image.
     */
    public static double getOrigHeight() {
        return TOKEN_ORIG_HEIGHT;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy