Feature Request: Expose GLFWwindow handle or otherwise allow means of registering certain callbacks
For example I want to handle drag & drop events in my app. This is easy to do with GLFW by calling glfwSetDropCallback(handle, callback). But the window handle isn't currently exposed so modifying Application.cpp is necessary.
If it's undesirable to expose GLFW I'd be fine with some other abstraction for setting the drop callback.
I recently used this framework to implement an application that uses the implot Immediate Mode Plotting library:
https://github.com/epezent/implot
I had to modify the Application.cpp file to create and destroy an ImPlot context inside of the ImGui::CreateContext / ImGui::DestroyContext:
Integration
- Set up an ImGui environment if you don't already have one.
- Add implot.h, implot_internal.h, implot.cpp, implot_items.cpp and optionally implot_demo.cpp to your sources. Alternatively, you can get ImPlot using vcpkg.
- Create and destroy an ImPlotContext wherever you do so for your ImGuiContext:
ImGui::CreateContext(); ImPlot::CreateContext(); ... ImPlot::DestroyContext(); ImGui::DestroyContext();
just modify the source code to expose whatever you need, it's an MIT license after all...