• Convenience function to up or downscale font sizes of a Theme object. Similarly also scales relevant paddings and margins to make font sizes sit better with the overall style defaults.

     // Example syntax
    const chart = lightningChart().ChartXY({
    theme: scaleTheme(Themes.darkGold, 0.6) // fonts, paddings etc. will be smaller than normal
    })

    This was designed as an easy way to adjust chart themes for mobile view (generally themes are downscaled in this case as screen space is more limited), but it can also be convenient tool to scaling general chart elements size.

    Returns

    New theme object.

    Parameters

    • theme: Theme

      Theme object to use as a base.

    • scaler: number

      Number around [.1, 4] range. 2 means twice as bigger fonts. 0.5 means half size fonts.

    Returns Theme