Class OTFSubSetWriter

    • Field Detail

      • currentPos

        protected int currentPos
      • output

        protected java.io.ByteArrayOutputStream output
    • Constructor Detail

      • OTFSubSetWriter

        public OTFSubSetWriter()
                        throws java.io.IOException
        Throws:
        java.io.IOException
    • Method Detail

      • concatArray

        public static byte[] concatArray​(byte[] a,
                                         byte[] b)
      • writeByte

        protected void writeByte​(int b)
        Appends a byte to the output array, updates currentPost but not realSize
      • writeCard16

        protected void writeCard16​(int s)
        Appends a USHORT to the output array, updates currentPost but not realSize
      • writeThreeByteNumber

        protected void writeThreeByteNumber​(int s)
      • writeULong

        protected void writeULong​(int s)
        Appends a ULONG to the output array, at the given position
      • writeBytes

        protected void writeBytes​(byte[] out)
      • getFontSubset

        public byte[] getFontSubset()
        Returns a subset of the fonts (readFont() MUST be called first in order to create the subset).
        Returns:
        byte array