pub struct Buffer<'a, B: CoreBuffer> {
pub core: Core<B>,
pub search: Vec<char>,
pub snippet: BTreeMap<String, String>,
pub yank: Yank,
pub lsp: Option<LSPClient>,
pub tabnine: Option<TabNineClient>,
/* private fields */
}
Fields§
§core: Core<B>
§search: Vec<char>
§snippet: BTreeMap<String, String>
§yank: Yank
§lsp: Option<LSPClient>
§tabnine: Option<TabNineClient>
Implementations§
Source§impl<'a, B: CoreBuffer> Buffer<'a, B>
impl<'a, B: CoreBuffer> Buffer<'a, B>
pub fn new( syntax_parent: &'a SyntaxParent, config: &'a ConfigWithDefault, ) -> Self
pub fn path(&self) -> Option<&Path>
pub fn storage(&self) -> Option<&dyn Storage<B>>
pub fn get_config<A: Key>(&self) -> Option<&'a A::Value>
pub fn extend_cache_duration(&mut self, duration: Duration)
pub fn indent_width(&self) -> usize
pub fn hard_tab(&self) -> bool
pub fn restart_completer(&mut self)
pub fn set_language(&mut self)
pub fn indent(&mut self)
pub fn set_storage<T: Storage<B> + 'static>(&mut self, storage: T)
pub fn open<S: Storage<B> + 'static>(&mut self, storage: S)
pub fn save(&mut self, is_optimize: bool) -> bool
pub fn show_cursor(&mut self)
pub fn show_cursor_middle(&mut self)
pub fn scroll_up(&mut self)
pub fn scroll_down(&mut self)
pub fn format(&mut self) -> Result<(), Cow<'static, str>>
pub fn compile(&mut self, is_optimize: bool)
pub fn last_compile_success(&self) -> Option<bool>
pub fn compiler_message_on_cursor(&self) -> Option<&str>
pub fn poll_compile_message(&mut self)
pub async fn wait_compile_message(&mut self)
pub fn is_compiling(&self) -> bool
pub fn draw(&mut self, view: TermView<'_>) -> Option<Cursor>
pub fn draw_with_selected<R: RangeBounds<Cursor>>( &mut self, view: TermView<'_>, selected: Option<R>, ) -> Option<Cursor>
Auto Trait Implementations§
impl<'a, B> !Freeze for Buffer<'a, B>
impl<'a, B> !RefUnwindSafe for Buffer<'a, B>
impl<'a, B> !Send for Buffer<'a, B>
impl<'a, B> !Sync for Buffer<'a, B>
impl<'a, B> Unpin for Buffer<'a, B>where
B: Unpin,
impl<'a, B> !UnwindSafe for Buffer<'a, B>
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
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>
Converts
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>
Converts
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