frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

MicroUI – A tiny, portable, immediate-mode UI library written in ANSI C

https://github.com/rxi/microui
57•peter_d_sherman•2h ago

Comments

peter_d_sherman•2h ago
>"Features

o Tiny: around 1100 sloc of ANSI C

o Works within a fixed-sized memory region: no additional memory is allocated

o Built-in controls: window, scrollable panel, button, slider, textbox, label, checkbox, wordwrapped text

o Works with any rendering system that can draw rectangles and text

o Designed to allow the user to easily add custom controls

o Simple layout system"

Littice•2h ago
Immediate-mode in pure C is a nice constraint. how does it handle text rendering, do you bring your own atlas or is there something built in? Thats usually the part that balloons the dependency footprint.
ur-whale•1h ago
Nice, except the hard part seems to be missing: interfacing with an actual window system (X11, TUI, WIN32, whatever ...)
foul•1h ago
In demo/ someone can "steal" the renderer part which, being based on SDL, is to some extent cross-platform.
exDM69•1h ago
That's the whole point!

You plug it into your project and it can be rendered on anything that can push pixels and/or triangles to the screen. Events from windowing system go in, list of triangles comes out.

This is intended to be used with OpenGL, Vulkan, D3D and other graphics environment and used in cases where integrating a "real" GUI toolkit would be more trouble than it's worth.

Other popular libs like Dear Imgui or Egui work the same way.

abtinf•1h ago
The first thing I look for in any UI library is accessibility support. Makes it trivial to filter out toy projects.
spwa4•1h ago
Then just save yourself some time. Immediate mode and accessibility are mutually exclusive.
whizzter•1h ago
This is a library in similar vein to "Dear imgui", minimal requirements for integration (rectangle and text rendering) so that it's easy to embed into game-engines,etc for debug UI's and similar things.
monocasa•1h ago
Or, not every UI library is intended for use cases where a13y even makes sense.

Like a debug UI in a game engine, or in an embedded device that doesn't even have input for a13y.

xyzzy_plugh•1h ago
No. As much as I would like it to be the case, that is most certainly a poor criteria to evaluate a UI library.

Dear ImGui [0] is without a doubt the most prevalent immediate mode UI library. It does not have native accessibility features, but that hasn't stopped companies such as Intel, Meta, IKEA and Google from shipping products built upon it. It's also used in a ton of games.

Calling Dear ImGui a toy project at this point would be like calling Unreal Engine a toy project.

It's a shame accessibility support is not more widespread, and furthermore it's a shame that it is so laborious to add it.

0: https://github.com/ocornut/imgui/

synergy20•59m ago
how is this different from lvgl? is this immediate mode or retained mode?
kartoffelsaft•45m ago
This has been my goto for personal toy projects for a while now. Trivial to slot in to basically anything that can display text and takes mouse input.

I will mention, however, it's kinda abandonware at this point. There is some bug with the draw call iterator which does a misaligned pointer access, which, if your environment is set up to catch that, can get annoying (Zig for example panics on it). There's a github issue that some have used as reason to fork it but all the forks I tried were subtly wrong, for what that's worth.

afavour•45m ago
Cool to see a demo in there that you can run in a browser, presumably compiled to WebAssembly. The kind of thing that was unimaginable years ago.
OvervCW•29m ago
What is the advantage of this compared to Dear Imgui?
ranger_danger•20m ago
it's lighter weight and written in C
RodgerTheGreat•1h ago
"Accessibility" is an open-ended set of functionality, not a checkbox; it is never "complete", there is always room for improvement. Colorblind support (which ones)? High-Contrast mode? Adjustable text size? Screenreader integration? Localization? IME support? Keyboard navigation? Keyboard remapping? Functional entirely without a keyboard? Touch support? Pen support? Dyslexia-aiding typefaces? The list goes on and on.
jazzypants•56m ago
This is one of the reasons why web technology is so popular and persistent. You get almost all of that for free as long as you use semantic HTML.
Dwedit•30m ago
One clearly defined starting point is exposing any custom controls to accessibility APIs that are used to enumerate and interact (simulated mouse actions, reading the text, etc) with controls on the screen. Both scripting tools and screen readers make use of these. Built-in controls already have the enumeration and interaction feature and don't need additional code, but custom controls may not have that.

In the MicroUI example here, there are buttons and text labels and other kinds of controls, but no ability for an outside process to enumerate or interact with the controls. Any program will just set a single giant window with no text and no controls inside. Accessibility software can still hook text output APIs, but not if it also uses custom font rendering.

Anyway, the Windows accessibility API is just implementing a few COM objects, and COM (other than the specific ABI used for storing the vtable and function call convention) is not necessarily specific to Win32.

jdmoreira•27m ago
What? On a micro immediate mode UI?

Really insane comment TBH

Want your images back? Sure... That'll be $5!

https://www.lutr.dev/want-your-images-back-sure-that-ll-be-5-dollars
258•lutr•1h ago•106 comments

Epic Games announces Lore version control system

https://lore.org/
47•regnerba•19m ago•30 comments

GLM-5.2 is the new leading open weights model on Artificial Analysis

https://artificialanalysis.ai/articles/glm-5-2-is-the-new-leading-open-weights-model-on-the-artif...
437•himata4113•5h ago•238 comments

Sixty percent of US consumers say 'AI' in brand messaging is a turnoff

https://wpvip.com/future-of-the-web-2026/
444•thm•2h ago•242 comments

RFC 10008: The new HTTP Query Method

https://www.rfc-editor.org/info/rfc10008/
141•schappim•3h ago•72 comments

MicroUI – A tiny, portable, immediate-mode UI library written in ANSI C

https://github.com/rxi/microui
58•peter_d_sherman•2h ago•19 comments

Hacker News but for Independent Blogs

https://bubbles.town/
290•headalgorithm•7h ago•87 comments

Show HN: High-Res Neural Cellular Automata

https://cells2pixels.github.io/
128•esychology•5h ago•30 comments

GrapheneOS has been ported to Android 17

https://discuss.grapheneos.org/d/36469-grapheneos-has-been-ported-to-android-17-and-official-rele...
902•Cider9986•18h ago•474 comments

AI demands more engineering discipline. Not less

https://charitydotwtf.substack.com/p/ai-demands-more-engineering-discipline
28•BerislavLopac•29m ago•1 comments

Running local models is good now

https://vickiboykis.com/2026/06/15/running-local-models-is-good-now/
1443•jfb•1d ago•554 comments

Why stdx is not on crates.io

https://kerkour.com/stdx-cratesio
3•Keyb0ardWarri0r•5m ago•0 comments

Abandoned and Little-Known Airfields

https://airfields-freeman.com/
74•wizardforhire•2d ago•14 comments

Image Compression

https://www.makingsoftware.com/chapters/image-compression
38•vinhnx•3d ago•5 comments

Show HN: Inkwash, a watercolor sketching app and explanation

https://johnowhitaker.github.io/inkwash/about
25•Yenrabbit•3d ago•9 comments

Show HN: Capacitor Alarm Clock

https://github.com/ArcaEge/capacitor-alarm-clock
88•arcaege•3d ago•26 comments

GLM 5.2 Performance Benchmarks

https://artificialanalysis.ai/models/glm-5-2
88•theanonymousone•7h ago•27 comments

Map Clustering Is Not My Favorite

https://blog.greg.technology/2026/06/12/map-clustering-is-not-my-favorite.html
78•gregsadetsky•4d ago•29 comments

The Rise and (Potential) Fall of Letterboxd

https://www.statsignificant.com/p/the-rise-and-potential-fall-of-letterboxd
5•speckx•1w ago•0 comments

Humiliating IIS servers for fun and jail time

https://mll.sh/humiliating-iis-servers-for-fun-and-jail-time/
315•denysvitali•15h ago•78 comments

TIL: You can make HTTP requests without curl using Bash /dev/TCP

https://mareksuppa.com/til/bash-dev-tcp-http-without-curl/
497•mrshu•22h ago•214 comments

Subterranean fungi networks more than 100 quadrillion km in length

https://www.theguardian.com/science/2026/jun/11/arbuscular-mycorrhizal-fungi-plant-life-climate-g...
125•tosh•5d ago•32 comments

From Chesterton's fence to Chesterton's gap

https://stephantul.github.io/blog/unfence/
47•stephantul•7h ago•37 comments

Calvin and Hobbes and the price of integrity

https://therepublicofletters.substack.com/p/calvin-and-hobbes-and-the-price-of
501•pseudolus•23h ago•218 comments

Has AI already killed self-help nonfiction books?

https://tim.blog/2026/06/12/has-ai-already-killed-nonfiction/
366•imakwana•21h ago•415 comments

GPT‑NL: a sovereign language model for the Netherlands

https://www.tno.nl/en/digital/artificial-intelligence/gpt-nl/
238•root-parent•20h ago•272 comments

Wolfram Language and Mathematica version 15

https://writings.stephenwolfram.com/2026/06/launching-version-15-of-wolfram-language-mathematica-...
197•alok-g•15h ago•102 comments

Stop Using JWTs

https://gist.github.com/samsch/0d1f3d3b4745d778f78b230cf6061452
450•dzonga•22h ago•264 comments

Semiclassical Gravity Efficiently Solves NP-Complete Problems

https://arxiv.org/abs/2606.14806
59•ascarshen•11h ago•19 comments

SpaceX to buy Cursor for $60B

https://www.reuters.com/legal/transactional/spacex-buy-anysphere-60-billion-2026-06-16/
1085•itsmarcelg•1d ago•1583 comments