Просмотр исходного кода

docs: Update ARCHITECTURE.md to reflect Baked-in Lua defaults

Bernardo Magri 1 месяц назад
Родитель
Сommit
5fcd7912b9
1 измененных файлов с 4 добавлено и 1 удалено
  1. 4 1
      documentation/ARCHITECTURE.md

+ 4 - 1
documentation/ARCHITECTURE.md

@@ -65,7 +65,10 @@ To avoid circular dependencies (e.g., `BufferManager` needing `EditorCore` needi
 
 ### 5. Lua Integration (`lua_api.cpp`)
 - **Binding**: Uses `sol2` to bind C++ classes (`EditorCore`, `Buffer`, `Window`, `Config`, `Theme`) to Lua.
-- **Extension**: `init.lua` implements the "Standard Library" of the editor (Major Modes, default keybindings).
+- **Initialization Cascade**:
+    1.  **Baked-in Defaults (`src/defaults.hpp`)**: Loads essential keybindings and mode infrastructure from binary memory. Ensures the editor is always functional.
+    2.  **User Config (`init.lua`)**: Loads the user's configuration file (if found), overriding defaults.
+- **Extension**: `init.lua` (and the embedded defaults) implements the "Standard Library" of the editor (Major Modes, default keybindings).
 
 ## User Interface (Frontends)