slint/api/sixtyfps-rs
2022-01-26 18:45:35 +01:00
..
LICENSES Update license information 2022-01-20 14:45:02 +01:00
sixtyfps-build Update to edition 2021 2022-01-25 11:40:11 +01:00
sixtyfps-macros Update to edition 2021 2022-01-25 11:40:11 +01:00
tests Mass update copyright messages to be more REUSE compliant 2021-12-22 10:06:12 +01:00
Cargo.toml Update to edition 2021 2022-01-25 11:40:11 +01:00
compile_fail_tests.rs Mass update copyright messages to be more REUSE compliant 2021-12-22 10:06:12 +01:00
docs Remove trailing slash from docs symlink 2020-09-07 11:22:55 +02:00
docs.rs Mass update copyright messages to be more REUSE compliant 2021-12-22 10:06:12 +01:00
lib.rs We don't need the resolver=2 with edition 2021 2022-01-25 11:40:11 +01:00
migration.md Migration docs: Remove one level of headlines 2022-01-26 18:45:35 +01:00
README.md Update the MSRV to 1.56, and test the generated code with edition 2021 2022-01-24 13:01:59 +01:00

SixtyFPS-rs

Crates.io Docs.rs

A Rust UI toolkit

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

The complete Rust documentation can be viewed online at https://sixtyfps.io/docs/rust/sixtyfps/.

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]
sixtyfps = "0.1.6"

And in your main.rs:

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

The sixtyfps 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 SixtyFPS that can be used as a starting point to your program.

cargo install cargo-generate
cargo generate --git https://github.com/sixtyfpsui/sixtyfps-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.56.0.