pull/8675/merge^2
piotrkwarcinski 2025-05-11 23:05:21 +02:00
parent d9ec722a77
commit ec53eb429a
1 changed files with 20 additions and 15 deletions

View File

@ -1112,35 +1112,40 @@ fn load_editor_api(engine: &mut Engine, generate_sources: bool) {
} }
}; };
template_function_arity_1("editor->doc-id", "Get the document from a given view"); template_function_arity_1("editor->doc-id", "Get the document from a given view.");
template_function_arity_1("editor-switch!", "Open the document in a vertical split"); template_function_arity_1("editor-switch!", "Open the document in a vertical split.");
template_function_arity_1("editor-set-focus!", "Set focus on the view"); template_function_arity_1("editor-set-focus!", "Set focus on the view.");
template_function_arity_1("editor-set-mode!", "Set the editor mode"); template_function_arity_1("editor-set-mode!", "Set the editor mode.");
template_function_arity_1( template_function_arity_1(
"editor-doc-in-view?", "editor-doc-in-view?",
"Check whether the current view contains a document", "Check whether the current view contains a document.",
); );
template_function_arity_1( template_function_arity_1(
"set-scratch-buffer-name!", "set-scratch-buffer-name!",
"Set the name of a scratch buffer", "Set the name of a scratch buffer.",
);
template_function_arity_1("editor-doc-exists?", "Check if a document exists.");
template_function_arity_1("editor->text", "Get the document as a rope.");
template_function_arity_1("editor-document->path", "Get the path to a document.");
template_function_arity_1(
"register->value",
"Get register value as a list of strings.",
);
template_function_arity_1(
"set-editor-clip-top!",
"Set the editor clipping at the top.",
); );
template_function_arity_1("editor-doc-exists?", "Check if a document exists");
template_function_arity_1("editor->text", "Get the document text as a rope");
template_function_arity_1("editor-document->path", "Get the path to a document");
template_function_arity_1("register->value", "Get register value as a list of strings");
template_function_arity_1("set-editor-clip-top!", "Set the editor clipping at the top");
template_function_arity_1( template_function_arity_1(
"set-editor-clip-right!", "set-editor-clip-right!",
"Set the editor clipping at the right", "Set the editor clipping at the right.",
); );
template_function_arity_1( template_function_arity_1(
"set-editor-clip-left!", "set-editor-clip-left!",
"Set the editor clipping at the left", "Set the editor clipping at the left.",
); );
template_function_arity_1( template_function_arity_1(
"set-editor-clip-bottom!", "set-editor-clip-bottom!",
"Set the editor clipping at the bottom", "Set the editor clipping at the bottom.",
); );
let mut template_function_arity_2 = |name: &str| { let mut template_function_arity_2 = |name: &str| {