Decodes a byte array from PDFDocEncoding to a JavaScript string.
PDFDocEncoding is the default encoding for PDF strings:
The byte array to decode.
The decoded string.
// Decode "Hello" (ASCII)decodeFromPDFDocEncoding(new Uint8Array([72, 101, 108, 108, 111]))// Decode with special character (0x80 = bullet)decodeFromPDFDocEncoding(new Uint8Array([72, 0x80, 105])) Copy
// Decode "Hello" (ASCII)decodeFromPDFDocEncoding(new Uint8Array([72, 101, 108, 108, 111]))// Decode with special character (0x80 = bullet)decodeFromPDFDocEncoding(new Uint8Array([72, 0x80, 105]))
Decodes a byte array from PDFDocEncoding to a JavaScript string.
PDFDocEncoding is the default encoding for PDF strings: