-
Notifications
You must be signed in to change notification settings - Fork 898
Expand file tree
/
Copy pathCargo.toml
More file actions
149 lines (129 loc) · 5.82 KB
/
Cargo.toml
File metadata and controls
149 lines (129 loc) · 5.82 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
# Copyright © SixtyFPS GmbH <info@slint.dev>
# SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0
# cSpell: ignore dashmap nucleo
[package]
name = "slint-lsp"
description = "A language server protocol implementation for Slint"
authors = ["Slint Developers <info@slint.dev>"]
edition.workspace = true
homepage = "https://slint.dev"
license.workspace = true
repository.workspace = true
rust-version.workspace = true
version = "1.17.0"
categories = ["gui", "development-tools", "command-line-utilities"]
keywords = ["lsp", "ui", "toolkit"]
default-run = "slint-lsp"
[package.metadata.bundle]
name = "Slint Live Preview"
icon = ["../../logo/slint-logo.icns"]
[[bin]]
name = "slint-lsp"
path = "main.rs"
[[example]]
name = "slint-editor"
path = "editor_main.rs"
[lib]
# lib is there only for the web
crate-type = ["cdylib"]
path = "wasm_main.rs"
# On windows building this package creates slint-lsp.exe and slint-lsp.dll.
# To avoid that both end up trying to create slint-lsp.pdb for their debug
# symbols, rename the lib.
name = "slint_lsp_wasm"
[features]
backend-qt = ["slint/backend-qt", "preview"]
backend-winit = ["slint/backend-winit", "preview"]
backend-winit-x11 = ["slint/backend-winit-x11", "preview"]
backend-winit-wayland = ["slint/backend-winit-wayland", "preview"]
backend-linuxkms = ["slint/backend-linuxkms", "preview"]
backend-linuxkms-noseat = ["slint/backend-linuxkms-noseat", "preview"]
backend-default = ["slint/backend-default", "preview"]
renderer-femtovg = ["slint/renderer-femtovg", "preview"]
renderer-skia = ["slint/renderer-skia", "preview"]
renderer-skia-opengl = ["slint/renderer-skia-opengl", "preview"]
renderer-skia-vulkan = ["slint/renderer-skia-vulkan", "preview"]
renderer-software = ["slint/renderer-software", "preview"]
# Compat
backend-gl-all = ["backend-winit", "renderer-femtovg"]
backend-gl-wayland = ["backend-winit-wayland", "renderer-femtovg"]
backend-gl-x11 = ["backend-winit-x11", "renderer-femtovg"]
eventloop-qt = ["backend-qt"]
renderer-winit-qt = ["backend-qt"]
renderer-winit-femtovg = ["renderer-femtovg"]
renderer-winit-skia = ["renderer-skia"]
renderer-winit-skia-opengl = ["renderer-skia-opengl"]
renderer-winit-skia-vulkan = ["renderer-skia-vulkan"]
renderer-winit-software = ["renderer-software"]
## Enable support for previewing .slint files
preview = ["preview-builtin", "preview-external", "preview-remote", "preview-engine"]
## [deprecated] Used to enable the "Show Preview" lenses and action on components.
preview-lense = []
## [deprecated] Used to enable partial support for external previewers.
## Use "preview-external" (and maybe "preview-engine" if you want the LSP binary
## to provide an implementation of the external preview API when building for WASM)
preview-api = ["preview-external"]
## Build in the actual code to act as a preview for slint files.
preview-engine = [
"dep:slint",
"dep:slint-interpreter",
"dep:i-slint-core",
"dep:i-slint-backend-selector",
"dep:slint-build",
]
## Build in the actual code to act as a preview for slint files. Does nothing in WASM!
preview-builtin = ["preview-engine"]
## Support the external preview optionally used by e.g. the VSCode plugin
preview-external = []
## Support the remote preview via a WebSocket connection
preview-remote = ["preview-engine", "preview-builtin"]
default = ["backend-default", "renderer-femtovg", "renderer-software", "preview"]
[dependencies]
i-slint-compiler = { workspace = true, features = ["display-diagnostics"] }
i-slint-common = { workspace = true }
by_address = { workspace = true }
clru = { workspace = true }
dissimilar = "1.0.7"
itertools = { workspace = true }
tracing = { workspace = true }
tracing-subscriber = { workspace = true, features = ["env-filter"] }
serde = { workspace = true }
serde_json = { workspace = true }
smol_str = { workspace = true }
i-slint-live-preview = { version = "=1.17.0", path = "../../internal/live-preview", features = ["protocol", "file-watcher"] }
lsp-types = { workspace = true }
# for the preview-engine feature
i-slint-backend-selector = { workspace = true, optional = true }
i-slint-core = { workspace = true, features = ["std"], optional = true }
slint = { workspace = true, features = ["compat-1-2"], optional = true }
slint-interpreter = { workspace = true, features = ["compat-1-2", "internal", "internal-highlight", "internal-json", "image-default-formats"], optional = true }
nucleo-matcher = "0.3.1"
futures-util = "0.3.32"
tokio-tungstenite-wasm = "0.8.2"
postcard = { version = "1.1.3", features = ["alloc"] }
[target.'cfg(not(any(target_os = "openbsd", target_os = "windows", target_arch = "wasm32", all(target_arch = "aarch64", target_os = "linux"))))'.dependencies]
tikv-jemallocator = { workspace = true }
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
clap = { workspace = true }
crossbeam-channel = "0.5" # must match the version used by lsp-server
lsp-server = "0.7"
tokio = { version = "1.50.0", features = ["rt", "sync", "time", "macros", "io-std", "io-util", "net", "fs", "process"] }
dashmap = "6.1.0"
mdns-sd = "0.18.2"
[target.'cfg(target_arch = "wasm32")'.dependencies]
console_error_panic_hook = "0.1.5"
js-sys = { version = "0.3.57" }
web-sys = { workspace = true, features = ["Navigator", "Clipboard", "UrlSearchParams", "Location"] }
send_wrapper = { workspace = true }
serde-wasm-bindgen = "0.6.0"
wasm-bindgen = "0.2.80"
wasm-bindgen-futures = "0.4.30"
i-slint-backend-winit = { workspace = true }
tokio = { version = "1.50.0", features = ["rt", "sync", "macros"] }
[dev-dependencies]
i-slint-backend-testing = { path = "../../internal/backends/testing" }
spin_on = { workspace = true }
[build-dependencies]
slint-build = { workspace = true, features = ["default"], optional = true }
# [package.metadata.wasm-pack.profile.release]
# wasm-opt = false