Examples of newFOUserAgent()


Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

   
    @Override
    public void transform() throws Exception {
        FopFactory fopFactory = FopFactory.newInstance();
        FOUserAgent foUserAgent = fopFactory.newFOUserAgent();

        OutputStream out = new FileOutputStream(target);
        out = new BufferedOutputStream(out);
       
        try {
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    private static Logger logger = Logger.getLogger(XmlTransformer.class.getName());
   
    @Override
    public void transform() throws Exception {
        FopFactory fopFactory = FopFactory.newInstance();
        FOUserAgent foUserAgent = fopFactory.newFOUserAgent();

        OutputStream out = new FileOutputStream(target);
        out = new BufferedOutputStream(out);
       
        try {
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    return null;
  }

  public File postProcessResult(File result) throws MojoExecutionException {
    final FopFactory fopFactory = FopFactory.newInstance();
    final FOUserAgent userAgent = fopFactory.newFOUserAgent();

    // First transform the cover page
    transformCover();

    // Get properties file from webhelp war
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    //  my own version of loadFOPConfig.  Really, I should be able to
    //  overwrite that method.
    //
    public void postProcessResult(File result) throws MojoExecutionException {
        final FopFactory fopFactory = FopFactory.newInstance();
        final FOUserAgent userAgent = fopFactory.newFOUserAgent();

        // First transform the cover page
        transformCover();

        // FOUserAgent can be used to set PDF metadata
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    public static Fop createFopInstance(OutputStream out, String outputFormat) throws FOPException {
        if (UtilValidate.isEmpty(outputFormat)) {
            outputFormat = MimeConstants.MIME_PDF;
        }
        FopFactory fopFactory = getFactoryInstance();
        FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
        Fop fop;
        if (out != null) {
            fop = fopFactory.newFop(outputFormat, foUserAgent, out);
        } else {
            fop = fopFactory.newFop(outputFormat, foUserAgent);
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

        SAXParser parser;
        parser = spf.newSAXParser();
        foReader = parser.getXMLReader();

        FopFactory fopFactory = FopFactory.newInstance();
        FOUserAgent ua = fopFactory.newFOUserAgent();
        tableHandler = new TableHandler(ua);
        ua.setFOEventHandlerOverride(tableHandler);

        Fop fop = fopFactory.newFop(ua);
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    // generate pdf file
    StreamSource source = new StreamSource(new ByteArrayInputStream(out.toByteArray()));
    StreamSource transformSource = new StreamSource(xsltfile);
    FopFactory fopFactory = FopFactory.newInstance();
    FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
    ByteArrayOutputStream outStream = new ByteArrayOutputStream();
    // transform xml
    Transformer xslfoTransformer = getTransformer(transformSource);
    try {
      Fop fop = fopFactory.newFop(MimeConstants.MIME_PDF, foUserAgent, outStream);
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

    public static Fop createFopInstance(OutputStream out, String outputFormat) throws FOPException {
        if (UtilValidate.isEmpty(outputFormat)) {
            outputFormat = MimeConstants.MIME_PDF;
        }
        FopFactory fopFactory = getFactoryInstance();
        FOUserAgent foUserAgent = fopFactory.newFOUserAgent();
        Fop fop;
        if (out != null) {
            fop = fopFactory.newFop(outputFormat, foUserAgent, out);
        } else {
            fop = fopFactory.newFop(outputFormat, foUserAgent);
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

                ttfFile.getCanonicalPath(), metricsFile.getCanonicalPath()};
        TTFReader.main(args);
        assertTrue(metricsFile.isFile());
       
        FopFactory fopFactory = FopFactory.newInstance();
        FOUserAgent ua = fopFactory.newFOUserAgent();
        PDFRenderer renderer = new PDFRenderer();
        renderer.setUserAgent(ua);
        List fontList = new java.util.ArrayList();
        List triplets = new java.util.ArrayList();
        triplets.add(new FontTriplet(fontFamily, "normal", Font.WEIGHT_NORMAL));
View Full Code Here

Examples of org.apache.fop.apps.FopFactory.newFOUserAgent()

        FopFactory ff = FopFactory.newInstance();
        ff.setSourceResolution(96);
        ff.setTargetResolution(300);

        FOUserAgent userAgent = ff.newFOUserAgent();

        ImageManager manager = ff.getImageManager();
        ImageInfo info = manager.preloadImage(uri, userAgent.getImageSessionContext());
        assertNotNull("ImageInfo must not be null", info);
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.