#imgui #ui #graphics #gui-applications #gui-framework

sys easy-imgui-sys

Low level bindings for the Dear ImGui C++ library

8 releases

new 0.3.0 Apr 11, 2024
0.2.4 Mar 22, 2024
0.2.2 Feb 26, 2024
0.1.1 Jan 27, 2024

#1114 in GUI

Download history 12/week @ 2024-01-22 4/week @ 2024-02-05 89/week @ 2024-02-12 36/week @ 2024-02-19 172/week @ 2024-02-26 3/week @ 2024-03-04 19/week @ 2024-03-11 330/week @ 2024-03-18 15/week @ 2024-03-25 55/week @ 2024-04-01

419 downloads per month
Used in 3 crates

MIT license

8MB
107K SLoC

C++ 95K SLoC // 0.2% comments Visual Studio Project 6.5K SLoC Objective-C++ 3.5K SLoC // 0.2% comments C 732 SLoC // 0.3% comments Visual Studio Solution 302 SLoC Batch 274 SLoC Rust 144 SLoC // 0.1% comments GLSL 64 SLoC Kotlin 60 SLoC // 0.1% comments Shell 4 SLoC // 0.7% comments GDB Script 2 SLoC // 0.9% comments

Contains (static library, 295KB) glfw3.lib, (static library, 295KB) glfw3.lib, (static library, 190KB) glfw3.lib, (static library, 190KB) glfw3.lib

easy-imgui-rs

build

Build full GUI applications with Rust and Dear ImGui. It currently uses version v1.90.5.

There are several crates in this repository:

See some examples at the examples directory. The simplest one is just a few lines of code:

use easy_imgui_window::{MainWindow, MainWindowWithRenderer,
    winit::event_loop::EventLoopBuilder,
    easy_imgui as imgui,
};

fn main() {
    let event_loop = EventLoopBuilder::new().build().unwrap();
    let main_window = MainWindow::new(&event_loop, "Example").unwrap();
    let mut window = MainWindowWithRenderer::new(main_window);

    let mut app = App;

    event_loop.run(move |event, w| {
        let res = window.do_event(&mut app, &event, w);
        if res.is_break() {
            w.exit();
        }
    }).unwrap();
}

struct App;

impl imgui::UiBuilder for App {
    fn do_ui(&mut self, ui: &imgui::Ui<Self>) {
        ui.show_demo_window(None);
    }
}

Dependencies