microui
buddy_alloc
Our great sponsors
microui | buddy_alloc | |
---|---|---|
13 | 7 | |
3,079 | 104 | |
- | - | |
0.0 | 7.8 | |
3 months ago | 3 months ago | |
C | C | |
MIT License | BSD Zero Clause License |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
microui
-
Immediate Mode GUI Programming
There is also microui, which I like[0].
Which I forked to work with SDL2[1], no guarantees. It's fun to hack on.
-
ImGui or text rendering libraries
For GUI, there are lots, most well-known of course being Dear Imgui, for which people have made auto-generated C bindings. Another mature but a lot simpler option is Nuklear, as others have mentioned. Even more minimalistic (it's just 1KLOC) is microui. There are a lot more, just google "imgui library c".
- A lightweight, simple, fast, feature-filled, text editor written in C, and Lua
-
Nuklear – A single-header ANSI C immediate mode cross-platform GUI library
The price for the 'lightest' UI toolkit probably goes to microui:
https://github.com/rxi/microui
Just around 1100 lines of C code.
You need to bring your own renderer, but that's the same for Nuklear or Dear ImGui.
I wrote a WASM wrapper for the microui demo too:
-
I made a shortlist of good libraries for my GUI C project and I want your thoughts and comments.
Good C library list: https://en.cppreference.com/w/c/links/libs https://github.com/Immediate-Mode-UI/Nuklear + C89, no dependencies, public license. 5/5 https://www.tecgraf.puc-rio.br/iup/ + good tutorial and wiki guides 5/5 https://libsdl.org/ + infinite possibilities - whole library for making games, forums, wiki - complicated, not many C tutorials, need to manage game states... 4/5 https://github.com/lvgl/lvgl + good docs - for embedded systems 4/5 https://github.com/ocornut/imgui + Popular, inspired Nuklear - for C++ 3/5 https://docs.enlightenment.org/api/imlib2/html/ + very efficient, used in Conky - uses X so only for Linux, just for displaying images and text and stuff 2/5 https://github.com/rxi/microui + simple, small - you need to handle your own drawing 2/5 GTK+ - no
- Best way to write a cross-platform graphical program in C while using only bare minimum third-party libraries?
- resources for making a gui library
-
Seeking your expert opinion and advice for an OpenGL client-server rendering framework
What about GUI like this: https://github.com/rxi/microui?
-
Easy to implement GUI for SDL 2
If you are using SDL with SDL_Renderer, try microui
-
What is your own favorite C project?
In terms of other people's projects: stb, microui, and nanovg come to mind
buddy_alloc
-
Open-source MISRA-compliant projects
I maintain a project that's not technically MISRA compliant (due to being a memory allocator and MISRA disallowing the very idea) and I keep it at 100% test coverage with support for multiple compilers and operating systems. Over time I had a few users reporting back - since it's working for them I count that as success. Is it wildly popular ? Of course not, but it doesn't have to be.
-
One year ago I wrote a buddy memory allocator - project update
In the last year I worked on profiling and optimizing it, I fixed a few bugs, added some new capabilities and gained some users. I recently tagged v0.4 - check it out at https://github.com/spaskalev/buddy_alloc/
You are right about the tests - they are written with 64-bit in mind. I ought to rework them to switch sizes based on arch but that will take a weekend. I've filed https://github.com/spaskalev/buddy_alloc/issues/19 to track this.
-
I'm giving out microgrants to open source projects for the third year in a row! Brag about your projects here so I can see them, big or small!
I'm the author of https://github.com/spaskalev/buddy_alloc - a custom memory allocator for C (modern C11, works with C++ as well) designed for predictable and repeatable performance. It is suitable for use in embedded, games and any other system with soft or hard real-time demands. It has 100% line and branch test coverage and uses a fixed amount of space on the call stack when called. Recently the project had its first external contribution as well. Cheers!
-
What is your own favorite C project?
I made a memory allocator that turned out rather neat - https://github.com/spaskalev/buddy_alloc
What are some alternatives?
imgui - Dear ImGui: Bloat-free Graphical User interface for C++ with minimal dependencies
sokol - minimal cross-platform standalone C headers
rpmalloc - Public domain cross platform lock free thread caching 16-byte aligned memory allocator implemented in C
nanovg - Antialiased 2D vector drawing library on top of OpenGL for UI and visualizations.
pixeltoaster - PixelToaster is a framebuffer library for C++
minifb - MiniFB is a small cross platform library to create a frame buffer that you can draw pixels in
nuklear
gunslinger - C99, header-only framework for games and multimedia applications
VulkanMemoryAllocator - Easy to integrate Vulkan memory allocation library
rotate - [WIP] static typed programming language that compiles to vm bytecode
pacman.c - Simple Pacman clone written in C99.
pns