Skip to main content

insert_text

Function insert_text 

Source
pub fn insert_text(
    doc: &mut RichDoc,
    pos: DocPos,
    text: &str,
    style: InlineStyle,
)
Expand description

Insert text (all in style) at pos. Adjacent identical-style runs are merged afterward, so passing the surrounding run’s style yields a seamless splice.