Main Content

mlreportgen.ppt.Italic Class

Namespace: mlreportgen.ppt

Italic for text object

Description

Specifies whether to render text in italic.

The mlreportgen.ppt.Italic class is a handle class.

Creation

Description

italicObj = Italic creates a format object that specifies to render text in italic.

italicObj = Italic(value) creates a format object that specifies to render text in italic if value is true; otherwise, the text renders without italic.

example

Input Arguments

expand all

Whether to use italic for the text, specified as a logical 1 (true) or 0 (false). When you specify:.

  • 1 (true) — Render the text in italic.

  • 0 (false) — Render the text in straight text.

Data Types: logical

Properties

expand all

Whether to use italic for the text, specified as a logical 1 (true) or 0 (false). When you specify:.

  • 1 (true) — Render text in italic.

  • 0 (false) — Render text in straight text.

Attributes:

GetAccess
public
SetAccess
public
NonCopyable
true

Data Types: logical

Tag, specified as a character vector or string scalar. The PPT API generates a session-unique tag as part of the creation of this object. The generated tag has the form CLASS:ID, where CLASS is the object class and ID is the value of the Id property of the object. Use this value to help identify where an issue occurs during presentation generation.

Attributes:

GetAccess
public
SetAccess
public
NonCopyable
true

Data Types: char | string

Object identifier, specified as a character vector or string scalar. The PPT API generates a session-unique identifier when it creates the presentation element object. You can specify your own value for Id.

Attributes:

GetAccess
public
SetAccess
public
NonCopyable
true

Data Types: char | string

Examples

collapse all

Create a presentation.

import mlreportgen.ppt.*

ppt = Presentation("myItalicPresentation.pptx");
open(ppt);
titleSlide = add(ppt,"Title and Content");

Create a paragraph and append text with italic and regular text.

p = Paragraph("Hello World");
p.Style = {Italic(true)};
t = Text(" How are you?");
t.Style = {Italic(false)};
append(p,t);

Add the paragraph to the slide. Close and view the presentation.

replace(titleSlide,"Content",p);

close(ppt);
rptview(ppt);

Sample slide with a paragraph that reads "Hello World How are you?", with "Hello World" displaying in italic

Version History

Introduced in R2015b