pub struct CT_TextParagraph {
pub properties: Option<CT_TextParagraphProperties>,
pub runs: Vec<TextRun>,
pub end_properties: Option<CT_TextCharacterProperties>,
/* private fields */
}Expand description
A DrawingML paragraph with ordered runs, breaks, and fields.
Fields§
§properties: Option<CT_TextParagraphProperties>§runs: Vec<TextRun>§end_properties: Option<CT_TextCharacterProperties>Implementations§
Source§impl CT_TextParagraph
impl CT_TextParagraph
Sourcepub fn properties_mut(&mut self) -> &mut CT_TextParagraphProperties
pub fn properties_mut(&mut self) -> &mut CT_TextParagraphProperties
Returns direct properties, inserting them before preserved content.
Sourcepub fn set_text(&mut self, text: &str)
pub fn set_text(&mut self, text: &str)
Replaces ordered text choices with one regular run, split at each
vertical tab by an a:br with the run’s formatting, since a vertical
tab is how the paragraph text reports a line break.
The first existing regular run supplies direct formatting and unmodelled run content for the replacement. A paragraph without one formats the new run with its end-of-paragraph properties, without their hyperlinks, as PowerPoint formats text typed into an empty paragraph. Empty text leaves the paragraph properties and drops every run, including run-local preserved children.
Sourcepub fn add_run(&mut self, text: &str) -> &mut CT_RegularTextRun
pub fn add_run(&mut self, text: &str) -> &mut CT_RegularTextRun
Appends one regular run after the existing ordered text choices.
Sourcepub fn write_xml<W: Write>(&self, writer: &mut Writer<W>) -> Result<()>
pub fn write_xml<W: Write>(&self, writer: &mut Writer<W>) -> Result<()>
Writes a paragraph with fixed prefixes and schema child order.