Colibrio Reader Framework API - Cloud license
    Preparing search index...

    Interface IPublicationStyleFontFace

    interface IPublicationStyleFontFace {
        family: string;
        fontStretch?: string;
        fontStyle?: string;
        fontWeight?: string;
        mediaType: MediaType;
        src?: string;
        srcUrl?: string;
    }

    Properties

    family: string

    The font family name for this font face. Cannot be any of the reserved words:

    • 'serif'
    • 'sans-serif'
    • 'cursive'
    • 'fantasy'
    • 'monospace'
    fontStretch?: string

    Sets the value to use for font-stretch for the corresponding

    rule. See: https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-stretch

    If undefined, font-stretch is not added to the @font-face.

    fontStyle?: string

    Sets the value to use for font-style for the corresponding

    rule. See: https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-style

    If undefined, font-style is not added to the @font-face.

    fontWeight?: string

    Sets the value to use for font-weight for the corresponding

    rule. See: https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face/font-weight

    If undefined, font-weight is not added to the @font-face.

    mediaType: MediaType

    The media type of the font.

    src?: string

    The font source data as a base64 string. To ensure compatibility, it is recommended to use a .woff, .otf or .ttf font. When using .otf or .ttf font, the font will only work on IE if the font is set to "installable"

    srcUrl?: string

    The URL to the font resource. To ensure compatibility, it is recommended to use a .woff, .otf or .ttf font. To be able to load fonts by URL, you must also allow remote resources by configuring EpubReaderPublicationOptions.remoteResourcesNonScriptedDocumentsOptions.

    If both src and srcUrl are specified, srcUrl will be used instead.