LayoutRenderer.java 988 Bytes
/*
 * Decompiled with CFR 0_118.
 */
package com.adobe.xfa.text;

import com.adobe.xfa.font.FontService;
import com.adobe.xfa.gfx.GFXDriver;
import com.adobe.xfa.gfx.GFXEnv;
import com.adobe.xfa.text.DispLineWrapped;
import com.adobe.xfa.text.LayoutDriver;
import com.adobe.xfa.text.TextLayout;
import com.adobe.xfa.text.TextSparseStream;
import com.adobe.xfa.ut.UnitSpan;

class LayoutRenderer
extends GFXEnv {
    private final LayoutDriver mpoDriver;

    LayoutRenderer(TextLayout poLayout, DispLineWrapped poDispLine, UnitSpan oFullAscent, UnitSpan oFullDescent, boolean bAllowCharGlyphs) {
        this.interactive(false);
        this.mpoDriver = new LayoutDriver(this, poLayout, poDispLine, oFullAscent, oFullDescent, bAllowCharGlyphs);
        this.fontService(poDispLine.stream().fontService());
        this.driverAttach();
    }

    void finish() {
        this.mpoDriver.finish();
    }

    @Override
    public GFXDriver driver() {
        return this.mpoDriver;
    }
}