Examples of PDFormXObject


Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

    public PDFormXObject getRolloverIcon()
    {
        COSBase i = this.getDictionary().getDictionaryObject("RI");
        if (i instanceof COSStream)
        {
            return new PDFormXObject(new PDStream((COSStream) i), "RI");
        }
        return null;
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

    public PDFormXObject getAlternateIcon()
    {
        COSBase i = this.getDictionary().getDictionaryObject("IX");
        if (i instanceof COSStream)
        {
            return new PDFormXObject(new PDStream((COSStream) i), "IX");
        }
        return null;
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

        }
    }

    private COSName createOverlayXObject(PDPage page, LayoutPage layoutPage, COSStream contentStream)
    {
        PDFormXObject xobjForm = new PDFormXObject(new PDStream(contentStream));
        xobjForm.setResources(new PDResources(layoutPage.overlayResources));
        xobjForm.setFormType(1);
        xobjForm.setBBox( layoutPage.overlayMediaBox.createRetranslatedRectangle());
        xobjForm.setMatrix(new AffineTransform());
        PDResources resources = page.getResources();
        return resources.add(xobjForm, "OL");
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

            ((PDFMarkedContentExtractor) context).xobject(xobject);
        }

        if(xobject instanceof PDFormXObject)
        {
            PDFormXObject form = (PDFormXObject)xobject;
            context.showForm(form);
        }
    }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

                            "The N Appearance must be a Stream"));
                    return false;
                }

                // Appearance stream is a XObjectForm, check it.
                ContextHelper.validateElement(ctx, new PDFormXObject(
                        new PDStream(COSUtils.getAsStream(apn, cosDocument)), "N"),
                        GRAPHIC_PROCESS);
            }
        } // else ok, nothing to check,this field is optional
        return true;
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

        PDDocument targetDoc = PDDocument.load(mainPDF);
        PDDocument overlay1Doc = PDDocument.load(overlay1);
        try
        {
            LayerUtility layerUtil = new LayerUtility(targetDoc);
            PDFormXObject form = layerUtil.importPageAsForm(overlay1Doc, 0);
            PDPage targetPage = targetDoc.getPage(0);
            layerUtil.wrapInSaveRestore(targetPage);
            AffineTransform at = new AffineTransform();
            PDOptionalContentGroup ocg = layerUtil.appendFormAsLayer(
                    targetPage, form, at, "overlay");
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.graphics.form.PDFormXObject

                LOG.error(e, e);
            }
        }
        else if (xobject instanceof PDFormXObject)
        {
            PDFormXObject form = (PDFormXObject) xobject;
            if (form.getGroup() != null && COSName.TRANSPARENCY.equals(form.getGroup().getSubType())) {
                getContext().showTransparencyGroup(form);
            }
            else
            {
                getContext().showForm(form);
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.