slint/tools/lsp
2023-11-28 10:38:46 +01:00
..
language Add more easing formulas (#3812) 2023-11-03 09:20:44 +01:00
LICENSES reuse: remove glob for markdown files 2023-08-17 08:55:28 +02:00
preview LSP: Simplify the preview config handling 2023-11-24 14:08:06 +01:00
ui lsp: Make previewed component resizable 2023-11-28 10:38:46 +01:00
build.rs LSP: Remove compiler env var line from build.rs 2023-11-03 22:14:20 +01:00
Cargo.toml Bump version number to 1.3.1 2023-11-23 07:47:07 +00:00
common.rs LSP: Simplify the preview config handling 2023-11-24 14:08:06 +01:00
language.rs LSP: Simplify the preview config handling 2023-11-24 14:08:06 +01:00
lsp_ext.rs lsp: Derive more Debug implementations 2023-11-03 22:14:20 +01:00
main.rs LSP: default style to native 2023-11-24 14:08:06 +01:00
preview.rs LSP: Simplify the preview config handling 2023-11-24 14:08:06 +01:00
README.md reuse: remove glob for markdown files 2023-08-17 08:55:28 +02:00
util.rs LSP: Move code around 2023-08-28 13:34:35 +02:00
wasm_main.rs LSP: Simplify the preview config handling 2023-11-24 14:08:06 +01:00

LSP (Language Server Protocol) Server for Slint

This directory contains the implementation of the LSP server for Slint featuring diagnostics, code completion, goto definition, and more importantly, live-preview

Generic usage

The LSP server consists of a binary, slint-lsp (or slint-lsp.exe on Windows). It provides all the functionality and allows any programming editor that also implements the standardized LSP protocol to communicate with it.

If you have Rust installed, you can install the binary by running the following command:

cargo install slint-lsp

This makes the latest released version available in $HOME/.cargo/bin. If you would like to try a development version, you can also point cargo install to the git repository: for the released version. Or, to install the develoment version:

cargo install slint-lsp --git https://github.com/slint-ui/slint --force

Alternatively, you can download one of our pre-built binaries for Linux or Windows:

  1. Open https://github.com/slint-ui/slint/releases
  2. Click on the latest release
  3. From "Assets" download either slint-lsp-linux.tar.gz for a Linux x86-64 binary or slint-lsp-windows.zip for a Windows x86-64 binary.
  4. Uncompress the downloaded archive into a location of your choice.

As the next step, configure your editor to use the binary, no arguments are required

Editor configuration

Please check the editors folder in the Slint repository for instructions on how to set up different editors to work with Slint.