transitive-js
Version:
A tool for generating dynamic stylized transit maps that are easy to understand.
33 lines (32 loc) • 1.18 kB
TypeScript
/**
* LabelEdgeGroup
*/
export default class LabelEdgeGroup {
constructor(renderedSegment: any);
renderedSegment: any;
renderedEdges: any[];
addEdge(rEdge: any): void;
edgeIds: any;
getLabelTextArray(): any[];
/**
* Find the potential anchors for a label given a display and spacing.
* @param {Display} display
* @param {Number} spacing - spacing needed for label placement (i.e., label
* height with buffer)
*/
getLabelAnchors(display: any, spacing: number): Object[];
/**
* Get the coordinate located at a defined percentage along along a rendered path.
* @param {Number} t - a value between 0 and 1 representing the location of the
* point to be computed
* @param {Display} display
* @returns {Object} - the coordinate as an {x,y} Object
*/
coordAlongRenderedPath(t: number, display: any): Object;
/**
* Get the total render length for the edge group, which consists of the sum
* of each graph edge length.
*/
getRenderLength(display: any): number;
renderLength: number | undefined;
}