fix(external-editor): Move panel to Operations Hub, fix config key lookup

- Moved External Editor panel from AI Settings to External Tools tab in Operations Hub
- Fixed default_editor lookup to use nested [tools.default_editor] structure
- Added example entries for vscode, notepadpp, 10xEditor, rider, sublime
- Improved panel UI with section header and clearer formatting
This commit is contained in:
2026-05-07 19:27:07 -04:00
parent 6c8c8516c8
commit 0948cae5a0
3 changed files with 57 additions and 18 deletions
+22 -11
View File
@@ -871,8 +871,6 @@ class App:
self._render_system_prompts_panel()
if imgui.collapsing_header("RAG Settings"):
self._render_rag_panel()
if imgui.collapsing_header("External Editor"):
self._render_external_editor_panel()
self._render_agent_tools_panel()
imgui.end()
if self.ui_separate_usage_analytics and self.show_windows.get("Usage Analytics", False):
@@ -974,6 +972,9 @@ class App:
if not self.ui_separate_external_tools:
if imgui.begin_tab_item("External Tools")[0]:
self._render_external_tools_panel()
imgui.separator()
imgui.text("")
self._render_external_editor_panel()
imgui.end_tab_item()
if imgui.begin_tab_item("Workspace Layouts")[0]:
imgui.text("Experimental: Auto-switch layout by Tier")
@@ -4841,23 +4842,33 @@ def hello():
launcher = get_default_launcher()
editors = launcher.config.editors
default_name = launcher.config.default_editor
imgui.text("Configured Editors:")
imgui.text_colored(vec4(0.7, 0.7, 0.7, 1), "External Editor for Diff Viewing")
imgui.separator()
if not editors:
imgui.text_colored(vec4(1, 0.5, 0, 1), " No editors configured")
imgui.text("")
imgui.text("Add editors in config.toml:")
imgui.text(" [tools.text_editors]")
imgui.text(' vscode = "C:\\\\path\\\\to\\\\code.exe"')
imgui.text_colored(vec4(0.5, 0.8, 1, 1), ' [tools.text_editors.vscode]')
imgui.text(' path = "C:\\\\path\\\\to\\\\code.exe"')
imgui.text(' diff_args = ["--diff"]')
imgui.text("")
imgui.text_colored(vec4(0.5, 0.8, 1, 1), ' [tools.text_editors.notepadpp]')
imgui.text(' path = "C:\\\\Program Files\\\\Notepad++\\\\notepad++.exe"')
imgui.text(' diff_args = ["-multiInst", "-nosession"]')
imgui.text("")
imgui.text("Then set default in [tools.default_editor]")
else:
imgui.text("Configured Editors:")
for name, editor in editors.items():
is_default = name == default_name
marker = " (default)" if is_default else ""
imgui.text(f" {name}{marker}: {editor.path}")
imgui.text_colored(vec4(0.3, 0.9, 0.3, 1), f" {name}{marker}")
imgui.text(f" path: {editor.path}")
if editor.diff_args:
imgui.text(f" diff args: {editor.diff_args}")
imgui.text("")
imgui.text("Configuration:")
imgui.text(" Global: config.toml [tools.text_editors]")
imgui.text(" Project: manual_slop.toml default_editor")
imgui.text(f" diff: {editor.diff_args}")
imgui.text("")
imgui.text_colored(vec4(0.7, 0.7, 0.7, 1), "Config: config.toml [tools.text_editors]")
imgui.text_colored(vec4(0.7, 0.7, 0.7, 1), "Override: manual_slop.toml default_editor")
def _render_agent_tools_panel(self) -> None:
if imgui.collapsing_header("Active Tool Presets & Biases", imgui.TreeNodeFlags_.default_open):