pub struct Content {
Show 14 fields pub fit: Vec<String>, pub doc: String, pub include: String, pub include_html: bool, pub math: String, pub img: InlineList<Img>, pub video: InlineList<Video>, pub iframe: InlineList<IFrame>, pub lay_img: InlineList<LayImg>, pub frag: FragMap, pub h_stack: Vec<Self>, pub v_stack: Vec<Self>, pub h_stack_border: Vec<Self>, pub v_stack_border: Vec<Self>,
}
Expand description

A content block, which visualize all contents in the layout.

The attributes will placed in the following order.

Fields§

§fit: Vec<String>

Fit texts.

  • Longer text will be smaller.
  • Special symbol --- represents horizontal line <hr/>.
§doc: String

Multiline Markdown text, accept HTML.

§include: String

Include a Markdown file from path, append after doc.

§include_html: bool

If you want to include an HTML file without conversion, enable this option.

§math: String

Latex math without $$ / \[\] brackets.

§img: InlineList<Img>

Embed images.

§video: InlineList<Video>

Embed videos.

§iframe: InlineList<IFrame>

Embed <iframe> structures, such as YouTube videos.

§lay_img: InlineList<LayImg>

Layout stack for images.

§frag: FragMap

Fragment option.

§h_stack: Vec<Self>

Horizontal stack.

§v_stack: Vec<Self>

Vertical stack.

§h_stack_border: Vec<Self>

Horizontal stack with border.

§v_stack_border: Vec<Self>

Vertical stack with border.

Trait Implementations§

Returns the “default value” for a type. Read more
Deserialize this value from the given Serde deserializer. Read more
Consume option self into HTML string. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Should always be Self
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.
Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more