pub struct TextBox {
pub id: u64,
pub rect: (f32, f32, f32, f32),
pub content: String,
pub font_size: f32,
pub color: [u8; 4],
pub background: Option<[u8; 4]>,
}Expand description
A positioned text overlay on a slide.
Fields§
§id: u64Unique identifier for this text box.
rect: (f32, f32, f32, f32)Normalized position and size: (x, y, w, h) in 0..1 coordinates.
content: StringTypst markup content.
font_size: f32Font size in points.
color: [u8; 4]Text color as RGBA.
background: Option<[u8; 4]>Optional background fill as RGBA.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TextBox
impl RefUnwindSafe for TextBox
impl Send for TextBox
impl Sync for TextBox
impl Unpin for TextBox
impl UnsafeUnpin for TextBox
impl UnwindSafe for TextBox
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