refactor(lsp): replace LSPManager with controller-based architecture

- Remove legacy LSPManager dialog implementation
- Introduce LSPController as the central LSP entry point
- Route UI interactions through lsp_controller.lsp_manager_ui
- Move client lifecycle handling out of ProviderResponseCache
- Simplify completion cache and matcher filtering
- Improve LSP completion item parsing with safer fallbacks
- Modernize typing (Python 3.10 union syntax)
- Remove unused imports and dead code
- Use GLib.idle_add for safe UI scrolling operations
- Minor comment and spelling fixes
This commit is contained in:
2026-03-11 23:17:57 -05:00
parent 060f68237b
commit 71bab687d7
21 changed files with 602 additions and 175 deletions

View File

@@ -9,6 +9,7 @@ from gi.repository import GtkSource
from gi.repository import Gtk
from gi.repository import Gdk
from gi.repository import Gio
from gi.repository import GLib
# Application imports
from ..command_helpers import update_info_bar_if_focused
@@ -35,6 +36,10 @@ def execute(
update_info_bar_if_focused(view.command, view)
view.emit("focus-in-event", Gdk.Event())
buffer = view.get_buffer()
itr = buffer.get_iter_at_mark( buffer.get_insert() )
view.scroll_to_iter(itr, 0.2, False, 0, 0)
def scroll_to_insert_itr(view):
buffer = view.get_buffer()
itr = buffer.get_iter_at_mark( buffer.get_insert() )
view.scroll_to_iter(itr, 0.2, False, 0, 0)
GLib.idle_add(scroll_to_insert_itr, view)