Home

Awesome

gtk4-rs CI

A group of crates that aims to provide complete GTK 4 bindings. This repository contains all the "core" crates of GTK 4.

The GTK 4 crates also depends on other libraries part of the platform like:

Those are common with the GTK 3 and GStreamer bindings and are part of the gtk-rs-core repository.

For more information about each crate, please refer to their README.md file in their directory.

Minimum supported Rust version

Currently, the minimum supported Rust version is 1.70.

Documentation

Useful links

Ecosystem

The gtk4-rs repository contains Rust crates for GTK 4. However there is a large ecosystem of GObject libraries and many of these libraries have Rust bindings based on the tooling included in gtk-rs. Of particular note:

Additionally, Rust bindings for various libraries are hosted on GNOME's GitLab instance and can be found at https://gitlab.gnome.org/World/Rust.

When using crates that are not part of the gtk4-rs repository, you will need to be careful and ensure that they do not pull in incompatible versions of core crates like glib-rs.

Built with GTK4 Rust bindings

A small list of applications built with gtk4-rs:

Libraries built with gtk4-rs:

Contributing

The bindings are composed of two parts:

The automatic ones can be generated using the generator.py script

python3 ./generator.py

If you didn't do so yet, please check out all the submodules before via

$ git submodule update --checkout

All the crates except gtk4-macros follow this structure

   ./crate 
   ├── Gir.toml
   ├── README.md
   ├── src
   │   ╰── auto
   ├── sys
   ╰── tests