Example usage for com.lowagie.text FontFactory setFontImp

List of usage examples for com.lowagie.text FontFactory setFontImp

Introduction

In this page you can find the example usage for com.lowagie.text FontFactory setFontImp.

Prototype

public static void setFontImp(FontFactoryImp fontImp) 

Source Link

Document

Sets the font factory implementation.

Usage

From source file:mpv5.utils.export.ODTFile2.java

License:Open Source License

public ODTFile2(String pathToFile) throws Exception {
    super(pathToFile);
    if (!exists()) {
        try {/*  ww  w.  j  a v  a 2s.  com*/
            createNewFile();

        } catch (IOException ex) {
            Log.Debug(ex);
        }
    }
    FontFactory.setFontImp(YabsFontFactoryImpl.instance);
    ITextFontRegistry reg = ITextFontRegistry.getRegistry();
    options = PdfOptions.create();
    options.fontProvider(reg);
    report = XDocReportRegistry.getRegistry().loadReport(new FileInputStream(this),
            TemplateEngineKind.Velocity);
    extractor = FieldsExtractor.create();
    report.addPreprocessor(ODTConstants.CONTENT_XML_ENTRY, YabsODTPreprocessor.INSTANCE);
    report.addPreprocessor(ODTConstants.STYLES_XML_ENTRY, YabsODTPreprocessor.INSTANCE);
}