pub struct TerminalInputParser { /* private fields */ }Expand description
Stateful VT100 / xterm / CSI / SS3 / SGR-1006 mouse and bracketed-paste byte stream parser.
Implementations§
Source§impl TerminalInputParser
VT/xterm keyboard, mouse, and bracketed-paste stream decoding for TerminalInputParser.
impl TerminalInputParser
VT/xterm keyboard, mouse, and bracketed-paste stream decoding for TerminalInputParser.
Sourcepub fn feed(&mut self, wid: WindowId, bytes: &[u8]) -> Vec<WindowEvent>
pub fn feed(&mut self, wid: WindowId, bytes: &[u8]) -> Vec<WindowEvent>
Parses incoming raw terminal bytes bytes into ordered EUV WindowEvents, buffering incomplete sequences across chunks.
§Arguments
&Self- Mutable parser state.WindowId- Target window identifier.&[u8]- Newly received raw terminal input bytes.
§Returns
Vec<WindowEvent>- Decoded keyboard, text, mouse, scroll, and terminate events.
Source§impl TerminalInputParser
impl TerminalInputParser
pub fn get_pending(&self) -> &Vec<u8> ⓘ
pub fn get_mut_pending(&mut self) -> &mut Vec<u8> ⓘ
pub fn set_pending(&mut self, val: Vec<u8>) -> &mut Self
pub fn get_in_paste(&self) -> bool
pub fn get_mut_in_paste(&mut self) -> &mut bool
pub fn set_in_paste(&mut self, val: bool) -> &mut Self
pub fn get_paste_buffer(&self) -> &String
pub fn get_mut_paste_buffer(&mut self) -> &mut String
pub fn set_paste_buffer(&mut self, val: String) -> &mut Self
pub fn get_cell_width_px(&self) -> f32
pub fn get_mut_cell_width_px(&mut self) -> &mut f32
pub fn set_cell_width_px(&mut self, val: f32) -> &mut Self
pub fn get_cell_height_px(&self) -> f32
pub fn get_mut_cell_height_px(&mut self) -> &mut f32
pub fn set_cell_height_px(&mut self, val: f32) -> &mut Self
Trait Implementations§
Source§impl Clone for TerminalInputParser
impl Clone for TerminalInputParser
Source§impl Debug for TerminalInputParser
impl Debug for TerminalInputParser
Source§impl Default for TerminalInputParser
Default TerminalInputParser using standard 8x16 cell metrics.
impl Default for TerminalInputParser
Default TerminalInputParser using standard 8x16 cell metrics.
Source§impl PartialEq for TerminalInputParser
impl PartialEq for TerminalInputParser
impl StructuralPartialEq for TerminalInputParser
Auto Trait Implementations§
impl Forget for TerminalInputParser
impl Freeze for TerminalInputParser
impl Move for TerminalInputParser
impl RefUnwindSafe for TerminalInputParser
impl Send for TerminalInputParserwhere
RawVecInner: Send,
impl Sync for TerminalInputParserwhere
RawVecInner: Sync,
impl Unpin for TerminalInputParser
impl UnsafeUnpin for TerminalInputParser
impl UnwindSafe for TerminalInputParserwhere
RawVecInner: UnwindSafe,
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
Mutably borrows from an owned value. Read more