// Path: ui/src/content/jcr_root/libs/foundation/src/impl/src/main/java/com/day/cq/wcm/foundation/ImageHelper.java
// public class ImageHelper extends com.day.cq.commons.ImageHelper {
// }


import java.awt.Color;
import java.awt.geom.Rectangle2D;
import java.io.IOException;
import javax.jcr.RepositoryException;
import com.day.cq.commons.jcr.JcrConstants;
import com.day.cq.wcm.api.designer.Style;
import com.day.cq.wcm.commons.AbstractImageServlet;
import com.day.cq.wcm.foundation.ImageHelper;
import com.day.image.Font;
import com.day.image.Layer;
import org.apache.sling.api.resource.Resource;
/*
 * Copyright 1997-2008 Day Management AG
 * Barfuesserplatz 6, 4001 Basel, Switzerland
 * All Rights Reserved.
 *
 * This software is the confidential and proprietary information of
 * Day Management AG, ("Confidential Information"). You shall not
 * disclose such Confidential Information and shall use it only in
 * accordance with the terms of the license agreement you entered into
 * with Day.
 */

package libs.foundation.components.title;




/**
 * Title image servlet
 */
public class title_png extends AbstractImageServlet {

    protected Layer createLayer(ImageContext c)
            throws RepositoryException, IOException {

        // read the style information (we don't use css names).
        Style style = c.style.getSubStyle("titleimage");
        String fontFace = style.get("fontFamily", "Myriad Pro");
        long fontSize = style.get("fontSize", 10L);
// Path: ui/src/content/jcr_root/libs/foundation/src/impl/src/main/java/com/day/cq/wcm/foundation/ImageHelper.java
// public class ImageHelper extends com.day.cq.commons.ImageHelper {
// }


// Path: ui/src/content/jcr_root/libs/foundation/components/title/title.png.java
import java.awt.Color;
import java.awt.geom.Rectangle2D;
import java.io.IOException;
import javax.jcr.RepositoryException;
import com.day.cq.commons.jcr.JcrConstants;
import com.day.cq.wcm.api.designer.Style;
import com.day.cq.wcm.commons.AbstractImageServlet;
import com.day.cq.wcm.foundation.ImageHelper;
import com.day.image.Font;
import com.day.image.Layer;
import org.apache.sling.api.resource.Resource;

/*
 * Copyright 1997-2008 Day Management AG
 * Barfuesserplatz 6, 4001 Basel, Switzerland
 * All Rights Reserved.
 *
 * This software is the confidential and proprietary information of
 * Day Management AG, ("Confidential Information"). You shall not
 * disclose such Confidential Information and shall use it only in
 * accordance with the terms of the license agreement you entered into
 * with Day.
 */

package libs.foundation.components.title;




/**
 * Title image servlet
 */
public class title_png extends AbstractImageServlet {

    protected Layer createLayer(ImageContext c)
            throws RepositoryException, IOException {

        // read the style information (we don't use css names).
        Style style = c.style.getSubStyle("titleimage");
        String fontFace = style.get("fontFamily", "Myriad Pro");
        long fontSize = style.get("fontSize", 10L);
        int fontStyle = ImageHelper.parseFontStyle(style.get("fontStyle", "bold"));