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

Method __mul__

src/__init__.py:14185–14192  ·  view source on GitHub ↗
(self, m)

Source from the content-addressed store, hash-verified

14183 return 2
14184
14185 def __mul__(self, m):
14186 if hasattr(m, "__float__"):
14187 return Point(self.x * m, self.y * m)
14188 if hasattr(m, "__getitem__") and len(m) == 2:
14189 # dot product
14190 return self.x * m[0] + self.y * m[1]
14191 p = Point(self)
14192 return p.transform(m)
14193
14194 def __neg__(self):
14195 return Point(-self.x, -self.y)

Callers

nothing calls this directly

Calls 2

transformMethod · 0.95
PointClass · 0.85

Tested by

no test coverage detected