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

org.jpedal.external.FXExternalHandlers Maven / Gradle / Ivy

There is a newer version: 7.15.25
Show newest version
/*
 * ===========================================
 * Java Pdf Extraction Decoding Access Library
 * ===========================================
 *
 * Project Info:  http://www.idrsolutions.com
 * Help section for developers at http://www.idrsolutions.com/support/
 *
 * (C) Copyright 1997-2017 IDRsolutions and Contributors.
 *
 * This file is part of JPedal/JPDF2HTML5
 *
 @LICENSE@
 *
 * ---------------
 * FXExternalHandlers.java
 * ---------------
 */
package org.jpedal.external;

import org.jpedal.FileAccess;
import org.jpedal.display.GUIModes;
import org.jpedal.objects.acroforms.javafx.JavaFXFormCreator;
import org.jpedal.objects.javascript.ExpressionEngine;
import org.jpedal.parser.DecoderOptions;
import org.jpedal.parser.PDFtoImageConvertor;
import org.jpedal.parser.fx.PDFtoImageConvertorFX;
import org.jpedal.render.FXDisplay;

/**
 * @author markee
 */
public class FXExternalHandlers extends ExternalHandlers {

    public FXExternalHandlers(final GUIModes guiModes) {
        super(guiModes);
    }

    @Override
    public boolean isJavaFX() {
        return true;
    }

    @Override
    public void setDVR(final FileAccess fileAccess) {
        fileAccess.setDVR(new FXDisplay(1, fileAccess.getObjectStore(), false));
    }

    @Override
    public PDFtoImageConvertor getConverter(final float multiplyer, final DecoderOptions options) {
        return new PDFtoImageConvertorFX(multiplyer, options);
    }

    @Override
    public void openPdfFile(final ExpressionEngine userExpressionEngine) {

        initObjects(userExpressionEngine, new JavaFXFormCreator());

    }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy