@nativescript/core
Version:
A JavaScript library providing an easy to use api for interacting with iOS and Android platform APIs.
19 lines (18 loc) • 966 B
TypeScript
import { Font as FontBase } from './font-common';
import { FontStyleType, FontWeightType, FontVariationSettingsType } from './font-interfaces';
export { FontStyle, FontWeight, FontVariationSettings, parseFont } from './font-common';
export declare class Font extends FontBase {
static default: Font;
constructor(family: string, size: number, style?: FontStyleType, weight?: FontWeightType, scale?: number, variationSettings?: Array<FontVariationSettingsType>);
withFontFamily(family: string): Font;
withFontStyle(style: FontStyleType): Font;
withFontWeight(weight: FontWeightType): Font;
withFontSize(size: number): Font;
withFontScale(scale: number): Font;
withFontVariationSettings(variationSettings: Array<FontVariationSettingsType> | null): Font;
getUIFont(defaultFont: UIFont): UIFont;
getAndroidTypeface(): android.graphics.Typeface;
}
export declare namespace ios {
function registerFont(fontFile: string): void;
}