this post was submitted on 23 Sep 2025
24 points (96.2% liked)

Rust

7386 readers
7 users here now

Welcome to the Rust community! This is a place to discuss about the Rust programming language.

Wormhole

!performance@programming.dev

Credits

  • The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)

founded 2 years ago
MODERATORS
 

I can't figure out which crate(s) I should be using to create GUI applications. I only want to create simple 2D games like Conway's Game of Life, so I don't need anything fancy. At most I would like to be able to easily create polygons.

I've already looked at Are we game yet?, but it would be a waste of time to learn 20 different crates in order to decide on which one to use. Bevy is far too heavy and doesn't even work if you are low on memory. SDL3 isn't natively supported without some workarounds (but SDL2 is fine). Winit tries to use insecure X11 unless I manually add it as a dependency with the Wayland feature. I plan to eventually learn GTK4+Adwaitta, but that's unnecessary for simple games.

GUI in Rust seams like a mess. There's so many crates ranging from simple to complicated. Information becomes outdated quickly, so LLMs often fail to help. There's few clear comparisons between crates to help you decide, so it becomes a headache. I'm just looking for a modern, safe, easy, minimal GUI crate.

Does anyone have any advice?

you are viewing a single comment's thread
view the rest of the comments
[–] blazebra@programming.dev 1 points 1 week ago (1 children)

Currently I use WxWidgets and Cocoa for macOS.

The best would probably be pure native UI with static/dynamic library in Rust for logic. Sounds hard, but it’s the best option in my opinion.

My 2 cents is below. Your decision depends on your tasks, preferences and targets.

  • GPU framework maybe fast, but accessibility at 0
  • HTML backend is nice, but I can’t choice other than native, which limits me quite hard for target user base. And I don’t like JS if not strictly required (it’s a personal preference).
  • GTK on macOS and windows is quite hard to install and I don’t like visuals
  • QT is in grey zone if static (non-GPL project), and I haven’t found good way to bundle it if dynamic
  • ImGUI is nice but I don’t know if they support HiDPI monitors and accessibility is not the highest
  • fltk is nice, but 1) many things you’ll have to write by you own, rewriting sometimes from FLTK2 C++ code… and community could be more chill and friendly
  • Windows Metro UI… probably no crates
  • Win32 API GUI works perfect
  • Swift… probably yes, but it’s very OS-dependent
  • Cocoa — very nice for macOS.
  • current stop is WxWidgets: small, embedded, look… ok for now.
  • there’s some framework for iOS and Android, looks fine for me, but not my target ATM.
[–] blazebra@programming.dev 1 points 1 week ago

I’ve forgot slint. Same as QT