Package org.pdfbox.pdmodel.common

Examples of org.pdfbox.pdmodel.common.PDMatrix


     *
     * @return The linear interpretation matrix.
     */
    public PDMatrix getLinearInterpretation()
    {
        PDMatrix retval = null;
        COSArray matrix = (COSArray)dictionary.getDictionaryObject( COSName.getPDFName( "Matrix" ) );
        if( matrix == null )
        {
            retval = new PDMatrix();
            setLinearInterpretation( retval );
        }
        else
        {
            retval = new PDMatrix( matrix );
        }
        return retval;
    }
View Full Code Here


     *
     * @return The matrix to transform from glyph space to text space.
     */
    public PDMatrix getFontMatrix()
    {
        PDMatrix matrix = null;
        COSArray array = (COSArray)font.getDictionaryObject( COSName.FONT_MATRIX );
        if( array == null )
        {
            array = new COSArray();
            array.add( new COSFloat( 0.001f ) );
            array.add( COSNumber.ZERO );
            array.add( COSNumber.ZERO );
            array.add( new COSFloat( 0.001f ) );
            array.add( COSNumber.ZERO );
            array.add( COSNumber.ZERO );
        }
        matrix = new PDMatrix(array);
       
        return matrix;
    }
View Full Code Here

TOP

Related Classes of org.pdfbox.pdmodel.common.PDMatrix

Copyright © 2018 www.massapicom. 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.