Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Color

Hierarchy

  • Color

Implements

Index

Constructors

constructor

  • new Color(c: string | ColorSpaceObject, interpolationFactory?: ColorGammaInterpolationFactory): Color
  • Parameters

    • c: string | ColorSpaceObject
    • Default value interpolationFactory: ColorGammaInterpolationFactory = Color.DEFAULT_INTERPOLATION

    Returns Color

Properties

Private _data

_data: ColorSpaceObject

interpolationFactory

interpolationFactory: ColorGammaInterpolationFactory

Static DEFAULT_INTERPOLATION

DEFAULT_INTERPOLATION: ColorGammaInterpolationFactory = interpolateRgb

Methods

asHSL

  • asHSL(): HSLColor

asRGB

  • asRGB(): RGBColor

get

  • get(element: SVGElement, attr: string): Color

interpolator

  • interpolator(from: Color): function

parse

  • parse(css: string | null): Color

set

  • set(element: SVGElement, attr: string, override?: Color): void

toString

  • toString(): string

Generated using TypeDoc