pub struct CaretGeometry {
pub x: f32,
pub top: f32,
pub height: f32,
pub line: usize,
}Expand description
Caret placement for a logical byte, in run-local coords.
Fields§
§x: f32Visual x from the run origin (BiDi-correct).
top: f32Y of the caret rect top, from the run origin baseline of line 1.
Requires size metrics (TextGeometry::with_size); 0 otherwise.
height: f32Caret rect height (line height). Requires size metrics.
line: usize0-based visual line index the byte sits on.
Trait Implementations§
Source§impl Clone for CaretGeometry
impl Clone for CaretGeometry
Source§fn clone(&self) -> CaretGeometry
fn clone(&self) -> CaretGeometry
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CaretGeometry
impl Debug for CaretGeometry
Source§impl PartialEq for CaretGeometry
impl PartialEq for CaretGeometry
Source§fn eq(&self, other: &CaretGeometry) -> bool
fn eq(&self, other: &CaretGeometry) -> bool
Tests for
self and other values to be equal, and is used by ==.impl Copy for CaretGeometry
impl StructuralPartialEq for CaretGeometry
Auto Trait Implementations§
impl Freeze for CaretGeometry
impl RefUnwindSafe for CaretGeometry
impl Send for CaretGeometry
impl Sync for CaretGeometry
impl Unpin for CaretGeometry
impl UnsafeUnpin for CaretGeometry
impl UnwindSafe for CaretGeometry
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
§fn into_result(self) -> Result<T, RunSystemError>
fn into_result(self) -> Result<T, RunSystemError>
Converts this type into the system output type.