UNPKG

igniteui-angular-gauges

Version:

Ignite UI Angular gauge components.

92 lines (91 loc) 3.71 kB
/* THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE: https://www.infragistics.com/legal/license/igultimate-la https://www.infragistics.com/legal/license/igultimate-eula GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company. */ import { Base, Point_$type, markType } from "igniteui-angular-core"; import { PathGeometry } from "igniteui-angular-core"; import { PathFigure } from "igniteui-angular-core"; import { LineSegment } from "igniteui-angular-core"; import { BrushUtil } from "igniteui-angular-core"; /** * @hidden */ export let LinearGraphBackingFrame = /*@__PURE__*/ (() => { class LinearGraphBackingFrame extends Base { constructor() { super(); this.e = null; this.f = null; this.c = 0; this.b = 0; this.a = 0; } g(a, b, c) { let d = new PathGeometry(); let e = new PathFigure(); let f, g, h, i; if (c == 1) { f = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: a * this.a, y: 0 }; return $ret; })()); g = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: a * this.b, y: 0 }; return $ret; })()); h = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: a * this.b, y: b }; return $ret; })()); i = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: a * this.a, y: b }; return $ret; })()); } else { f = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: 0, y: a * (1 - this.b) }; return $ret; })()); g = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: b, y: a * (1 - this.b) }; return $ret; })()); h = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: b, y: a * (1 - this.a) }; return $ret; })()); i = ((() => { let $ret = new LineSegment(1); $ret.c = { $type: Point_$type, x: 0, y: a * (1 - this.a) }; return $ret; })()); } e._startPoint = f.c; e._segments.add(g); e._segments.add(h); e._segments.add(i); e._isClosed = true; d.c.add(e); return d; } d(a, b, c) { this.c = b.c + (c.c - b.c) * a; this.e = BrushUtil.n(b.e, a, c.e, 0); this.f = BrushUtil.n(b.f, a, c.f, 0); this.b = b.b + (c.b - b.b) * a; this.a = b.a + (c.a - b.a) * a; } } LinearGraphBackingFrame.$t = markType(LinearGraphBackingFrame, 'LinearGraphBackingFrame'); return LinearGraphBackingFrame; })();