import { StreamProcessor } from "../../basic/StreamProcessor";
import { InteractiveEvent, IRectNode, Point, Rect } from "../../../../common";
import { AppEventContext } from "../../../../app";
import { IPoint } from "../../../../idl";
import { SingleStretchInfo } from "../../detector/stretch/StretchDetector";
import { CropProps, GraphicNode, OolongLine } from "../../../../graphics";
import { AffineMatrix } from "../../../../math";
import { AlignWorker } from "../../align/AlignWorker";
import { AlignStretchResultInfo, StretchAlignType } from "../../align/AlignResult";
import { LayoutWorker } from "../../../../ability/line/LayoutWorker";
import { RelatedGroupBaseWorker } from "../../../../ability/group/RelatedGroupBaseWorker";
import { AbsStretchHandler } from "./handler/AbsStretchHandler";
import { AbsImgNode } from "../../../../graphics/img/AbsImgNode";
import { StretchCropNodeHandler } from "./handler/StretchCropNodeHandler";
import { LineTextRectProps } from "@/graphics/props/LineTextRectProps";
export interface CropInfo {
    originCropProps: CropProps;
    originImgRect: Rect;
    originTransform: AffineMatrix;
    globalImgPos: IPoint;
}
export interface INodeStretchProp {
    x: number;
    y: number;
    height: number;
    width: number;
    angle: number;
    points?: IPoint[];
    lineTextRect?: LineTextRectProps;
    lineTextT?: number;
    crop?: CropInfo;
    fontSize?: number;
    richText?: string;
    checkSize?: number;
    innerRadius?: number;
}
export declare abstract class AbsStretchProcessor extends StreamProcessor {
    minStretchSize: IPoint;
    originPos: Point;
    originStretchRect?: Rect;
    propsMap: Map<GraphicNode, INodeStretchProp>;
    originTransform: AffineMatrix;
    viewBounds: IRectNode;
    target: SingleStretchInfo | null;
    alignWorker: AlignWorker;
    alignType: StretchAlignType;
    originWidthHeightRatio: number;
    isUniform: boolean;
    relatedLines: Set<OolongLine>;
    layoutWorker: LayoutWorker;
    cropStretchHandler: StretchCropNodeHandler;
    groupBaseWorker: RelatedGroupBaseWorker;
    abstract handlers: AbsStretchHandler[];
    abstract getStretchRect(ctx: AppEventContext): Rect;
    abstract getMiniSize(ctx: AppEventContext): IPoint;
    protected abstract recordPropsMap(ctx: AppEventContext): void;
    protected recordNodePropInfo(node: GraphicNode): INodeStretchProp;
    computeAnchorPoint(stretchInfo: SingleStretchInfo, rect: Rect): {
        x: number;
        y: number;
    };
    protected abstract computeOriginTransform(ctx: AppEventContext): void;
    protected isTextLikeUniformNode(node: GraphicNode): boolean;
    protected shouldForceUniformForNode(node: GraphicNode): boolean;
    protected shouldForceUniformForTextLikeNode(node: GraphicNode): boolean;
    protected judgeUniform(ctx: AppEventContext): void;
    computeStretchRect(stretchRect: Rect, delta: IPoint): void;
    protected minRectLimit(stretchRect: Rect): void;
    protected computeTarget(event: InteractiveEvent, ctx: AppEventContext): void;
    protected modifyOriginPos(event: InteractiveEvent, ctx: AppEventContext): void;
    onStart(event: InteractiveEvent, ctx: AppEventContext): void;
    protected afterOnStart(ctx: AppEventContext): void;
    onMove(event: InteractiveEvent, ctx: AppEventContext): void;
    onUp(event: InteractiveEvent, ctx: AppEventContext): void;
    protected afterOnUp(event: InteractiveEvent, ctx: AppEventContext): void;
    protected alignStretchGlobalPoint(event: InteractiveEvent, ctx: AppEventContext): IPoint;
    protected stretchNode(event: InteractiveEvent, ctx: AppEventContext, streaming: boolean): void;
    protected afterStretchNode(ctx: AppEventContext, sx: number, sy: number, M: AffineMatrix, streaming: boolean, cropImgNodes: AbsImgNode[], svgNodes: AbsImgNode[]): void;
    protected computeScale(stretchRect: Rect, isUniform?: boolean): {
        sx: number;
        sy: number;
    };
    protected abstract drawAlignLine(stretchRect: Rect, alignRes: AlignStretchResultInfo, ctx: AppEventContext): void;
    private batchCollectNodeLinks;
    private collectNodeLinks;
}
//# sourceMappingURL=AbsStretchProcessor.d.ts.map