Rename crop function to show it's internal

This commit is contained in:
Matthew Tretter 2012-02-11 15:33:25 -05:00
parent 4278a95001
commit 80a26a4f09

View file

@ -10,7 +10,7 @@ class Side(object):
ALL = (TOP, RIGHT, BOTTOM, LEFT)
def crop(img, bbox, sides=Side.ALL):
def _crop(img, bbox, sides=Side.ALL):
bbox = (
bbox[0] if Side.LEFT in sides else 0,
bbox[1] if Side.TOP in sides else 0,
@ -67,7 +67,7 @@ class TrimBorderColor(object):
bbox = diff.getbbox()
if bbox:
img = crop(img, bbox, self.sides)
img = _crop(img, bbox, self.sides)
return img