unreal.SlateFontInfo

class unreal.SlateFontInfo(font_object: Object = Ellipsis, font_material: Object = Ellipsis, outline_settings: FontOutlineSettings = Ellipsis, typeface_font_name: Name = 'None', size: float = 0.0, letter_spacing: int = 0, skew_amount: float = 0.0, force_monospaced: bool = False, monospaced_width: float = 0.0)

Bases: StructBase

A representation of a font in Slate.

C++ Source:

  • Module: SlateCore

  • File: SlateFontInfo.h

Editor Properties: (see get_editor_property/set_editor_property)

  • font_material (Object): [Read-Write] The material to use when rendering

  • font_object (Object): [Read-Write] The font object (valid when used from UMG or a Slate widget style asset)

  • force_monospaced (bool): [Read-Write] Enable pseudo-monospaced font.

  • letter_spacing (int32): [Read-Write] The uniform spacing (or tracking) between all characters in the text.

  • monospaced_width (float): [Read-Write] The uniform width to apply to all characters when bForceMonospaced is enabled, proportional of the font Size.

  • outline_settings (FontOutlineSettings): [Read-Write] Settings for applying an outline to a font

  • size (float): [Read-Write] The font size is a measure in point values. The conversion of points to Slate Units is done at 96 DPI. So if you’re using a tool like Photoshop to prototype layouts and UI mock ups, you can change the UMG Font settings to ensure that UMG font size is displayed in its 72 DPI equivalent, even if Slate will still use 96 DPI internally.

  • skew_amount (float): [Read-Write] A skew amount to apply to the text.

  • typeface_font_name (Name): [Read-Write] The name of the font to use from the default typeface (None will use the first entry)

property font_material: Object

[Read-Write] The material to use when rendering

Type:

(Object)

property font_object: Object

[Read-Write] The font object (valid when used from UMG or a Slate widget style asset)

Type:

(Object)

property force_monospaced: bool

[Read-Write] Enable pseudo-monospaced font.

Type:

(bool)

property letter_spacing: int

[Read-Write] The uniform spacing (or tracking) between all characters in the text.

Type:

(int32)

property monospaced_width: float

[Read-Write] The uniform width to apply to all characters when bForceMonospaced is enabled, proportional of the font Size.

Type:

(float)

property outline_settings: FontOutlineSettings

[Read-Write] Settings for applying an outline to a font

Type:

(FontOutlineSettings)

property size: float

[Read-Write] The font size is a measure in point values. The conversion of points to Slate Units is done at 96 DPI. So if you’re using a tool like Photoshop to prototype layouts and UI mock ups, you can change the UMG Font settings to ensure that UMG font size is displayed in its 72 DPI equivalent, even if Slate will still use 96 DPI internally.

Type:

(float)

property skew_amount: float

[Read-Write] A skew amount to apply to the text.

Type:

(float)

property typeface_font_name: Name

[Read-Write] The name of the font to use from the default typeface (None will use the first entry)

Type:

(Name)