pub struct TranslatorRenderState {
pub builtins: Builtins,
pub keymap: KeymapHandle,
pub partial_chord: Arc<[KeyChord]>,
pub active_minor_modes: Arc<[ModeId]>,
}Expand description
Translator inputs for the renderer’s input loop.
Phase 5.8.AF.5 / Slice 3c.final.B (group 5) — closes the
audit’s slice-D holdout for the TranslateContext &'a borrow
batch (builtins, keymap, partial_chord). The translator
runs on the renderer thread; in the slice-E end-state it can
no longer borrow through &Editor. Publishing these inputs as
owned/Arc-backed values lets runtime.rs build a
TranslateContext from a single snapshot load per keystroke.
All three fields are cheap to publish:
builtinsisCopyso the field is a plain move.keymapis anArc<KeymapRegistry>-backed handle;Cloneis one Arc bump andresolve()stays wait-free via the handle’s internalArcSwap.partial_chordis small (typically 0–2 entries during a chord sequence) so the per-publishArc<[KeyChord]>clone is sub-µs.
Fields§
§builtins: Builtins§keymap: KeymapHandle§partial_chord: Arc<[KeyChord]>§active_minor_modes: Arc<[ModeId]>D.5.b (2026-05-30): active buffer’s minor modes,
snapshotted at publish time and threaded into
TranslateContext so chord bindings registered against
MinorMode(ModeId) layers gate on per-buffer
activation (K.1.c). Empty in headless / mid-boot when
no buffer has been activated yet. One Arc bump per
publish; the slice is typically 0–3 entries
(diff-mode, completion-popup-mode,
active-snippet-mode in the busiest realistic case).
Trait Implementations§
Source§impl Clone for TranslatorRenderState
impl Clone for TranslatorRenderState
Source§fn clone(&self) -> TranslatorRenderState
fn clone(&self) -> TranslatorRenderState
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for TranslatorRenderState
impl Debug for TranslatorRenderState
Source§impl Default for TranslatorRenderState
impl Default for TranslatorRenderState
Source§fn default() -> TranslatorRenderState
fn default() -> TranslatorRenderState
Auto Trait Implementations§
impl !RefUnwindSafe for TranslatorRenderState
impl !UnwindSafe for TranslatorRenderState
impl Freeze for TranslatorRenderState
impl Send for TranslatorRenderState
impl Sync for TranslatorRenderState
impl Unpin for TranslatorRenderState
impl UnsafeUnpin for TranslatorRenderState
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere
T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s.§impl<T> DowncastSync for T
impl<T> DowncastSync for T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more