Documentation

This is machine translation

Translated by Microsoft
Mouseover text to see original. Click the button below to return to the English verison of the page.

Note: This page has been translated by MathWorks. Please click here
To view all translated materals including this page, select Japan from the country navigator on the bottom of this page.

getTitleReporter

Class: mlreportgen.report.Section
Package: mlreportgen.report

Get section title reporter

Syntax

reporter = getTitleReporter(section)

Description

reporter = getTitleReporter(section) returns a reporter that the Section reporter (section) uses to format the value specified by its Title property. Use this method to customize the title alignment, position, and appearance.

Input Arguments

expand all

Section of the report, specified as a section reporter object. To create the section input, use mlreportgen.report.Section.

Output Arguments

expand all

Section title reporter, returned as a reporter object.

Examples

Use Nondefault Section Title Style

Create a style for the title of your section that differs from the default style. Before you run this report, create a template named MySectionTemplate and customize its SectionTitle style. Then, use the getTitleReporter method and the TemplateSrc property to use your template.

import mlreportgen.report.*
import mlreportgen.dom.*
rpt = Report('MyReport','pdf','MyCustomPDFTemplate');
section = Section;
titleReporter = getTitleReporter(section);
titleReporter.TemplateSrc = rpt;
titleReporter.Content = 'My Section';
section.Title = titleReporter;

Introduced in R2017b

Was this topic helpful?