svghmi/svghmi.py
branchsvghmi
changeset 2815 77b2a3757e66
parent 2814 2cabc4773885
child 2816 d813ecfe8941
equal deleted inserted replaced
2814:2cabc4773885 2815:77b2a3757e66
    82     def etree(self, add_hash=False):
    82     def etree(self, add_hash=False):
    83 
    83 
    84         attribs = dict(name=self.name)
    84         attribs = dict(name=self.name)
    85         if self.path is not None:
    85         if self.path is not None:
    86             attribs["path"] = ".".join(self.path)
    86             attribs["path"] = ".".join(self.path)
       
    87 
       
    88         if self.hmiclass is not None:
       
    89             attribs["class"] = self.hmiclass
    87 
    90 
    88         if add_hash:
    91         if add_hash:
    89             attribs["hash"] = ",".join(map(str,self.hash()))
    92             attribs["hash"] = ",".join(map(str,self.hash()))
    90 
    93 
    91         res = etree.Element(self.nodetype, **attribs)
    94         res = etree.Element(self.nodetype, **attribs)