/** The two edges of a warp at one horizontal position, `0`…`1` down the box. */ export interface WarpEdges { readonly top: number; readonly bottom: number; } /** * Whether a preset bends text at all. `textNoShape` is the "no warp" member of * the enumeration and by far its most common value — two thirds of the decks * that mention a warp state only this one — and a body carrying it is an * ordinary text box, NOT WordArt stretched to its shape. * * @param preset The `a:prstTxWarp @prst` value. * @returns Whether {@link textWarpEdges} can bend text through this preset. */ export declare function isTextWarp(preset: string): boolean; /** * Where a warped body's two frames sit on the page: the shape's box, which the * warped text is stretched onto, and the box the UN-warped block occupies. * Both are in the page's top-left frame, y growing down. */ export interface WarpFrame { readonly preset: string; readonly adjust?: number; readonly boxX: number; readonly boxY: number; readonly boxWidth: number; readonly boxHeight: number; readonly srcX: number; readonly srcWidth: number; readonly srcTop: number; readonly srcHeight: number; } /** * The matrix that places one glyph of a warped body. * * Maps the glyph's own text space — x along its advance, y UP from its * baseline — into the page's top-left frame, as `[a, b, c, d, e, f]` with * `px = a·x + c·y + e` and `py = b·x + d·y + f`. Upright text therefore has a * negative `d`: the glyph's y runs against the page's. * * @param frame The two frames, from the laid-out line. * @param glyphX The glyph's left edge in the un-warped block. * @param advance How wide the glyph is there. * @param baselineY The line's baseline in the un-warped block. * @returns The six numbers, or `undefined` where the warp leaves no room to * draw — the pinched end of a fade, or a preset this file cannot bend. */ export declare function warpGlyphMatrix(frame: WarpFrame, glyphX: number, advance: number, baselineY: number): readonly [number, number, number, number, number, number] | undefined; /** * The two edges of a warp at one position across its box. * * @param preset The `a:prstTxWarp @prst` value. * @param u Position across the box, `0` at its left edge and `1` at its right. * @param adj The `a:avLst` `adj` guide in hundred-thousandths, when the file states one. * @returns The top and bottom edges, `0`…`1` down the box, or `undefined` for a * preset this file does not bend (an unknown name, or `textNoShape`). */ export declare function textWarpEdges(preset: string, u: number, adj?: number): WarpEdges | undefined;