opensource_community
Reproducible toolchain validation

Bilingual XeLaTeX Research Typesetting: Toolchain Validation

Bilingual typesetting, mathematics, vector graphics, code listings and bibliography in one compact smoke test.

Test date: 2026-08-30 · Public edition: Redacted · Output: three-page A4 PDF

Summary

Validated capabilities
9 / 9
All compiled and visually inspected
Output
3 pages
A4, compact with full test coverage
Build Engine
XeLaTeX
ctex + Fandol Chinese font
Bibliography backend
Biber
Author–year citation style
ConclusionThis sample is suitable as an acceptance test for a Linux research-writing environment. Rather than showcase a particular paper, it is designed to expose problems with fonts, packages, figures, numbering, and bibliography tools in a single build.

Rendered output

These pages are the actual output of the successful XeLaTeX and Biber build. Select a page to view it at full size. Together, they show the document structure and bilingual text, mathematics and tables, vector figures, code, and references.

LaTeX sample page 1: bilingual title, abstract, table of contents, text hierarchy, and lists
PAGE 01 · BILINGUAL TEXT & STRUCTURE
LaTeX sample page 2: equations, theorems, tables, and units
PAGE 02 · MATH & TABLES
LaTeX sample page 3: TikZ, PGFPlots, code, and references
PAGE 03 · FIGURES, CODE & REFERENCES

1. Test objectives and scope

The test directory contains the main document, a BibLaTeX database, build instructions, and records of font-related failures. The test verifies the complete source-to-PDF workflow and checks that key elements render without missing glyphs, placeholder boxes, overlap, or clipping.

This is not a font-quality benchmark, print-color assessment, or PDF/UA accessibility audit. The sample data is for typesetting tests only; any accuracy or timing values shown in its tables are not experimental results.

2. Coverage matrix

CapabilitiesCoverageVerification result
Bilingual textChinese and English, bold and italic text, monospaced text, footnotes, and full-width punctuationPassed
Document structureTitle, abstract, table of contents, sections, nested lists, and page numbersPassed
MathematicsSubscripts, accents, matrices, piecewise functions, integrals, limits, theorems, and equation numbersPassed
Tables and unitsbooktabs, multirow, siunitx, decimal alignment, and scientific notationPassed
Vector figuresTikZ curves, axes, annotations, and subfiguresPassed
PlotsPGFPlots lines, grids, axis labels, and legendsPassed
Code listingsPython syntax highlighting, line numbers, wrapping, borders, and monospaced fontsPassed
Cross-referencesLinks to theorem, equation, table, and figure numbersPassed, with a localization issue noted
BibliographyBiber, author–year citations, DOI links, and reference entriesPassed

3. Minimum reproducible process

The main document uses ctexart for Chinese and Unicode support through XeLaTeX. biblatex uses Biber as its backend, while latexmk runs XeLaTeX and Biber as needed until the build converges.

# Build
latexmk -xelatex main.tex

# Force a full rebuild and stop on errors
latexmk -g -xelatex -interaction=nonstopmode -halt-on-error main.tex

# Remove intermediate build files
latexmk -C
Acceptance checkA successful build only confirms that the tools exited without an error. Render the complete PDF and inspect each page for font fallback, clipped equations, misplaced floats, overflowing code, and broken bibliography links.

4. Layout verification and follow-up items

4.1 Passed checks

4.2 Non-blocking issue

cleveref still labels references in English (for example, theorem, equation, figure, and table). For a Chinese-only paper, define localized names or review the package language options and loading order. The sample also renders the word to in a Celsius range; formal Chinese documents should use a consistent Chinese range marker.

5. Desktop font rendering issue

After installing the Chinese TeX Live components, Chinese character spacing may temporarily look wrong in a desktop terminal or an Electron/Chromium app. The evidence points away from the LaTeX build chain: installation changes the system Fontconfig fallback order, while long-running graphical apps may retain stale font caches or mappings.

  1. Record fc-match output and package changes before and after installation so the results can be compared.
  2. ctex under XeLaTeX can use TeX Live's bundled Fandol fonts; basic Chinese support usually does not require changing desktop fonts.
  3. After changing fonts, rebuild the Fontconfig cache and fully quit and restart apps that render text. Restart again if the cache still appears inconsistent.
  4. Specify fonts explicitly in the source when possible to reduce dependence on the desktop's default fallback chain.
Scope of this findingDo not attribute this behavior to a single font file without evidence. A reliable diagnosis compares font-matching results, package-change records, and application behavior before and after restart.

6. Redactions and environment details

This report includes commonly used package combinations, build commands, verification methods, and failure mechanisms. It omits absolute source paths, local usernames, host identifiers, user-level configuration, installation logs, and other details tied to a specific environment. The author field is presented as a toolchain-validation label.

7. Conclusion

This test confirms that XeLaTeX, ctex, TikZ/PGFPlots, listings, cleveref, siunitx, and Biber can form a compact, reproducible baseline for bilingual research typesetting. The core features render as expected. Further work should address localized reference names and unit-range wording rather than expand the test matrix.