renderer.d.ts 1.2 KB

12345678910111213141516171819202122232425
  1. import { Point, Rectangle } from '@antv/x6-geometry';
  2. import { Base } from '../graph/base';
  3. import { Cell } from '../model';
  4. import { CellView, EdgeView } from '../view';
  5. export declare class Renderer extends Base {
  6. private readonly schedule;
  7. requestViewUpdate(view: CellView, flag: number, options?: any): void;
  8. isViewMounted(view: CellView): boolean;
  9. setRenderArea(area?: Rectangle): void;
  10. findViewByElem(elem: string | Element | undefined | null): CellView<Cell<Cell.Properties>, CellView.Options> | null;
  11. findViewByCell(cellId: string | number): CellView | null;
  12. findViewByCell(cell: Cell | null): CellView | null;
  13. findViewsFromPoint(p: Point.PointLike): CellView<Cell<Cell.Properties>, CellView.Options>[];
  14. findEdgeViewsFromPoint(p: Point.PointLike, threshold?: number): EdgeView<import("../model").Edge<import("../model").Edge.Properties>, EdgeView.Options>[];
  15. findViewsInArea(rect: Rectangle.RectangleLike, options?: {
  16. strict?: boolean;
  17. nodeOnly?: boolean;
  18. }): CellView<Cell<Cell.Properties>, CellView.Options>[];
  19. dispose(): void;
  20. }
  21. export declare namespace Renderer {
  22. interface FindViewsInAreaOptions {
  23. strict?: boolean;
  24. }
  25. }