Expand description
A standalone editor component for GPUI
This crate provides a text editor widget for GPUI applications with syntax highlighting support.
§Architecture
The editor is structured in three layers:
- Editor: The core data model and editing operations
- EditorElement: The GPUI element that renders an Editor
- EditorView: A complete view with keyboard handling (see examples)
Re-exports§
pub use buffer::GapBuffer;pub use buffer::TextBuffer;pub use editor::CursorPosition;pub use editor::Editor;pub use editor::EditorConfig;pub use element::EditorElement;pub use syntax_highlighter::SyntaxHighlighter;pub use gpui;
Modules§
- buffer
- Gap buffer implementation for efficient text editing.
- editor
- element
- GPUI Element implementation for rendering an Editor
- syntax_
highlighter
Structs§
- Binding
Builder - Helper to create multiple bindings with the same context
- Binding
Spec - Specification for a key binding
- Keymap
- Represents a complete keymap configuration
- Keymap
Collection - A collection of keymaps, typically loaded from multiple files
- Meta
Line - Selection
Enums§
Functions§
- bind
- Helper to create a single binding
- create_
bindings - Helper to create a list of key bindings from action-keystroke pairs