def trigger_property (self, property): if property == "status": self._change_mode () elif property == "full_letter": self._full_width_letter [self._mode] = not self._full_width_letter [self._mode] self._refresh_properties () elif property == "full_punct": self._full_width_punct [self._mode] = not self._full_width_punct [self._mode] self._refresh_properties () elif property == "shuangpin": PinYinEngine._shuangpin = not PinYinEngine._shuangpin self.reset () if PinYinEngine._shuangpin: self._py_parser = PYParser.ShuangPinParser (PinYinEngine._shuangpin_schema) else: self._py_parser = PYParser.PinYinParser () self._user_input.set_parser (self._py_parser) self._config.write ("/IMEngine/Python/PinYin/ShuangPin", PinYinEngine._shuangpin) self._refresh_properties () elif property == "gbk": PinYinEngine._gbk = not PinYinEngine._gbk self.reset () self._config.write ("/IMEngine/Python/PinYin/SupportGBK", PinYinEngine._gbk) self._refresh_properties () elif property == "setup": self.start_helper ("eebeecd7-cb22-48f4-8ced-70e42dad1a79") IMEngine.trigger_property (self, property)
def trigger_property (self, property): IMEngine.trigger_property (self, property)