Skip to content

MadLadSquad/UntitledImGuiFramework

Repository files navigation

UntitledImGuiFramework

CI MIT license trello Discord

A desktop software development framework that uses dear imgui as its UI and rendering library.

NEW: Interactive web demo

You can try out the demo here.

Motivation

Desktop UI frameworks and libraries like QT and GTK are complicated and really rigid. Using them, or system-specific UI libraries would hard-lock us into using only what they use.

We also wanted a small and light core, which provides most-minimal features. We also wanted good developer experience, as QT and GTK seemed overengineered to us. Dear imgui filled all our requirements.

Dear imgui provides a GUI layer which provides the following benefits:

  • Light
  • Fast(graphically accelerated)
  • Immediate(rendering is done in the source code using function calls)
  • Doesn't require config files for layouts or style *
  • Easy to work with
  • Used by a multitude of high profile developers, an incomplete list can be seen here

* It depends on 1 for window management and compositing but it is small, autogenerated and is mainly used to save window coordinates for the next user session.

But the UntitledImGuiFramework provides many of the features that QT and GTK provides, how can you say that it is lighter then them!?

Yes, the framework provides many of the features that can be found in larger toolkits such as QT and GTK. The difference is that the UntitledImGuiFramework only provides a minimal renderer, component system and some interfaces for things like input out of the box.

To enable additional features, you need to enable modules, which can be compiled out of your application, as opposed to toolkits like QT and GTK, where many of the features that are modules here, are actually part of the core toolkit and cannot be removed. Here is a short list of features that we provide as modules that other libraries provide as part of their core:

  1. System font querying
  2. CLI parsing
  3. System theme fetching
  4. Rich text rendering
  5. Undo/Redo
  6. URL & default file/folder opening
  7. I18N features

Framework features

The above section says a lot, but let's talk features.

Interfaces

The framework provides access to many core features through so-called interfaces. Currently we have the following interfaces:

  1. Window interface - covers almost all parts of Window management on most platforms and even has additional X11 features
  2. Input interface - an easy way to deal with input devices, key bindings and more
  3. Renderer interface - gives you access to renderer settings
  4. Utility interface - contains many utility functions
  5. Plugins interface - allows you to interact with the built-in plugin support

Modules

The framework is divided into multiple modules compiled statically into your program. Users can fully decide which modules and submodules they want or don't want to include in their application. Module list and development status below:

  • Core Module ✅
    • Window ✅
    • Core ImGui rendering ✅
    • Textures ✅
    • Renderer subsystems ✅
      • OpenGL ✅
      • Vulkan ✅
      • WebGPU ✅
  • I18N module ✅
    • Adds the UntitledI18N library for internationalisation support
  • Plotting Module ✅
    • Adds ImPlot for plotting ✅
  • Knobs Module ✅
  • Spinner Module ✅
    • Adds imspinner for different spinner widgets ✅
  • Toggles Module ✅
    • Adds imgui_toggle library for different types of toggle widgets ✅
  • Text Utils Module ✅
    • Adds the UntitledImGuiTextUtils library that adds additional utility functions for easily rendering bold, italic, underlined and other types of text
  • Undo/Redo Module ✅
    • Adds Undo/Redo operation support ✅
  • CLI Args module ✅
  • Theming module ✅
  • OS Module for core OS interaction
    • URL and file/folder opener with default application using the UntitledOpen library ✅
    • Exec integration using the UntitledExec library ✅
    • Cross-platform system font querying using the UntitledFontUtils library ✅
    • Freedesktop: ✅

C & C++ APIs

The framework uses C++ as its main development language. Additionally, because we want to include support for full modability and plugins in mutiple languages, the user-facing API has a separate, completely C version that can be used to develop applications too!

Simply write the required bindings to your language or generate them automatically from C using a relevant tool. As long as you have the main engine library compiled you should easily be able to write applications in C or any other programming language that supports C style functions. C and C++ ABI stability of the core is generally guaranteed.

Native plugin support

The framework has native support for plugins with a handy plugin manager and interface that make it easy to make your application extensible from both C & C++, as well as other languages through the C & C++ APIs.

Supported platforms

We currently support the following platforms as official targets:

  1. Windows
  2. macOS
  3. Linux
  4. WASM

All of the operating systems above have generally the same features, as we're trying to have a generic platform to build desktop applications with.

The only exception is the Freedesktop submodule of the OS module, which provides more libraries for working with desktop environment features, that are otherwise baked into the core OS libraries, when talking about Windows and macOS.

And much more

There are countless more little useful features that we could name, here's a short list:

  1. Easy texturing
  2. Bundled with utilities for dealing with UTF-8/16/32
  3. Client-side header bar
  4. Comes with a library for logging
  5. Comes with a library for working with YAML files
  6. Is extensively documented with up-to-date and stable documenation

Learn

We provide an always up-to-date, stable and extensive documentation, which you can find on the wiki.

It is written as pure learning material, with code examples using both the C and C++ APIs. Aside from users of the framework, the documentation also covers topics such as:

  1. Shipping the application to production for package maintainers
  2. Plugin development examples
  3. Developer tips
  4. Internal documentation and reference
  5. Collaboration tips

Showcase and Progress

Coming soon, follow the UntitledDesktopEnvironment webpage for updates and some feature highlights.

Try out the new interactive web demo here.

There are many applications, already in production, that use the framework. A list can be found here. If your application uses the framework, please contribute to the list!

The organization trello board can be found here. It contains organization information on all projects related to UDE. The framework can be found in its corresponding cards.