Files
texrra-engine/docs/STATUS.md
T
gloamxun bb1d9e0561 Initial texrra engine
Rename the crate, binary, core crate, font families, env vars, and internal commands from texcraft/tex-engine to texrra. Serve the separately versioned texrra-web frontend from TEXRRA_WEB_DIR, ../web, or ./web instead of embedding index.html. Add starred section heading support and an arXiv template conformance fixture.
2026-10-19 11:41:46 +08:00

57 lines
2.9 KiB
Markdown

# Engine status
The project is split into two repositories: `texrra-engine` (this Rust engine
and HTTP server) and `texrra-web` (the static editor frontend). The engine
discovers the frontend through `TEXRRA_WEB_DIR`, `../web`, or `./web`.
Rust-native, Typst-inspired incremental LaTeX engine. No external XeLaTeX is
invoked. The live server keeps compiled documents cached and only rebuilds when
the source changes; the SVG preview is refreshed per page.
## Implemented
- Headings: numbered `\section`/`\subsection`/`\subsubsection` and starred
`\section*` variants (starred headings do not advance the counter).
- Box material: `\rule` (raise/width/height), block `\fbox`, `\parbox`,
inline `\mbox`/`\makebox`, `center`, `\hrule` with `width`/`height`.
- Fonts: Liberation Serif/Mono faces, bold/italic/monospace declarations with
group scoping, grouped text-style commands, uppercase small-caps approximation.
- Paragraphs: Knuth-Plass breaking, TeX hyphenation patterns, justification,
centering.
- Pages: A4/A5/B5/Letter/Legal/Executive, landscape, geometry margins and
text block, automatic pagination, `\newpage`/`\pagebreak`.
- Classes/packages: built-in classes, local `.cls`/`.sty`, paper options,
`\DeclareOption`/`\ProcessOptions`/`\ExecuteOptions`/option passing.
- Compatibility: spacing macros (quad/qquad/thin/en/med/thick, `\vspace*`,
`\hspace*`, skips), text symbols/letters/punctuation, break advisories,
metadata, citations/references, tables/lists/images.
- Live preview: paragraph and page-layout caches, page-hash diffing, warm
rebuilds in the low milliseconds for small edits.
## Remaining structural work
See `docs/ROADMAP.md` for concrete implementation plans.
## Known approximations / gaps
- Paragraphs: no `\parindent` indentation (a parse-side kern experiment did not
take effect and a `\setlength` conditional broke the preamble, so it was
reverted) and no `\hfill` (last-line infinite glue is not stretched).
- Fonts: no sans family (`\sffamily` is a no-op); small caps are uppercase-only.
- Boxes: `\fbox`/`\parbox` are block-level (an inline `\fbox` starts a block);
`\raisebox`, `\minipage`, and VBox material are missing.
- Pages: no footnote insertion area, no floats, no headers/footers (fancyhdr
commands are accepted as no-ops), planner and renderer are separate.
- Lengths: `\textwidth`/`\textheight`/`\linewidth`/`\columnwidth` are fixed
A4-content defaults, not geometry-aware.
- Miscellaneous: `\tableofcontents`/list commands are no-ops; base font-size
class options (10/11/12pt) are parsed but unused; rules are painted with 1x1
images in PDF.
## Verification
- `examples/hello.tex`, `examples/boxes.tex`, `examples/compat.tex` compile to
one A4 page each; the arXiv template project compiles to 3 Letter pages.
- `cargo fmt --check` passes; `cargo test` currently has no test cases.
- Warm preview: hello ~11ms, arXiv ~15ms (release server).