本文整理汇总了Python中rectangle.Rectangle.__init__方法的典型用法代码示例。如果您正苦于以下问题:Python Rectangle.__init__方法的具体用法?Python Rectangle.__init__怎么用?Python Rectangle.__init__使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类rectangle.Rectangle
的用法示例。
在下文中一共展示了Rectangle.__init__方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
# self.id = random.uniform(0, 999999999)
Rectangle.__init__(self)
self.handler = Handler()
self.magnetos = Magnetos()
self.offset = Point()
self.pivot = Point()
self.selected = False
self.resizing = False
self.direction = NONE
self.control = AUTOMATIC
self.z = 0
self.hints = False
from ui.canvas import Canvas
self.canvas = Canvas()
self.handler.is_testing = self.canvas.is_testing
self.dash = []
self.thickness = 1.0
self.fill_style = COLOR
self.fill_color = Color(0.25, 0.25, 0.25, 0.25)
self.stroke_color = Color(0.25, 0.25, 0.25, 1.0)
self.gradient = Gradient()
示例2: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.hidden = False
self.position = 0.0
self.direction = NONE
self.control = Control()
self.control.limbus = True
示例3: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.active = True
self.top = 0
self.left = 0
self.bottom = 0
self.right = 0
self.control = list()
index = 0
while index < 8:
control = Control()
self.control.append(control)
index += 1
示例4: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.active = True
self.tags = list()
self.magnetism = 32
示例5: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.active = False
示例6: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.position = 0
self.selected = False
self.size = 25
self.orientation = NONE
示例7: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self):
Rectangle.__init__(self)
self.active = True
self.size = 15.0
self.snap = True
示例8: __init__
# 需要导入模块: from rectangle import Rectangle [as 别名]
# 或者: from rectangle.Rectangle import __init__ [as 别名]
def __init__(self, index, x, y, width, height):
self.index = index
self.state = ' '
Rectangle.__init__(self, x, y, width, height)