pub struct EditorTabStatus { /* private fields */ }Expand description
Snapshot of an EditorTab state for frontend polling.
Implementations§
Source§impl EditorTabStatus
impl EditorTabStatus
Sourcepub fn session(&self) -> &DocumentSessionStatus
pub fn session(&self) -> &DocumentSessionStatus
Returns the underlying session status snapshot.
Sourcepub fn generation(&self) -> u64
pub fn generation(&self) -> u64
Returns the current tab generation counter.
Sourcepub fn document(&self) -> &DocumentStatus
pub fn document(&self) -> &DocumentStatus
Returns the current document status snapshot.
Sourcepub fn line_count(&self) -> LineCount
pub fn line_count(&self) -> LineCount
Returns the current document line count.
Sourcepub fn display_line_count(&self) -> usize
pub fn display_line_count(&self) -> usize
Returns the best-effort line count for viewport sizing and scrolling.
Sourcepub fn exact_line_count(&self) -> Option<usize>
pub fn exact_line_count(&self) -> Option<usize>
Returns the exact document line count when it is known.
Sourcepub fn is_line_count_exact(&self) -> bool
pub fn is_line_count_exact(&self) -> bool
Returns true when the current line count is exact.
Sourcepub fn line_ending(&self) -> LineEnding
pub fn line_ending(&self) -> LineEnding
Returns the currently detected line ending style.
Sourcepub fn backing(&self) -> DocumentBacking
pub fn backing(&self) -> DocumentBacking
Returns the current document backing mode.
Sourcepub fn has_edit_buffer(&self) -> bool
pub fn has_edit_buffer(&self) -> bool
Returns true when the document currently has a mutable edit buffer.
Sourcepub fn has_piece_table(&self) -> bool
pub fn has_piece_table(&self) -> bool
Returns true when the document is currently piece-table-backed.
Sourcepub fn background_activity(&self) -> &BackgroundActivity
pub fn background_activity(&self) -> &BackgroundActivity
Returns the current background activity.
Sourcepub fn background_issue(&self) -> Option<&BackgroundIssue>
pub fn background_issue(&self) -> Option<&BackgroundIssue>
Returns the most recent background open/save problem, if one is being retained.
Sourcepub fn close_pending(&self) -> bool
pub fn close_pending(&self) -> bool
Returns true when close_file() was requested while a background job
was active and the actual close is deferred until that job finishes.
Sourcepub fn loading_state(&self) -> Option<&FileProgress>
pub fn loading_state(&self) -> Option<&FileProgress>
Returns typed loading progress when a background open is active.
Sourcepub fn loading_phase(&self) -> Option<LoadPhase>
pub fn loading_phase(&self) -> Option<LoadPhase>
Returns the current loading phase when a background open is active.
Sourcepub fn save_state(&self) -> Option<&FileProgress>
pub fn save_state(&self) -> Option<&FileProgress>
Returns typed save progress when a background save is active.
Sourcepub fn is_loading(&self) -> bool
pub fn is_loading(&self) -> bool
Returns true while a background load is in progress.
Sourcepub fn cursor(&self) -> CursorPosition
pub fn cursor(&self) -> CursorPosition
Returns the current cursor position.
Trait Implementations§
Source§impl Clone for EditorTabStatus
impl Clone for EditorTabStatus
Source§fn clone(&self) -> EditorTabStatus
fn clone(&self) -> EditorTabStatus
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more