diff --git a/scripting/editor_text_api.nim b/scripting/editor_text_api.nim index c399b215..f12f3c36 100644 --- a/scripting/editor_text_api.nim +++ b/scripting/editor_text_api.nim @@ -455,7 +455,7 @@ proc getCompletions*(self: TextDocumentEditor) = editor_text_getCompletions_void_TextDocumentEditor_impl(self) proc gotoSymbol*(self: TextDocumentEditor) = editor_text_gotoSymbol_void_TextDocumentEditor_impl(self) -proc fuzzySearchLines*(self: TextDocumentEditor; minScore: float = float.low; +proc fuzzySearchLines*(self: TextDocumentEditor; minScore: float = 0.2; sort: bool = true) = editor_text_fuzzySearchLines_void_TextDocumentEditor_float_bool_impl(self, minScore, sort) diff --git a/scripting/editor_text_api_wasm.nim b/scripting/editor_text_api_wasm.nim index 908c5f91..865bf5e0 100644 --- a/scripting/editor_text_api_wasm.nim +++ b/scripting/editor_text_api_wasm.nim @@ -3178,7 +3178,7 @@ proc gotoSymbol*(self: TextDocumentEditor) = proc editor_text_fuzzySearchLines_void_TextDocumentEditor_float_bool_wasm( arg: cstring): cstring {.importc.} -proc fuzzySearchLines*(self: TextDocumentEditor; minScore: float = float.low; +proc fuzzySearchLines*(self: TextDocumentEditor; minScore: float = 0.2; sort: bool = true) = var argsJson = newJArray() argsJson.add block: diff --git a/scripting/plugin_api_internal.nim b/scripting/plugin_api_internal.nim index 93b9bf42..2ded31bb 100644 --- a/scripting/plugin_api_internal.nim +++ b/scripting/plugin_api_internal.nim @@ -442,7 +442,7 @@ proc editor_text_gotoSymbol_void_TextDocumentEditor_impl*( self: TextDocumentEditor) = discard proc editor_text_fuzzySearchLines_void_TextDocumentEditor_float_bool_impl*( - self: TextDocumentEditor; minScore: float = float.low; sort: bool = true) = + self: TextDocumentEditor; minScore: float = 0.2; sort: bool = true) = discard proc editor_text_gotoWorkspaceSymbol_void_TextDocumentEditor_string_impl*( self: TextDocumentEditor; query: string = "") = diff --git a/src/app.nim b/src/app.nim index 1fe9e531..44003f6f 100644 --- a/src/app.nim +++ b/src/app.nim @@ -283,7 +283,7 @@ proc tryCloseDocument*(self: App, document: Document, force: bool): bool proc closeUnusedDocuments*(self: App) proc tryOpenExisting*(self: App, path: string, appFile: bool = false, append: bool = false): Option[DocumentEditor] proc setOption*(self: App, option: string, value: JsonNode, override: bool = true) -proc addCommandScript*(self: App, context: string, subContext: string, keys: string, action: string, arg: string = "", description: string = "", source: tuple[filename: string, line: int, column: int] = ("", 0, 0)) +proc addCommandScript*(self: App, context: string, subContext: string, keys: string, action: string, arg: string = "", description: string = "") proc currentEventHandlers*(self: App): seq[EventHandler] proc getEditorsForDocument(self: App, document: Document): seq[DocumentEditor] proc showEditor*(self: App, editorId: EditorId, viewIndex: Option[int] = int.none) @@ -945,14 +945,14 @@ proc loadKeybindingsFromJson*(self: App, json: JsonNode, filename: string) = (commandStr[0.. 0: self.commandDescriptions[context & subContext & keys] = description - self.getEventHandlerConfig(context).addCommand(subContext, keys, command, source) + self.getEventHandlerConfig(context).addCommand(subContext, keys, command) self.invalidateCommandToKeysMap() proc removeCommand*(self: App, context: string, keys: string) {.expose("editor").} =