Rust/fltk-rs desktop demo application that uses the fltk-rs GUI framework and persists data in a database-like binary file, performs a full CRUD, and displays a to-do list in GUI.
🤦 Yes, just another to-do application, but to try something new you have to start somewhere ¯\_(ツ)_/¯.
fltk-rs
is a Rust bindings for the FLTK Graphical User Interface library.
The fltk crate
is a cross-platform lightweight gui library which can be statically linked to produce small, self-contained and fast gui applications.
Why choose FLTK
?
- Lightweight. Small binary, around 1mb after stripping. Small memory footprint.
- Speed. Fast to install, fast to build, fast at startup and fast at runtime.
- Single executable. No DLLs to deploy.
- Supports old architectures.
FLTK
's permissive license which allows static linking for closed-source applications.- Themeability (5 supported schemes: Base, GTK, Plastic, Gleam and Oxy), and additional theming using fltk-theme.
- Provides around 80 customizable widgets.
- Has inbuilt image support.
Here is a list of software using FLTK. For software using fltk-rs, check here.
FLTK
offers a GUI WYSIWYG rapid application development tool called FLUID which allows creating GUI applications. Currently there is a video tutorial on youtube on using it with Rust: Use FLUID
(RAD tool) with Rust (more info here).
- Book
- Documentation
- Videos
- Examples
- Demos
- 7guis-fltk-rs
- FLTK-RS-Examples
- Erco's FLTK cheat page, which is an excellent FLTK C++ reference.
Use this library if you want something very, very light, quick to code and compile... and you like somewhat minimalist interfaces like me.🤓
Install the Rust toolchain and run the following command in the root directory of the project:
cargo run
Run the following command at the root of the project (it is necessary to have installed cargo bundle
in the system using cargo install
):
cargo bundle --release
Note
On Linux, if you install the application using the .deb
file, a .todo.dat
file will be generated in the user folder. We can establish the path of said file if we edit the application's preferences from its launcher.