[−][src]Struct makepad_widget::TextCursorSet
Fields
set: Vec<TextCursor>
last_cursor: usize
insert_undo_group: u64
last_clamp_range: Option<(usize, usize)>
Methods
impl TextCursorSet
[src]
pub fn new() -> TextCursorSet
[src]
pub fn get_all_as_string(&self, text_buffer: &TextBuffer) -> String
[src]
pub fn add_last_cursor_head_and_tail(
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
[src]
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
pub fn clear_and_set_last_cursor_head_and_tail(
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
[src]
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
pub fn set_last_cursor_head(
&mut self,
offset: usize,
text_buffer: &TextBuffer
) -> bool
[src]
&mut self,
offset: usize,
text_buffer: &TextBuffer
) -> bool
pub fn clear_and_set_last_cursor_head(
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
[src]
&mut self,
offset: usize,
text_buffer: &TextBuffer
)
pub fn get_last_cursor_text_pos(&self, text_buffer: &TextBuffer) -> TextPos
[src]
pub fn get_last_cursor_order(&self) -> (usize, usize)
[src]
pub fn get_last_cursor_singular(&self) -> Option<usize>
[src]
pub fn is_last_cursor_singular(&self) -> bool
[src]
pub fn grid_select_corner(
&mut self,
new_pos: TextPos,
text_buffer: &TextBuffer
) -> TextPos
[src]
&mut self,
new_pos: TextPos,
text_buffer: &TextBuffer
) -> TextPos
pub fn grid_select(
&mut self,
start_pos: TextPos,
end_pos: TextPos,
text_buffer: &TextBuffer
) -> bool
[src]
&mut self,
start_pos: TextPos,
end_pos: TextPos,
text_buffer: &TextBuffer
) -> bool
pub fn set_last_clamp_range(&mut self, range: (usize, usize))
[src]
pub fn clear_last_clamp_range(&mut self)
[src]
pub fn insert_newline_with_indent(&mut self, text_buffer: &mut TextBuffer)
[src]
pub fn replace_text(&mut self, text: &str, text_buffer: &mut TextBuffer)
[src]
pub fn insert_around(
&mut self,
pre: &str,
post: &str,
text_buffer: &mut TextBuffer
)
[src]
&mut self,
pre: &str,
post: &str,
text_buffer: &mut TextBuffer
)
pub fn overwrite_if_exists_or_deindent(
&mut self,
thing: &str,
deindent: usize,
text_buffer: &mut TextBuffer
)
[src]
&mut self,
thing: &str,
deindent: usize,
text_buffer: &mut TextBuffer
)
pub fn delete(&mut self, text_buffer: &mut TextBuffer)
[src]
pub fn backspace(&mut self, text_buffer: &mut TextBuffer, undo_id: u64)
[src]
pub fn insert_tab(&mut self, text_buffer: &mut TextBuffer, tab_str: &str)
[src]
pub fn replace_lines_formatted(
&mut self,
out_lines: Vec<Vec<char>>,
text_buffer: &mut TextBuffer
)
[src]
&mut self,
out_lines: Vec<Vec<char>>,
text_buffer: &mut TextBuffer
)
pub fn remove_tab(&mut self, text_buffer: &mut TextBuffer, num_spaces: usize)
[src]
pub fn select_all(&mut self, text_buffer: &mut TextBuffer)
[src]
pub fn move_home(&mut self, only_head: bool, text_buffer: &TextBuffer)
[src]
pub fn move_end(&mut self, only_head: bool, text_buffer: &TextBuffer)
[src]
pub fn move_up(
&mut self,
line_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
line_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn move_down(
&mut self,
line_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
line_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn move_left(
&mut self,
char_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
char_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn move_right(
&mut self,
char_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
char_count: usize,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn get_nearest_token_chunk_boundary(
left: bool,
offset: usize,
text_buffer: &TextBuffer
) -> usize
[src]
left: bool,
offset: usize,
text_buffer: &TextBuffer
) -> usize
pub fn get_nearest_token_chunk(
offset: usize,
text_buffer: &TextBuffer
) -> Option<(usize, usize)>
[src]
offset: usize,
text_buffer: &TextBuffer
) -> Option<(usize, usize)>
pub fn move_left_nearest_token(
&mut self,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn move_right_nearest_token(
&mut self,
only_head: bool,
text_buffer: &TextBuffer
)
[src]
&mut self,
only_head: bool,
text_buffer: &TextBuffer
)
pub fn get_token_highlight(&self, text_buffer: &TextBuffer) -> Vec<char>
[src]
pub fn get_selection_highlight(&self, text_buffer: &TextBuffer) -> Vec<char>
[src]
Trait Implementations
impl Clone for TextCursorSet
[src]
fn clone(&self) -> TextCursorSet
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Auto Trait Implementations
impl Send for TextCursorSet
impl Sync for TextCursorSet
impl Unpin for TextCursorSet
impl UnwindSafe for TextCursorSet
impl RefUnwindSafe for TextCursorSet
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,