Table of contents
TOC
Collapse the table of content
Expand the table of content

Font Object (PowerPoint)

office 365 dev account|Last Updated: 6/12/2017
|
1 Contributor

Represents character formatting for text or a bullet. The Font object is a member of the Fonts collection. The Fonts collection contains all the fonts used in a presentation.

Example

The following examples describes how to do the following:

  • Return the Font object that represents the font attributes of a specified bullet, a specified range of text, or all text at a specified outline level

  • Return a Font object from the collection of all the fonts used in the presentation

Use the Fontproperty to return the Font object that represents the font attributes for a specific bullet, text range, or outline level. The following example sets the title text on slide one and sets the font properties.

With ActivePresentation.Slides(1).Shapes.Title _

        .TextFrame.TextRange

    .Text = "Volcano Coffee"

    With .Font

        .Italic = True

        .Name = "Palatino"

        .Color.RGB = RGB(0, 0, 255)

    End With

End With

Use Fonts (index), where index is the font's name or index number, to return a single Font object. The following example checks to see whether font one in the active presentation is embedded in the presentation.

If ActivePresentation.Fonts(1).Embedded = _

    True Then MsgBox "Font 1 is embedded"

Properties

Name
Application
AutoRotateNumbers
BaselineOffset
Bold
Color
Embeddable
Embedded
Emboss
Italic
Name
NameAscii
NameComplexScript
NameFarEast
NameOther
Parent
Shadow
Size
Subscript
Superscript
Underline

See also

Other resources

PowerPoint Object Model Reference

© 2017 Microsoft