MCPcopy Create free account
hub / github.com/CoderLine/alphaTab / withFamilyList

Method withFamilyList

packages/alphatab/src/model/Font.ts:471–480  ·  view source on GitHub ↗

* Initializes a new instance of the Font class. * @param families The families. * @param size The size. * @param style The style. * @param weight The weight.

(
        families: string[],
        size: number,
        style: FontStyle = FontStyle.Plain,
        weight: FontWeight = FontWeight.Regular
    )

Source from the content-addressed store, hash-verified

469 * @param weight The weight.
470 */
471 public static withFamilyList(
472 families: string[],
473 size: number,
474 style: FontStyle = FontStyle.Plain,
475 weight: FontWeight = FontWeight.Regular
476 ) {
477 const f = new Font('', size, style, weight);
478 f.families = families;
479 return f;
480 }
481
482 public toCssString(scale: number = 1): string {
483 if (!this._css || !(Math.abs(scale - this._cssScale) < 0.01)) {

Callers 5

Font.test.tsFile · 0.80
withSizeMethod · 0.80
fromJsonMethod · 0.80
registerFontMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected