export declare function displayWidth(text: string): number; /** * A rectangle of text plus the column its spine sits on. `spine` is where an * incoming `│` attaches at the top and where an outgoing one leaves at the * bottom, so stacking is a matter of lining up that column. */ export type Block = { lines: string[]; width: number; spine: number; }; export declare function padTo(line: string, width: number): string; export declare function indent(block: Block, by: number): Block; /** Text lines centred on a shared spine. No lines is a legitimate answer — an * unnamed routing node draws as its split and nothing else. */ export declare function textBlock(texts: string[]): Block; /** One row carrying nothing but the spine. */ export declare function spineBlock(char?: string): Block; export declare function emptyBlock(): Block; /** Stack blocks vertically, aligning their spines. */ export declare function vstack(blocks: Block[]): Block; /** Place blocks side by side, returning where each one's spine landed. */ export declare function hstack(blocks: Block[], gap: number): { block: Block; spines: number[]; }; /** Extend a column downwards so every column in a split ends level. */ export declare function padColumn(block: Block, toHeight: number, char: string): Block; /** * The glyph where a rail meets the spine. A tee has to point at the rails it * actually carries: drawing `├` while the rail leaves to the left produces a * junction with an arm attached to nothing and a rail attached to nothing. */ export declare function teeAt(spine: number, others: number[], down: boolean): string; /** Draw a horizontal rail across `width`, writing one glyph per marked column. */ export declare function rail(width: number, marks: { at: number; char: string; }[]): string; /** Wrap a block in a captioned box, for a sub-flow that runs inside a step. */ export declare function frame(block: Block, caption: string): Block; //# sourceMappingURL=asciiBlocks.d.ts.map