/** * The drawn parts of an exercise (#1227, #1228): writing areas, and the * grids of word searches, crosswords and operations in columns. Each is a * frameless box whose design draws it — paths for the rules, texts for the * letters — so every output paints it as it paints any box design, a * right-to-left page mirrors it, and the layout places and keeps it whole. * Lengths are given in points. */ import type { CalloutStyleConfig, ColorValue, DesignElement, DesignPathElement, DesignTextElement } from '../types.js'; /** A frameless box drawn by `elements`, `heightPt` tall. */ export declare function drawnBox(id: string, elements: DesignElement[], heightPt: number, marginTopPt?: number, marginBottomPt?: number): CalloutStyleConfig; /** A path element over `[0, w] × [0, h]` points, from the box's top left. */ export declare function pathElement(id: string, d: string, wPt: number, hPt: number, stroke: ColorValue, widthPt: number, extra?: Partial): DesignPathElement; /** A text element: `content` set in a box `wPt` × `hPt` at (`xPt`, `yPt`). */ export declare function textElement(id: string, content: string, xPt: number, yPt: number, wPt: number, hPt: number, sizePt: number, extra?: Partial): DesignTextElement; export type AreaKind = 'lines' | 'dots' | 'grid' | 'seyes' | 'tianzige' | 'box' | 'none'; export interface AreaSpec { kind: AreaKind; lines: number; /** Distance between two lines (the side of a grid's square), points. */ spacingPt: number; /** The room the area may take across, points. */ widthPt: number; color: ColorValue; weightPt: number; /** Answers written on the lines (a teacher's edition), one a line, in * `answerColor`. */ answers?: string[]; answerColor?: ColorValue; answerSizePt?: number; answerFont?: string; /** Squares (`grid`, `tianzige`) in groups of so many cells, side by side * a square apart and wrapping at the measure (`cells="2 2 3"`, #1244): * a word's squares each, `lines` rows tall. One number sizes the area to * that many cells. Absent: the whole measure. */ cells?: number[]; } /** The elements and height of a writing area. */ export declare function areaElements(a: AreaSpec): { elements: DesignElement[]; heightPt: number; }; //# sourceMappingURL=designs.d.ts.map