6 releases (3 breaking)
Uses new Rust 2024
| new 0.4.0 | Apr 11, 2026 |
|---|---|
| 0.3.0 | Apr 8, 2026 |
| 0.2.1 | Mar 27, 2026 |
| 0.1.1 | Feb 28, 2026 |
#347 in Text editors
Used in 2 crates
(via redox-tui)
185KB
4.5K
SLoC
Core editor primitives.
This crate provides a rope-based text buffer (via ropey) and small, focused
navigation utilities suitable for implementing a Vim-like editor.
Notes on indexing
ropey::Ropeis UTF-8 text stored as a rope.- Most editing operations are most naturally expressed in char indices
(
usizecounts of Unicode scalar values), becauseropeyexposes many APIs in terms ofcharoffsets. - The UI may need byte indices for interoperability with external data, but those are not used as the primary index type in this crate.
redox-core
Core editor library for Redox.
This crate contains the editor primitives and behaviour that should stay independent of any UI:
- Rope-based text buffer (via
ropey) - Text indexing and cursor utilities (lines, columns, char indices, selections)
- Motions, text objects, search helpers, and small composable editing operations
Frontend crates should depend on redox-core and keep rendering, input mapping, and platform concerns outside this crate.
Dependencies
~670KB
~13K SLoC