forked from slint-ui/slint
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Cargo.toml
123 lines (104 loc) · 4.66 KB
/
Cargo.toml
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
# Copyright © SixtyFPS GmbH <info@slint.dev>
# SPDX-License-Identifier: GPL-3.0-only OR LicenseRef-Slint-Royalty-free-1.1 OR LicenseRef-Slint-commercial
[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.5.0"
categories = ["gui", "development-tools", "command-line-utilities"]
keywords = ["lsp", "ui", "toolkit"]
[package.metadata.bundle]
name = "Slint Live Preview"
icon = ["../../logo/slint-logo-small-light.png"]
[[bin]]
name = "slint-lsp"
path = "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]
# Remove once MSRV > 1.70 (1.70 does not yet work!):
slint = []
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-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:image", "dep:slint-build", "dep:i-slint-common"]
## 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 = []
default = ["backend-default", "renderer-femtovg", "preview"]
[dependencies]
i-slint-compiler = { workspace = true, features = ["display-diagnostics"] }
euclid = "0.22"
itertools = { workspace = true }
lsp-types = { version = "0.95.0", features = ["proposed"] }
rowan = "0.15.5"
serde = "1.0.118"
serde_json = "1.0.60"
dissimilar = "1.0.7"
# for the preview-engine feature
i-slint-backend-selector = { workspace = true, optional = true }
i-slint-common = { 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", "highlight", "internal"], optional = true }
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
clap = { version = "4.0", features = ["derive", "wrap_help"] }
crossbeam-channel = "0.5" # must match the version used by lsp-server
lsp-server = "0.7"
once_cell = "1.9.0"
# Enable image-rs' default features to make all image formats available for the preview
image = { version = "0.24.0", optional = true }
[target.'cfg(target_arch = "wasm32")'.dependencies]
console_error_panic_hook = "0.1.5"
js-sys = { version = "0.3.57" }
send_wrapper = { workspace = true }
serde-wasm-bindgen = "0.6.0"
wasm-bindgen = "0.2.80"
wasm-bindgen-futures = "0.4.30"
[dev-dependencies]
spin_on = "0.1"
[build-dependencies]
slint-build = { workspace = true, features = ["default"], optional = true }
# [package.metadata.wasm-pack.profile.release]
# wasm-opt = false