This example demonstrates how an F4SE mod plugin integrates with DearModdingUI using the header-only C++ client (<DearModdingUI/Client.h>).
- Host Connection: Discovers
DearModdingUI.dllat runtime during F4SEkPostPostLoadwithout linking against host binaries. - Categorized Navigation: Groups related pages under structured categories (
kLightingCategory,kPresetsCategory,kToolsCategory) with Phosphor icons and sort order keys. - Multi-Page Layout:
- Overview & Status: Displays system summary, formatted status banners (
DrawStyledText), and live key-value readouts (DrawLabeledValue). - Volumetrics & Sun: Two-column settings table using
SettingsTableScopeand reusableFieldScope, complete with reset button handling. - Color Grading: Type-safe combo dropdown via
DrawChoicewith custom selection handling. - Telemetry: Live frame time plotting via
dmui::ui::PlotLinesand host status reporting (SetStatus). - Console: A focused overlay (
RequestOverlayFocus) toggled by a hotkey action, withdmui::ui::InputTextEditorhistory, Tab completion, a caret-anchoredBeginTooltipAtsuggestion list, and Escape that closes the popup before the console (ABI 2.1).
- Overview & Status: Displays system summary, formatted status banners (
- Command Palette Action: Registers a callable global action (
AddAction) accessible from the host menu search or action list. - Frame Lifecycle Observer: Samples frame deltas safely on the render thread via
AddFrameObserver.
The example builds directly via xmake:
xmake build example-plugin