25 VISIBLE_ATTRIBUTE_NAME =
"Visible"
26 FLAGS_ATTRIBUTE_NAME =
"Flags"
28 def __init__(self, selection, flags, visible=False):
34 return "Visible: %s"%str(self.
IsVisibleIsVisible())
55 if (entity
is not None)
and isinstance(entity,
gfx.Entity):
59 group.SetAttribute(VisibilityOp.VISIBLE_ATTRIBUTE_NAME, str(int(self.
IsVisibleIsVisible())))
60 group.SetAttribute(VisibilityOp.FLAGS_ATTRIBUTE_NAME, str(self.
GetSelectionFlagsGetSelectionFlags()))
66 if group.HasAttribute(VisibilityOp.VISIBLE_ATTRIBUTE_NAME):
67 visible = bool(int(group.GetAttribute(VisibilityOp.VISIBLE_ATTRIBUTE_NAME)))
69 if group.HasAttribute(VisibilityOp.FLAGS_ATTRIBUTE_NAME):
70 flags = int(group.GetAttribute(VisibilityOp.FLAGS_ATTRIBUTE_NAME))
71 selection = group.GetTextData()
graphical rendering of mol::EntityHandle entites
def SetSelectionFlags(self, flags)
def SetSelection(self, selection)
def __init__(self, selection, flags, visible=False)
def ApplyOn(self, entity)
def SetVisible(self, visible)
def GetSelectionFlags(self)