4 ms·
The only UI framework I’ve ever used that I didn’t absolute hate is DearImGui. I realize it doesn’t produce polished, professional looking UIs. But my god is it
by forrestthewoods 2y ago
The only UI framework I’ve ever used that I didn’t absolute hate is DearImGui. I realize it doesn’t produce polished, professional looking UIs. But my god is it the only thing that doesn’t suck.
JavaScript and ReactJS are at least 10 times less efficient to write than C++ Dear ImGui. That’s so crazy.
- andrewmcwatters 2y agoDear ImGui isn't for end-user facing UI.
- forrestthewoods 2y agoDid you read my whole comment? It feels like you didn’t read my whole comment. Because I said “I realize it doesn’t produce polished, professional looking UIs”. I don’t think that’s an intrinsic quality of a DearImGui type API design. I’m reasonably confident it could produce a professional end-user facing UI. And that it would be perfectly performant and battery efficient.
- lmz 2y agoGood luck making that immediate UI accessible.
- forrestthewoods 2y agoWhy is immediate-mode fundamentally incompatible with accessibility?
- lmz 2y agoReact is "immediate" so it probably could work. However the accessibility tools in that case operate on the rendered DOM layer. Without such a "retained" structure it would be very hard. You can imagine web accessibility tools wouldn't like it either if you rebuilt the whole DOM on every change instead of only updating the changed parts.
- hombre_fatal 2y agoYeah, drawing everything to the screen every frame makes a lot of things easy. You can just update state and it will get drawn on the next frame. DOM UI libraries like React have the harder problem of surgical tree updates since they can't just redraw from scratch. It's where all of their complexity comes from. Not even React's basic primitives like useState would be necessary if you were just going to redraw the whole UI on the next frame.
- elcritch 2y agoI feel the same about DearImGui. Want a list of sliders, bam, it’s done. So I started working to create my own UI framework with some of the DearImGui feel but being a bit more scalable. Recently I just added basic CSS [1]. Super fun to get it working but it’s been a lot of work combining UI styles. But it’s cool getting 60fps live animations in a 4mb binary. Hopefully CSS can help get it looking good. 1: https://blog.elcritch.net/why-i-settled-on-css-for-theming-in-figuro https://blog.elcritch.net/why-i-settled-on-css-for-theming-i...