Skip to content

GameFontDescription

Uncategorized - no domain claims this class yet. Categorize

Class Documentation

Edit documentation

A text style: which font files to draw with, at what size, and in which colors. UI text elements link it through UiElementTextData.FontDescription, and floating text links it through FloatTextFormattingData.mFontDescription.

The client builds a font from a description in three steps:

  1. It picks the font files from typeData, a FontType, by the client's locale.
  2. It picks the size, outline size and shadow offset from resolutionData, a FontResolutionData, by the locale and the height of the game window. The size is then multiplied by a scale factor that the requesting UI passes.
  3. It copies the colors and the fill texture from the description.

UI text that uses the same description at the same scale shares one font. When the game window changes height, the client repeats step 2 for every font it has built. Each font file is loaded once, the first time a font uses it, and shared by every font that names the same path.

Colorblind colors. The five colorblind* colors are optional overrides. While the client uses its colorblind color palette, a font takes each override that is set in place of the matching normal color. An override that is not set leaves the normal color in place.

Properties

Color

Color = [0, 0, 0, 255]
Edit documentation

The text color. Replaced by colorblindColor when that is set and the colorblind palette is on.

ColorblindSelectionBoxColor

Option<Color> = null
Edit documentation

Replaces SelectionBoxColor while the colorblind palette is on. No shipped description sets it.

SelectionBoxColor

Color = [255, 0, 0, 255]
Edit documentation

A color the client copies onto the font with the other colors. Replaced by ColorblindSelectionBoxColor when that is set and the colorblind palette is on. Where the font uses it is not yet identified. Shipped data sets it on 9 descriptions.

colorblindColor

Option<Color> = null
Edit documentation

Replaces Color while the colorblind palette is on. See the class description.

colorblindGlowColor

Option<Color> = null
Edit documentation

The colorblind counterpart of glowColor. No reader was found in the game client, and no shipped description sets it.

colorblindOutlineColor

Option<Color> = null
Edit documentation

Replaces outlineColor while the colorblind palette is on. See the class description.

colorblindShadowColor

Option<Color> = null
Edit documentation

Replaces shadowColor while the colorblind palette is on. See the class description. No shipped description sets it.

fillTextureName

File = "0x0"
Type history (2 revisions)
  • 13.15 - 16.16 String
  • since 16.17 File
Edit documentation

A texture the client loads with the description and hands to the font. How the font draws it is not yet identified.

Examples:
  • assets/ux/fonts/announcementtexture.tex, on 13 announcement banner descriptions
  • assets/ux/fonts/loadingscreen_font_fill.tex, on 3 loading screen descriptions

glowColor

Color = [0, 0, 0, 255]
Edit documentation

Building a font does not read it, and no other reader was found in the game client. Shipped data sets it on about 300 descriptions.

name

String = ""
Edit documentation

A readable name for the description. Shipped values describe the style, for example Gold4_NoShadow. Building a font does not read it.

outlineColor

Color = [0, 0, 0, 255]
Edit documentation

The color of the outline. The outline's width comes from FontResolution.outlineSize. Replaced by colorblindOutlineColor when that is set and the colorblind palette is on.

shadowColor

Color = [0, 0, 0, 255]
Edit documentation

The color of the drop shadow. The shadow's offset comes from FontResolution.shadowDepthX and shadowDepthY. Replaced by colorblindShadowColor when that is set and the colorblind palette is on.

typeData

Link<FontType> = "0x0"
Edit documentation

The FontType that supplies the font files. Shipped descriptions link the types under UX/Fonts/Types/, for example UX/Fonts/Types/BeaufortBold.

Referenced by 2 classes · 2 properties