Step 132: library symbol browser

This commit is contained in:
Bill
2026-02-09 17:05:09 -07:00
parent ae95aeb303
commit dcc963f625
7 changed files with 194 additions and 2 deletions

View File

@@ -305,6 +305,7 @@ int main(int, char**) {
ImGui::MenuItem("Terminal", state.keys.getBinding("view.toggleTerminal").toString().c_str(),
&state.showTerminalPanel);
ImGui::MenuItem("Dependencies", nullptr, &state.showDependencyPanel);
ImGui::MenuItem("Libraries", nullptr, &state.showLibraryBrowserPanel);
ImGui::MenuItem("Settings", nullptr, &state.showSettingsPanel);
ImGui::MenuItem("LSP Servers...", nullptr, &state.showLspSettings);
if (state.active()) {
@@ -568,6 +569,21 @@ int main(int, char**) {
}
}
if (state.showLibraryBrowserPanel) {
ImGui::Begin("Libraries", &state.showLibraryBrowserPanel);
ImGui::PushFont(uiFont);
std::string insertText;
if (renderLibraryBrowser(state.libraryBrowser,
state.activeAST(),
state.libraryIndex,
insertText,
state.outputLog)) {
state.insertTextAtCursor(insertText);
}
ImGui::PopFont();
ImGui::End();
}
// ---------------------------------------------------------------
// Find / Replace bar (floating at top of editor)
// ---------------------------------------------------------------