[−][src]Struct makepad_render::Text
Fields
text_style: TextStyle
shader: Shader
color: Color
z: f32
wrapping: Wrapping
font_scale: f32
Methods
impl Text
[src]
pub fn new(cx: &mut Cx) -> Self
[src]
pub fn instance_font_tc() -> InstanceVec4
[src]
pub fn instance_color() -> InstanceColor
[src]
pub fn instance_x() -> InstanceFloat
[src]
pub fn instance_y() -> InstanceFloat
[src]
pub fn instance_w() -> InstanceFloat
[src]
pub fn instance_h() -> InstanceFloat
[src]
pub fn instance_z() -> InstanceFloat
[src]
pub fn instance_base_x() -> InstanceFloat
[src]
pub fn instance_base_y() -> InstanceFloat
[src]
pub fn instance_font_size() -> InstanceFloat
[src]
pub fn instance_marker() -> InstanceFloat
[src]
pub fn instance_char_offset() -> InstanceFloat
[src]
pub fn uniform_brightness() -> UniformFloat
[src]
pub fn uniform_curve() -> UniformFloat
[src]
pub fn def_text_shader() -> ShaderGen
[src]
pub fn begin_text(&mut self, cx: &mut Cx) -> AlignedInstance
[src]
pub fn add_text<F>(
&mut self,
cx: &mut Cx,
geom_x: f32,
geom_y: f32,
char_offset: usize,
aligned: &mut AlignedInstance,
chunk: &[char],
char_callback: F
) where
F: FnMut(char, usize, f32, f32) -> f32,
[src]
&mut self,
cx: &mut Cx,
geom_x: f32,
geom_y: f32,
char_offset: usize,
aligned: &mut AlignedInstance,
chunk: &[char],
char_callback: F
) where
F: FnMut(char, usize, f32, f32) -> f32,
pub fn end_text(&mut self, cx: &mut Cx, aligned: &AlignedInstance) -> Area
[src]
pub fn draw_text(&mut self, cx: &mut Cx, text: &str) -> Area
[src]
pub fn find_closest_offset(&self, cx: &Cx, area: &Area, pos: Vec2) -> usize
[src]
pub fn get_monospace_base(&self, cx: &Cx) -> Vec2
[src]
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Text
impl Send for Text
impl Sync for Text
impl Unpin for Text
impl UnwindSafe for Text
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
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> 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 = Infallible
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>,