本文整理汇总了Python中goocanvas.EVENTS_PAINTED_MASK属性的典型用法代码示例。如果您正苦于以下问题:Python goocanvas.EVENTS_PAINTED_MASK属性的具体用法?Python goocanvas.EVENTS_PAINTED_MASK怎么用?Python goocanvas.EVENTS_PAINTED_MASK使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类goocanvas
的用法示例。
在下文中一共展示了goocanvas.EVENTS_PAINTED_MASK属性的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: import goocanvas [as 别名]
# 或者: from goocanvas import EVENTS_PAINTED_MASK [as 别名]
def __init__(self, parent_canvas_item, sta, dev):
self.node1 = sta
self.dev = dev
self.node2 = None # ap
self.canvas_item = goocanvas.Group(parent=parent_canvas_item)
self.invisible_line = goocanvas.Polyline(parent=self.canvas_item,
line_width=25.0,
visibility=goocanvas.ITEM_HIDDEN)
self.visible_line = goocanvas.Polyline(parent=self.canvas_item,
line_width=1.0,
stroke_color_rgba=0xC00000FF,
line_dash=goocanvas.LineDash([2.0, 2.0 ]))
self.invisible_line.props.pointer_events = (goocanvas.EVENTS_STROKE_MASK
|goocanvas.EVENTS_FILL_MASK
|goocanvas.EVENTS_PAINTED_MASK)
self.canvas_item.set_data("pyviz-object", self)
self.canvas_item.lower(None)
self.set_ap(None)
示例2: __init__
# 需要导入模块: import goocanvas [as 别名]
# 或者: from goocanvas import EVENTS_PAINTED_MASK [as 别名]
def __init__(self, parent_canvas_item, sta, dev):
"""! Initialize function.
@param self The object pointer.
@param parent_canvas_item: parent canvas
@param sta The STA node
@param dev The dev
"""
self.node1 = sta
self.dev = dev
self.node2 = None # ap
self.canvas_item = goocanvas.Group(parent=parent_canvas_item)
self.invisible_line = goocanvas.Polyline(parent=self.canvas_item,
line_width=25.0,
visibility=goocanvas.ITEM_HIDDEN)
self.visible_line = goocanvas.Polyline(parent=self.canvas_item,
line_width=1.0,
stroke_color_rgba=0xC00000FF,
line_dash=goocanvas.LineDash([2.0, 2.0 ]))
self.invisible_line.props.pointer_events = (goocanvas.EVENTS_STROKE_MASK
|goocanvas.EVENTS_FILL_MASK
|goocanvas.EVENTS_PAINTED_MASK)
self.canvas_item.set_data("pyviz-object", self)
self.canvas_item.lower(None)
self.set_ap(None)