alma 0.1.0

A Bevy-native modal text editor with Vim-style navigation.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
//! Editor command request messages.

use crate::ecs::components::buffer::{BufferEntity, ViewEntity};
use crate::vim::VimCommand;
use bevy::prelude::Message;

/// Request to execute a parsed editor command at the owner boundary.
#[derive(Clone, Copy, Debug, Eq, Message, PartialEq)]
pub struct CommandRequested {
    /// Editor buffer entity that owns text and persistence.
    pub target: BufferEntity,
    /// Editor view that submitted the command and should receive status.
    pub source: ViewEntity,
    /// Parsed command submitted by an input interpreter.
    pub command: VimCommand,
}