# Don't try to resize an object with more than one image (this
# case should be dealt with by overriden handlers)
if (region.GetFormatMode() & FORMAT_SIZE_TO_CONTENTS) and \
- region.GetFormattedText().GetCount() and \
+ len(region.GetFormattedText()) and \
len(self._regions) == 1 and \
not Shape.GraphicsInSizeToContents:
y = top
# We now have the point on the bounding box: but get the point
# on the ellipse by imagining a vertical line from
- # (x, self._ypos - self_height - 500) to (x, self._ypos) intersecting
+ # (x, self._ypos - self._height - 500) to (x, self._ypos) intersecting
# the ellipse.
return DrawArcToEllipse(self._xpos, self._ypos, self._width, self._height, x, self._ypos - self._height - 500, x, self._ypos)