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

Function JM_char_bbox

src/__init__.py:18784–18794  ·  view source on GitHub ↗

return rect of char quad

(line, ch)

Source from the content-addressed store, hash-verified

18782
18783
18784def JM_char_bbox(line, ch):
18785 '''
18786 return rect of char quad
18787 '''
18788 q = JM_char_quad(line, ch)
18789 r = mupdf.fz_rect_from_quad(q)
18790 if not line.m_internal.wmode:
18791 return r
18792 if r.y1 < r.y0 + ch.m_internal.size:
18793 r.y0 = r.y1 - ch.m_internal.size
18794 return r
18795
18796
18797def JM_char_font_flags(font, line, ch):

Callers 7

extractBLOCKSMethod · 0.85
extractWORDSMethod · 0.85
JM_copy_rectangleFunction · 0.85
JM_make_spanlistFunction · 0.85
JM_search_stext_pageFunction · 0.85

Calls 1

JM_char_quadFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…