documentationfor yFiles for HTML 2.6

Describes a font using with size, family, style, weight, and line spacing.

Inheritance Hierarchy
Font

Remarks

This is a convertible type that can be used with the following notation(s) in parameter lists, parameter objects or setters.

CSS font shorthand strings are converted to Fonts. For example:

'bold 16px sans-serif'
'italic Tahoma'
'normal xx-large Arial'

Type Details

yfiles module
view-component
yfiles-umd modules
All view modules
Legacy UMD name
yfiles.view.Font

See Also

When using external fonts, make sure that they are loaded before the text is rendered. Otherwise the text-measurement may use a system fallback resulting in wrong measurements, e.g., for the background shape. For more information, see https://kb.yworks.com/article/802/.

Constructors

Properties

Methods

Static Methods