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

Function joinligature

src/__main__.py:661–684  ·  view source on GitHub ↗

Return ligature character for a given pair / triple of characters. Args: lig: (str) 2/3 characters, e.g. "ff" Returns: Ligature, e.g. "ff" -> chr(0xFB00)

(lig: str)

Source from the content-addressed store, hash-verified

659 return chars, rows, left, right, rowheight
660
661 def joinligature(lig: str) -> str:
662 """Return ligature character for a given pair / triple of characters.
663
664 Args:
665 lig: (str) 2/3 characters, e.g. "ff"
666 Returns:
667 Ligature, e.g. "ff" -> chr(0xFB00)
668 """
669
670 if lig == "ff":
671 return chr(0xFB00)
672 elif lig == "fi":
673 return chr(0xFB01)
674 elif lig == "fl":
675 return chr(0xFB02)
676 elif lig == "ffi":
677 return chr(0xFB03)
678 elif lig == "ffl":
679 return chr(0xFB04)
680 elif lig == "ft":
681 return chr(0xFB05)
682 elif lig == "st":
683 return chr(0xFB06)
684 return lig
685
686 # --------------------------------------------------------------------
687 def make_textline(left, slot, minslot, lchars):

Callers 1

process_blocksFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…