[package]
name = "i-slint-backend-winit"
description = "Winit backend for Slint"
authors.workspace = true
edition.workspace = true
homepage.workspace = true
license.workspace = true
repository.workspace = true
rust-version.workspace = true
version.workspace = true
build = "build.rs"
[lib]
path = "lib.rs"
[features]
wayland = ["winit/wayland", "winit/wayland-csd-adwaita", "glutin?/wayland", "glutin-winit?/wayland", "copypasta/wayland", "i-slint-renderer-skia?/wayland", "softbuffer?/wayland", "softbuffer?/wayland-dlopen"]
x11 = ["winit/x11", "glutin?/x11", "glutin?/glx", "glutin-winit?/x11", "glutin-winit?/glx", "copypasta/x11", "i-slint-renderer-skia?/x11", "softbuffer?/x11", "softbuffer?/x11-dlopen"]
renderer-femtovg = ["dep:i-slint-renderer-femtovg", "dep:glutin", "dep:glutin-winit"]
renderer-skia = ["i-slint-renderer-skia", "winit/rwh_06"]
renderer-skia-opengl = ["renderer-skia", "i-slint-renderer-skia/opengl"]
renderer-skia-vulkan = ["renderer-skia", "i-slint-renderer-skia/vulkan"]
renderer-software = ["dep:softbuffer", "dep:imgref", "dep:rgb", "i-slint-core/software-renderer-systemfonts", "dep:bytemuck", "winit/rwh_06"]
accessibility = ["dep:accesskit", "dep:accesskit_winit"]
raw-window-handle-06 = ["winit/rwh_06"]
default = []
[dependencies]
i-slint-core = { workspace = true, features = ["default"] }
i-slint-core-macros = { workspace = true, features = ["default"] }
i-slint-common = { workspace = true, features = ["default"] }
cfg-if = "1"
derive_more = { workspace = true }
lyon_path = "1.0"
once_cell = "1.5"
pin-weak = "1"
scoped-tls-hkt = "0.1"
winit = { version = "0.30.2", default-features = false }
raw-window-handle = { version = "0.6", features = ["alloc"] }
scopeguard = { version = "1.1.0", default-features = false }
i-slint-renderer-femtovg = { workspace = true, features = ["default"], optional = true }
i-slint-renderer-skia = { workspace = true, features = ["default"], optional = true }
softbuffer = { workspace = true, optional = true, default-features = false }
imgref = { version = "1.6.1", optional = true }
rgb = { version = "0.8.27", optional = true }
bytemuck = { workspace = true, optional = true, features = ["derive"] }
[target.'cfg(target_arch = "wasm32")'.dependencies]
web-sys = { workspace = true, features=["HtmlInputElement", "HtmlCanvasElement", "Window", "Document", "Event", "KeyboardEvent", "InputEvent", "CompositionEvent", "DomStringMap", "ClipboardEvent", "DataTransfer"] }
wasm-bindgen = { version = "0.2" }
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
glutin = { workspace = true, optional = true, default-features = false, features = ["egl", "wgl"] }
glutin-winit = { version = "0.5", optional = true, default-features = false, features = ["egl", "wgl"] }
accesskit = { version = "0.17", optional = true }
accesskit_winit = { version = "0.23", optional = true }
copypasta = { version = "0.10", default-features = false }
[target.'cfg(not(any(target_family = "windows", target_os = "macos", target_os = "ios", target_arch = "wasm32")))'.dependencies]
ashpd = { version = "0.9.2" }
futures = { version = "0.3.31" }
[target.'cfg(target_os = "macos")'.dependencies]
objc2-app-kit = { version = "0.2.2" }
[build-dependencies]
cfg_aliases = { workspace = true }
[dev-dependencies]
slint = { path = "../../../api/rs/slint", default-features = false, features = ["std", "compat-1-2", "backend-winit", "renderer-software", "raw-window-handle-06"] }
[package.metadata.docs.rs]
features = ["wayland", "renderer-software", "raw-window-handle-06"]