6 releases

Uses new Rust 2021

0.2.4 May 9, 2022
0.2.3 May 9, 2022
0.2.1 Mar 10, 2022
0.2.0 Feb 10, 2022
0.0.0 Feb 1, 2022

#4 in Rendering engine

Download history 147/week @ 2022-03-12 106/week @ 2022-03-19 154/week @ 2022-03-26 156/week @ 2022-04-02 152/week @ 2022-04-09 140/week @ 2022-04-16 140/week @ 2022-04-23 254/week @ 2022-04-30 285/week @ 2022-05-07 305/week @ 2022-05-14 143/week @ 2022-05-21 151/week @ 2022-05-28 151/week @ 2022-06-04 117/week @ 2022-06-11 127/week @ 2022-06-18 80/week @ 2022-06-25

506 downloads per month
Used in 2 crates

GPL-3.0-only OR LicenseRef-Slint-commercial

785KB
14K SLoC

Slint

Crates.io Docs.rs

A Rust UI toolkit

Slint is a UI toolkit that supports different programming languages. Slint is the Rust API to interact with a Slint UI design from Rust.

The complete Rust documentation can be viewed online at https://slint-ui.com/docs/rust/slint/.

Getting Started

The crate documentation shows how to use this crate.

Hello World

The most basic "Hello world" application can be achieved with a few lines of code:

In your Cargo.toml add:

[dependencies]
slint = "0.2.4"

And in your main.rs:

slint::slint!{
    HelloWorld := Window {
        Text {
            text: "hello world";
            color: green;
        }
    }
}
fn main() {
    HelloWorld::new().run();
}

The slint crate documentation contains more advanced examples and alternative ways to use this crate.

To quickly get started, you can use the Template Repository with the code of a minimal application using Slint that can be used as a starting point to your program.

cargo install cargo-generate
cargo generate --git https://github.com/slint-ui/slint-rust-template

More examples

You can quickly try out the examples by cloning this repo and running them with cargo run

# Runs the "printerdemo" example
cargo run --release --bin printerdemo

Minimum Supported Rust Version

This crate's minimum supported rustc version is 1.59.

Dependencies

~7–20MB
~413K SLoC