src/eric7/JediInterface/JediServer.py

branch
eric7
changeset 10683
779cda568acb
parent 10526
2549534fcb55
child 10694
f46c1e224e8a
child 10850
d835f48b9908
equal deleted inserted replaced
10682:47be220abdaf 10683:779cda568acb
163 line, index = editor.getCursorPosition() 163 line, index = editor.getCursorPosition()
164 line += 1 # jedi line numbers are 1 based 164 line += 1 # jedi line numbers are 1 based
165 source = editor.text() 165 source = editor.text()
166 return filename, line, index, source 166 return filename, line, index, source
167 167
168 def requestCompletions(self, editor, context, acText): # noqa: U100 168 def requestCompletions(self, editor, _context, acText):
169 """ 169 """
170 Public method to request a list of possible completions. 170 Public method to request a list of possible completions.
171 171
172 @param editor reference to the editor object, that called this method 172 @param editor reference to the editor object, that called this method
173 @type Editor 173 @type Editor
174 @param context flag indicating to autocomplete a context 174 @param _context flag indicating to autocomplete a context (unused)
175 @type bool 175 @type bool
176 @param acText text to be completed 176 @param acText text to be completed
177 @type str 177 @type str
178 """ 178 """
179 if not Preferences.getJedi("JediCompletionsEnabled"): 179 if not Preferences.getJedi("JediCompletionsEnabled"):
223 if "Error" not in result: 223 if "Error" not in result:
224 editor = self.__vm.getOpenEditor(result["FileName"]) 224 editor = self.__vm.getOpenEditor(result["FileName"])
225 if editor is not None: 225 if editor is not None:
226 editor.completionsListReady(names, result["CompletionText"]) 226 editor.completionsListReady(names, result["CompletionText"])
227 227
228 def getCallTips(self, editor, pos, commas): # noqa: U100 228 def getCallTips(self, editor, _pos, _commas):
229 """ 229 """
230 Public method to calculate calltips. 230 Public method to calculate calltips.
231 231
232 @param editor reference to the editor object, that called this method 232 @param editor reference to the editor object, that called this method
233 @type Editor 233 @type Editor
234 @param pos position in the text for the calltip 234 @param _pos position in the text for the calltip (unused)
235 @type int 235 @type int
236 @param commas minimum number of commas contained in the calltip 236 @param _commas minimum number of commas contained in the calltip (unused)
237 @type int 237 @type int
238 @return list of possible calltips 238 @return list of possible calltips
239 @rtype list of str 239 @rtype list of str
240 """ 240 """
241 if not Preferences.getJedi("JediCalltipsEnabled"): 241 if not Preferences.getJedi("JediCalltipsEnabled"):

eric ide

mercurial