MCPcopy Create free account
hub / github.com/EasyIME/PIME / createSession

Method createSession

python/input_methods/rime/rime_ime.py:113–122  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

111 self.select_keys = select_keys
112
113 def createSession(self):
114 if not (self.session_id and rime.find_session(self.session_id)):
115 self.session_id = rime.create_session()
116 self.style = RimeStyle(APP, self.session_id)
117 self.customizeUI(candFontSize = self.style.font_point,
118 candFontName = self.style.font_face,
119 candPerRow = self.style.candidate_per_row,
120 candUseCursor = self.style.candidate_use_cursor)
121 rime.set_option(self.session_id, b'soft_cursor', self.style.soft_cursor)
122 rime.set_option(self.session_id, b'_horizontal', self.style.candidate_per_row > 1)
123
124 def onDeactivate(self):
125 TextService.onDeactivate(self)

Callers 4

onActivateMethod · 0.95
processKeyMethod · 0.95
onCommandMethod · 0.95

Calls 2

RimeStyleClass · 0.85
customizeUIMethod · 0.80

Tested by

no test coverage detected