yaze 0.3.2
Link to the Past ROM Editor
 
Loading...
Searching...
No Matches
diagnostics_panel.h
Go to the documentation of this file.
1#ifndef YAZE_APP_EDITOR_CODE_DIAGNOSTICS_PANEL_H
2#define YAZE_APP_EDITOR_CODE_DIAGNOSTICS_PANEL_H
3
4// Renders a structured diagnostics list (file:line:col + severity) for the
5// assembly editor's build-output panel. When z3dk is the active backend,
6// diagnostics carry full location data; when Asar is active, AsarWrapper
7// best-effort populates the same shape so this panel is backend-agnostic.
8
9#include <functional>
10#include <span>
11#include <string>
12
14
15namespace yaze {
16namespace editor {
17
19 // Invoked when the user clicks a diagnostic row. Host is responsible for
20 // navigation (focus file tab, move cursor to line/column).
21 std::function<void(const std::string& file, int line, int column)>
23};
24
25// Draws the diagnostics list inline. Expected to be hosted inside an
26// ImGui child or panel window by the caller. Returns nothing — activation
27// is routed via the callback.
28void DrawDiagnosticsPanel(std::span<const core::AssemblyDiagnostic> diagnostics,
29 const DiagnosticsPanelCallbacks& callbacks);
30
31} // namespace editor
32} // namespace yaze
33
34#endif // YAZE_APP_EDITOR_CODE_DIAGNOSTICS_PANEL_H
void DrawDiagnosticsPanel(std::span< const core::AssemblyDiagnostic > diagnostics, const DiagnosticsPanelCallbacks &callbacks)
std::function< void(const std::string &file, int line, int column) on_diagnostic_activated)