Files
qbz/crates/vendor/i-slint-renderer-femtovg-1.16.1/Cargo.toml
T
vicrodh 5fc1beb869 fix(slint): vendor femtovg-wgpu renderer for transparent window surface
Slint 1.16's femtovg-wgpu renderer configures the wgpu surface via
get_default_config() and leaves the composite alpha mode at Auto, which
resolves to an opaque surface on KWin/Wayland — a borderless transparent
window then shows a black rectangular backing behind the rounded card.
WGPUConfiguration exposes no surface/alpha hook, so the only fix is a
renderer patch.

Vendor i-slint-renderer-femtovg-1.16.1 with a preferred_alpha_mode() that
picks a supported non-opaque mode (PreMultiplied / PostMultiplied /
Inherit, guarded by the surface's advertised alpha_modes, else Auto) and
wire it into set_surface(). Pulled in via [patch.crates-io]; Slint stays
pinned =1.16.1. The main window is unaffected (it paints opaque).

cx
2026-06-17 18:35:03 -06:00

143 lines
2.8 KiB
TOML

# THIS FILE IS AUTOMATICALLY GENERATED BY CARGO
#
# When uploading crates to the registry Cargo will automatically
# "normalize" Cargo.toml files for maximal compatibility
# with all versions of Cargo and also rewrite `path` dependencies
# to registry (e.g., crates.io) dependencies.
#
# If you are reading this file be aware that the original Cargo.toml
# will likely look very different (and much more reasonable).
# See Cargo.toml.orig for the original contents.
[package]
edition = "2024"
rust-version = "1.88"
name = "i-slint-renderer-femtovg"
version = "1.16.1"
authors = ["Slint Developers <info@slint.dev>"]
build = false
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "FemtoVG based renderer for Slint"
homepage = "https://slint.dev"
readme = "README.md"
license = "GPL-3.0-only OR LicenseRef-Slint-Royalty-free-2.0 OR LicenseRef-Slint-Software-3.0"
repository = "https://github.com/slint-ui/slint"
[package.metadata.docs.rs]
rustdoc-args = ["--generate-link-to-definition"]
[features]
default = []
opengl = []
unstable-wgpu-27 = []
unstable-wgpu-28 = [
"wgpu-28",
"i-slint-core/unstable-wgpu-28",
]
wgpu = ["wgpu-28"]
wgpu-28 = [
"dep:wgpu-28",
"femtovg/wgpu",
"i-slint-core/wgpu-28",
]
[lib]
name = "i_slint_renderer_femtovg"
path = "lib.rs"
[dependencies.cfg-if]
version = "1"
[dependencies.const-field-offset]
version = "0.2"
[dependencies.derive_more]
version = "2.0.0"
features = [
"deref",
"deref_mut",
"into",
"from",
"add",
"add_assign",
"mul",
"not",
"display",
]
default-features = false
[dependencies.femtovg]
version = "0.23.2"
features = ["swash"]
default-features = false
[dependencies.glow]
version = "0.17"
[dependencies.i-slint-common]
version = "=1.16.1"
features = [
"default",
"shared-fontique",
]
default-features = false
[dependencies.i-slint-core]
version = "=1.16.1"
features = [
"default",
"box-shadow-cache",
"shared-fontique",
"shared-parley",
]
default-features = false
[dependencies.i-slint-core-macros]
version = "=1.16.1"
features = ["default"]
default-features = false
[dependencies.imgref]
version = "1.6.1"
[dependencies.lyon_path]
version = "1.0"
default-features = false
[dependencies.pin-weak]
version = "1"
[dependencies.rgb]
version = "0.8.27"
[dependencies.wgpu-28]
version = "28"
optional = true
default-features = true
package = "wgpu"
[target.'cfg(target_arch = "wasm32")'.dependencies.wasm-bindgen]
version = "0.2"
[target.'cfg(target_arch = "wasm32")'.dependencies.web-sys]
version = "0.3.72"
features = [
"console",
"WebGlContextAttributes",
"CanvasRenderingContext2d",
"HtmlInputElement",
"HtmlCanvasElement",
"Window",
"Document",
]
default-features = false
[lints.rust.unexpected_cfgs]
level = "warn"
priority = 0
check-cfg = ["cfg(slint_nightly_test)"]