Fix calculation of image printed area (used in finding weighted DPI for OCR)

Fixes #1334
This commit is contained in:
James R. Barlow
2024-06-21 15:13:51 -07:00
parent 34c285c9ac
commit 0544d06c3d
+1 -1
View File
@@ -491,7 +491,7 @@ class ImageInfo:
"""Physical area of the image in square inches."""
if not self.renderable:
return 0.0
return float(self.width * self.dpi.x * self.height * self.dpi.y)
return float((self.width / self.dpi.x) * (self.height / self.dpi.y))
def __repr__(self):
"""Return a string representation of the image."""