1 | import { Axis } from './ViewPort';
|
2 | import Document, { Element } from './Document';
|
3 | export default class Property<T = any> {
|
4 | private readonly document;
|
5 | private readonly name;
|
6 | private value;
|
7 | static readonly textBaselineMapping: {
|
8 | baseline: string;
|
9 | 'before-edge': string;
|
10 | 'text-before-edge': string;
|
11 | middle: string;
|
12 | central: string;
|
13 | 'after-edge': string;
|
14 | 'text-after-edge': string;
|
15 | ideographic: string;
|
16 | alphabetic: string;
|
17 | hanging: string;
|
18 | mathematical: string;
|
19 | };
|
20 | static empty(document: Document): Property<string>;
|
21 | private isNormalizedColor;
|
22 | constructor(document: Document, name: string, value: T);
|
23 | split(separator?: string): Property<string>[];
|
24 | hasValue(zeroIsValue?: boolean): boolean;
|
25 | isString(regexp?: RegExp): boolean;
|
26 | isUrlDefinition(): boolean;
|
27 | isPixels(): boolean;
|
28 | setValue(value: T): this;
|
29 | getValue(def?: T): T;
|
30 | getNumber(def?: T): number;
|
31 | getString(def?: T): string;
|
32 | getColor(def?: T): string;
|
33 | getDpi(): number;
|
34 | getRem(): number;
|
35 | getEm(): number;
|
36 | getUnits(): string;
|
37 | getPixels(axis?: Axis, processPercent?: boolean): number;
|
38 | getPixels(isFontSize?: boolean): number;
|
39 | getMilliseconds(): number;
|
40 | getRadians(): number;
|
41 | getDefinition<T extends Element>(): T;
|
42 | getFillStyleDefinition(element: Element, opacity: Property): string | CanvasPattern | CanvasGradient;
|
43 | getTextBaseline(): string;
|
44 | addOpacity(opacity: Property): Property<string>;
|
45 | }
|
46 | //# sourceMappingURL=Property.d.ts.map |
\ | No newline at end of file |