[package]
edition = "2021"
rust-version = "1.87"
name = "rust_widgets"
version = "0.9.6"
authors = ["Mike Wolfli <mikewolfli@gmail.com>"]
build = false
include = [
"src/**/*",
"tests/**/*",
"benches/**/*",
"examples/**/*",
"include/**/*",
"tools/widget_gallery.rs",
"LICENSE",
"README.md",
"README.zh-CN.md",
"CHANGELOG.md",
"clippy.toml",
"rustfmt.toml",
]
autolib = false
autobins = false
autoexamples = false
autotests = false
autobenches = false
description = "Pure Rust cross-platform native GUI library with hardware-adaptive rendering, 60+ widgets, touch/gesture support, i18n, and SVG-pipeline-accurate output"
homepage = "https://github.com/mikewolfli/rust-widgets"
readme = "README.md"
keywords = [
"gui",
"widget",
"cross-platform",
"mobile",
"wasm",
]
categories = [
"gui",
"rendering",
"graphics",
"embedded",
"wasm",
]
license = "MIT"
repository = "https://github.com/mikewolfli/rust-widgets"
[package.metadata.docs.rs]
features = [
"full",
"touch",
"holographic",
"projection",
]
rustc-args = [
"--cfg",
"docsrs",
]
[badges.maintenance]
status = "actively-developed"
[features]
a11y = []
advanced-widgets = ["dep:dirs"]
android = ["dep:jni"]
android-jni = ["android"]
chart = []
cocoa-legacy = ["macos-legacy"]
controls-custom = []
controls-native = []
default = ["desktop"]
desktop = [
"os-auto",
"desktop-runtime",
"wgpu",
"touch",
"i18n",
"chart",
"print",
"pdf",
"a11y",
"quality-management",
"advanced-widgets",
"controls-native",
"controls-custom",
"dep:chrono",
"dep:serde",
"dep:serde_json",
]
desktop-runtime = [
"dep:notify",
"dep:crossbeam-channel",
]
embedded = [
"software",
"controls-custom",
]
full = [
"desktop",
"macos",
"macos-legacy",
"ios",
"linux-gtk",
"linux-wayland",
"linux-a11y",
"android",
"wasm",
"harmony",
"holographic",
"projection",
"unstable-pipeline-routing",
"unstable-special-widgets",
]
gpu = ["dep:wgpu"]
gpu-wgpu = [
"gpu",
"dep:pollster",
]
gtk-native = ["linux-gtk"]
harmony = []
holographic = []
i18n = []
ios = [
"dep:objc2",
"dep:objc2-foundation",
"dep:objc2-ui-kit",
]
ios-uikit-ffi = ["ios"]
linux-a11y = [
"dep:zbus",
"dep:pollster",
]
linux-gtk = ["dep:gtk"]
linux-wayland = [
"dep:wayland-client",
"dep:wayland-protocols",
"dep:wayland-cursor",
]
macos = [
"dep:objc2",
"dep:objc2-foundation",
"dep:objc2-app-kit",
"dep:objc2-core-graphics",
]
macos-legacy = [
"dep:cocoa",
"dep:objc",
"dep:objc-foundation",
]
mini = [
"software",
"controls-custom",
"dep:heapless",
"dep:hashbrown",
"dep:spin",
"dep:bumpalo",
]
mobile = [
"os-auto",
"wgpu",
"touch",
"i18n",
"quality-management",
"mobile-api",
"controls-native",
"controls-custom",
]
mobile-api = []
objc2-macos = ["macos"]
os-auto = []
pdf = []
print = []
projection = []
quality-management = []
software = []
tablet = [
"os-auto",
"wgpu",
"touch",
"i18n",
"quality-management",
"controls-native",
"controls-custom",
]
touch = []
unstable-pipeline-routing = []
unstable-special-widgets = []
wasm = [
"dep:wasm-bindgen",
"dep:web-sys",
"dep:js-sys",
]
wayland-native = ["linux-wayland"]
wgpu = ["gpu"]
windows = []
[lib]
name = "rust_widgets"
crate-type = [
"lib",
"cdylib",
]
path = "src/lib.rs"
[[example]]
name = "demo_button"
path = "examples/demo_button.rs"
[[example]]
name = "demo_code_editor"
path = "examples/demo_code_editor.rs"
[[example]]
name = "demo_list_view"
path = "examples/demo_list_view.rs"
[[example]]
name = "demo_main"
path = "examples/demo_main.rs"
[[example]]
name = "demo_map_view"
path = "examples/demo_map_view.rs"
[[example]]
name = "demo_media_player"
path = "examples/demo_media_player.rs"
[[example]]
name = "demo_terminal"
path = "examples/demo_terminal.rs"
[[example]]
name = "demo_wgpu_control_parity"
path = "examples/demo_wgpu_control_parity.rs"
[[example]]
name = "demo_window"
path = "examples/demo_window.rs"
[[example]]
name = "widget_gallery"
path = "tools/widget_gallery.rs"
[[test]]
name = "blue9_r1_api_symmetry_test"
path = "tests/blue9_r1_api_symmetry_test.rs"
[[test]]
name = "blue9_r6_platform_capability_test"
path = "tests/blue9_r6_platform_capability_test.rs"
[[test]]
name = "integration_test"
path = "tests/integration_test.rs"
[[test]]
name = "property_based_tests"
path = "tests/property_based_tests.rs"
[[test]]
name = "snapshot_tests"
path = "tests/snapshot_tests.rs"
[[bench]]
name = "event_bench"
path = "benches/event_bench.rs"
harness = false
[[bench]]
name = "json_bench"
path = "benches/json_bench.rs"
harness = false
[[bench]]
name = "layout_bench"
path = "benches/layout_bench.rs"
harness = false
[[bench]]
name = "render_bench"
path = "benches/render_bench.rs"
harness = false
[[bench]]
name = "signal_bench"
path = "benches/signal_bench.rs"
harness = false
[dependencies.bumpalo]
version = "3.16"
optional = true
default-features = false
[dependencies.chrono]
version = "0.4"
optional = true
[dependencies.crossbeam-channel]
version = "0.5"
optional = true
[dependencies.dirs]
version = "5.0"
optional = true
[dependencies.font8x8]
version = "0.2.7"
[dependencies.hashbrown]
version = "0.15"
features = ["alloc"]
optional = true
default-features = false
[dependencies.heapless]
version = "0.8"
optional = true
[dependencies.jni]
version = "0.21"
features = ["invocation"]
optional = true
[dependencies.js-sys]
version = "0.3"
optional = true
[dependencies.log]
version = "0.4"
[dependencies.notify]
version = "6.1"
optional = true
[dependencies.pollster]
version = "0.3"
optional = true
[dependencies.serde]
version = "1.0"
features = ["derive"]
optional = true
[dependencies.serde_json]
version = "1.0"
optional = true
[dependencies.spin]
version = "0.9"
optional = true
[dependencies.wasm-bindgen]
version = "0.2"
optional = true
[dependencies.web-sys]
version = "0.3"
features = [
"Window",
"Document",
"Element",
"HtmlElement",
"Node",
"Event",
"MouseEvent",
"KeyboardEvent",
"console",
"HtmlCanvasElement",
"CanvasRenderingContext2d",
"Clipboard",
"Navigator",
"Location",
]
optional = true
[dependencies.wgpu]
version = "29.0.3"
optional = true
[dev-dependencies.criterion]
version = "0.8.2"
[dev-dependencies.proptest]
version = "1.6"
[dev-dependencies.tempfile]
version = "3.8"
[target.'cfg(target_os = "harmony")'.dependencies]
[target.'cfg(target_os = "ios")'.dependencies.objc2]
version = "0.6"
optional = true
[target.'cfg(target_os = "ios")'.dependencies.objc2-foundation]
version = "0.3"
optional = true
[target.'cfg(target_os = "ios")'.dependencies.objc2-ui-kit]
version = "0.3"
optional = true
[target.'cfg(target_os = "linux")'.dependencies.gtk]
version = "0.18"
optional = true
[target.'cfg(target_os = "linux")'.dependencies.wayland-client]
version = "0.31"
optional = true
[target.'cfg(target_os = "linux")'.dependencies.wayland-cursor]
version = "0.31"
optional = true
[target.'cfg(target_os = "linux")'.dependencies.wayland-protocols]
version = "0.32"
features = [
"staging",
"client",
]
optional = true
[target.'cfg(target_os = "linux")'.dependencies.zbus]
version = "5"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.cocoa]
version = "0.24"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc]
version = "0.2"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc-foundation]
version = "0.1"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc2]
version = "0.6"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc2-app-kit]
version = "0.3"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc2-core-graphics]
version = "0.3"
optional = true
[target.'cfg(target_os = "macos")'.dependencies.objc2-foundation]
version = "0.3"
optional = true
[target."cfg(windows)".dependencies.winapi]
version = "0.3"
features = [
"winuser",
"commctrl",
"commdlg",
"winbase",
"synchapi",
"wingdi",
"shellapi",
"ole2",
"combaseapi",
"objbase",
"knownfolders",
"shlobj",
]
[lints.rust]
unexpected_cfgs = "allow"
[profile.release]
opt-level = 3
lto = "fat"
codegen-units = 1
[profile.release-embedded]
opt-level = "s"
lto = true
codegen-units = 1
panic = "abort"
inherits = "release"
strip = true
[profile.release-mini]
opt-level = "z"
lto = true
codegen-units = 1
panic = "abort"
inherits = "release"
strip = true