mirror of
https://github.com/jsvine/pdfplumber.git
synced 2026-08-29 08:34:23 +08:00
Rename CroppedPage prop "page" -> "parent_page"
This commit is contained in:
+3
-3
@@ -164,13 +164,13 @@ class Page(Container):
|
||||
return CroppedPage(self, bbox)
|
||||
|
||||
class CroppedPage(Page):
|
||||
def __init__(self, page, bbox):
|
||||
self.page = page
|
||||
def __init__(self, parent_page, bbox):
|
||||
self.parent_page = parent_page
|
||||
self.bbox = bbox
|
||||
|
||||
@property
|
||||
def objects(self):
|
||||
if hasattr(self, "_objects"): return self._objects
|
||||
self._objects = utils.within_bbox(self.page.objects, self.bbox,
|
||||
self._objects = utils.within_bbox(self.parent_page.objects, self.bbox,
|
||||
crop=True)
|
||||
return self._objects
|
||||
|
||||
Reference in New Issue
Block a user