MCPcopy Create free account
hub / github.com/pymupdf/PyMuPDF / _insert_font

Method _insert_font

src/__init__.py:3951–3959  ·  view source on GitHub ↗

Utility: insert font from file or binary.

(self, fontfile=None, fontbuffer=None)

Source from the content-addressed store, hash-verified

3949 return liste
3950
3951 def _insert_font(self, fontfile=None, fontbuffer=None):
3952 '''
3953 Utility: insert font from file or binary.
3954 '''
3955 pdf = _as_pdf_document(self)
3956 if not fontfile and not fontbuffer:
3957 raise ValueError( MSG_FILE_OR_BUFFER)
3958 value = JM_insert_font(pdf, None, fontfile, fontbuffer, 0, 0, 0, 0, 0, -1)
3959 return value
3960
3961 def _loadOutline(self):
3962 """Load first outline."""

Callers 2

subset_fontsMethod · 0.80
subset_fontsFunction · 0.80

Calls 2

_as_pdf_documentFunction · 0.85
JM_insert_fontFunction · 0.85

Tested by

no test coverage detected