Main Content

Paragraph

Insert paragraph text into report

Description

This component inserts a paragraph into the report. The paragraph text is taken from a child text component, or from text that you enter in the Paragraph Text field.

Title Options

  • No paragraph title (default): Specifies no title for the paragraph.

  • Get title from first child: Gets the title of the paragraph from its first child component, which should be a Text component.

  • Custom title: Specifies a custom title for the paragraph.

Style Name

Specifies a style to use for the paragraph title for reports whose output format is one of the from template types, for example, Direct PDF (from template). By default, this option specifies the rgParagraphTitle style defined by the Report Explorer's default document conversion templates. To modify the appearance of all paragraph titles in a report, customize the rgParagraphTitle style in the report template. To modify the appearance of this title only, specify another style defined in the report template. To specify another style:

  1. In the Paragraph properties dialog box, set Title Options to one of these values:

    • Get title from first child

    • Custom title

  2. Set Style Name to Specify.

  3. In the Style Name text box, type a style name.

    To use the custom style you specify, it must be a paragraph style (or a linked paragraph/character style for Word reports) defined in the template that you use to generate the report. For more information about template styles, see Report Templates.

In Microsoft® Word, paragraph styles and text styles applied using a named style can interact when you apply both to the same text. This interaction occurs for formatting properties that paragraphs and text have in common, such as bold, italic, and underline.

Suppose that you apply the paragraph style MyStyle to a paragraph and that MyStyle specifies bold formatting. You then apply a text style named BoldStyle to text in the paragraph. The text formatted with BoldStyle toggles the paragraph style bold off. To ensure the text is bold you can create a text style that does not use bold but has the other properties you want to apply to text in that type of paragraph.

Paragraph Text

Enter paragraph text into this field. If the Paragraph component has child components, the paragraph content is taken from the paragraph text and the child components. Otherwise, the Paragraph component inserts text from this field. If the Paragraph component does not have any child components and you do not enter any text into this field, no text appears in the report.

To insert text to be computed when the report is generated, use the computed property notation, %<expr>, where expr is a MATLAB expression that evaluates to a string.

Style Name

Specifies a style to use with the paragraph text for reports whose output format is one of the from template types, for example, Direct PDF (from template). By default, this option specifies the rgParagraph style defined by the Report Explorer's default document conversion templates. To modify the appearance of all paragraphs in a report, customize the rgParagraph style in the report template. To modify the appearance of this paragraph only, specify another style defined in the report template. To specify another style:

  1. Set Style Name to Specify.

  2. In the Style Name text box, type a style name.

    To use the custom style you specify, it must be a paragraph style (or a linked paragraph/character style for Word reports) defined in the template that you use to generate the report. For more information about template styles, see Report Templates.

Style

Note

If you use the Style Name field to specify a style for the paragraph text, the style formats below override the corresponding formats specified in the style. For example, selecting Bold makes the text bold, even if the specified style specifies regular weight text.

  • Bold: Makes the text bold.

  • Italic: Makes the text italic.

  • Underline: Underlines the text.

  • Strikethrough: Strikes through the text.

  • Preserve white space: Preserves sequences of spaces in the text content of this component. Deselecting this option causes sequences of spaces to be reduced to one space. This option does not appear if this component is the child of a Paragraph component that has its Preserve white space option selected. The Preserve white space option applies to all children of that Paragraph component. This option applies only to HTML (from template), Multipage HTML (from template) (since R2024a), Single-File HTML (from template, or Word (from template) reports. The Preserve white space option does not appear for other output types.

  • Color: Specifies the color of the text.

    • Select a color from the list of colors.

    • Enter a hexadecimal RGB value as #RRGGBB. For example, #0000ff is a shade of blue.

    • Enter %<expr>, where expr is a MATLAB® expression that evaluates to a color name or a hexadecimal RGB value.

Insert Anything into Report?

Yes. Paragraph.

Class

rptgen.cfr_paragraph