Example #1
0
 def fromXmlString(self, xmlString):
     xmlElement = etree.fromstring(xmlString)
     newRoot = macro.SequenceNode(None)
     newRoot.fromXml(xmlElement)
     self.setRoot(newRoot)
     self.reset()
     return newRoot
Example #2
0
 def fromPlainText(self, text, macroInfos):
     self.beginResetModel()
     newRoot = macro.SequenceNode(None)
     newRoot.fromPlainText(text, macroInfos)
     self.setRoot(newRoot)
     self.endResetModel()
     return newRoot
Example #3
0
 def fromXmlString(self, xmlString):
     self.beginResetModel()
     xmlElement = etree.fromstring(xmlString)
     newRoot = macro.SequenceNode(None)
     newRoot.fromXml(xmlElement)
     self.setRoot(newRoot)
     self.endResetModel()
     return newRoot
Example #4
0
 def clearSequence(self):
     self.setRoot(macro.SequenceNode())
Example #5
0
 def __init__(self, parent=None):
     Qt.QAbstractItemModel.__init__(self, parent)
     self.columns = 4
     self.setRoot(macro.SequenceNode())
     self.headers = ["Macro", "Parameters", "Progress", "Pause"]
Example #6
0
 def fromPlainText(self, text):
     newRoot = macro.SequenceNode(None)
     newRoot.fromPlainText(text)
     self.setRoot(newRoot)
     self.reset()
     return newRoot