def size(self, value): if isinstance(value, tuple): if not isinstance(value, Size): value = Size(value[0], value[1]) self._obj.SetSize(value.native_obj) else: # value is a single number/integer self._obj.SetSize(Size(value, value).native_obj)
def drill(self, value): """Sets the drill size. If value is a single float or int, pad drill shape is set to circle, if input is a tuple of (x, y) drill shape is set to oval.""" if isinstance(value, tuple): self.drillShape = DrillShape.Oval if not isinstance(value, Size): value = Size(value[0], value[1]) self._obj.SetDrillSize(value.native_obj) else: # value is a single number/integer drillShape = DrillShape.Circle self._obj.SetDrillSize(Size(value, value).native_obj())
def drill(self): """Drill size. Returns `Size`.""" return Size.wrap(self._obj.GetDrillSize())
def size(self): return Size.wrap(self._obj.GetSize())