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

Method normalize

src/__init__.py:14773–14779  ·  view source on GitHub ↗

Replace rectangle with its finite version.

(self)

Source from the content-addressed store, hash-verified

14771 return math.sqrt(sum([c*c for c in self]))
14772
14773 def normalize(self):
14774 """Replace rectangle with its finite version."""
14775 if self.x1 < self.x0:
14776 self.x0, self.x1 = self.x1, self.x0
14777 if self.y1 < self.y0:
14778 self.y0, self.y1 = self.y1, self.y0
14779 return self
14780
14781 @property
14782 def quad(self):

Callers 4

get_drawingsMethod · 0.45
get_lineartMethod · 0.45
make_edgesFunction · 0.45
prism.jsFile · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected