MCPcopy
hub / github.com/ShizukuIchi/pdf-editor / utf8Text

Function utf8Text

public/makeTextPDF.js:66943–66950  ·  view source on GitHub ↗
(buf, i)

Source from the content-addressed store, hash-verified

66941 if ((buf[2] & 0xC0) !== 0x80) {
66942 self.lastNeed = 2;
66943 return '\ufffd';
66944 }
66945 }
66946 }
66947}
66948
66949// Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer.
66950function utf8FillLast(buf) {
66951 var p = this.lastTotal - this.lastNeed;
66952 var r = utf8CheckExtraBytes(this, buf, p);
66953 if (r !== undefined) return r;

Callers

nothing calls this directly

Calls 2

utf8CheckIncompleteFunction · 0.85
toStringMethod · 0.45

Tested by

no test coverage detected