Configuration
fduthesis provides a highly flexible configuration system. High-level layout choices are passed to the \documentclass, while granular styling and personal metadata are defined using the \fdusetup macro.
Document Class Options
These options dictate the structural behavior of the document and are passed as standard LaTeX optional arguments:
\documentclass[type=master, twoside, draft=false]{fduthesis}
| Option | Description | Trade-offs & Usage Notes |
|---|---|---|
type |
Thesis type: doctor, master, bachelor. (Default: bachelor) |
Controls cover layout, degree terminology, and binding margins. |
oneside |
Formats the document for single-sided digital viewing. | Chapters can start on any page. Margins are symmetrical. Ideal for PDF-only distribution. |
twoside |
Formats for double-sided physical printing. (Default) | Chapters force-start on odd (right-hand) pages. Margins shift to accommodate physical binding. Blank pages may automatically be inserted. |
draft |
Enables draft mode (true or false). (Default: false) |
Replaces high-res images with bounding boxes. Disables hyperlinks. Highlights overfull horizontal boxes (text bleeding into margins) with black bars. Use this to drastically speed up compile times during writing. |
config |
Loads an external user config file. | e.g., config=myconfig.def. Useful if you want to keep main.tex extremely clean. |
The \fdusetup Command
The \fdusetup command is the heart of fduthesis. It utilizes the l3keys interface, meaning you use a clean, hierarchical key-value syntax.
Values can be set using nested blocks:
\fdusetup{
style = {
font-size = -4,
hyperlink = color
},
info = {
title = {我的论文标题}
}
}
Or via paths (useful for single overrides later in the document):
\fdusetup{style/font-size = -4}
Style Options (style/)
The style block configures typography, link behaviors, and automated cover generation.
Fonts (font and cjk-font)
Because LaTeX engine font handling can be notoriously complex across different operating systems, fduthesis auto-detects your OS and applies the most appropriate font suite by default. However, you can force specific fonts:
font: Sets the Western (Roman) font and its corresponding Math font.- Options:
times(default, uses XITS),times*(uses system Times New Roman, math stays XITS),garamond,libertinus,lm(Latin Modern),palatino,none. cjk-font: Sets the Chinese font suite (Song, Hei, Kai, Fangsong).- Options:
windows(Zhongyi fonts, default on Win),mac(华文 fonts, default on macOS),fandol(Open source, default on Linux),adobe,founder,sinotype,sourcehan,none.
Expert Tip: If you use
cjk-font = none, the template assumes you will define your own fonts in the preamble using\setCJKmainfont,\setCJKsansfont, etc. This is useful for users with strict, non-standard font requirements.
Typography & Punctuation
font-size: The base font size for the main body. Options:-4(小四, approx 12pt, default),5(五号, approx 10.5pt).fullwidth-stop: Scientific and technical theses in Chinese traditionally replace the open circle full stop (。) with a fullwidth solid dot (.).- Options:
catcode(safest for cross-engine),mapping(XeTeX only),false(keeps。). footnote-style: Controls the appearance of footnote markers. Options:plain(1, 2, 3),pifont(circled numbers ①, ②),libertinus,xits.
Hyperlinks
hyperlink: How cross-references, citations, and URLs appear.color(default): Links are colored text. Best for reading on screens.border: Links have a colored box drawn around them. Box does not print.none: Disables link styling entirely. Crucial for final physical printing to avoid grey/colored text.hyperlink-color: Pre-defined palettes. Options:default,classic,material,graylevel,prl.
Cover Generation
auto-make-cover: Options:true(default),false. If true, the title page, instructor list, and originality declaration are automatically injected at\begin{document}.declaration-page: If you have signed the physical declaration page and scanned it, you can inject it directly to replace the auto-generated one.- Example:
declaration-page = {figures/signed-declaration.pdf}. logo&logo-size: Adjusts the Fudan University text logo on the cover. Default isfudan-name.pdf.
Metadata Options (info/)
The info block populates the cover pages and PDF metadata. Keys with a * suffix denote the English equivalent.
| Key | Description & Examples |
|---|---|
title, title* |
Thesis title. Use \\ for manual line breaks if the auto-wrap looks aesthetically poor. |
author, author* |
Candidate's name. |
supervisor |
Supervisor's name and title (e.g., 张三\quad 教授). |
instructors |
Guiding committee members. Formatted as a nested list: {{A\quad Prof}, {B\quad Prof}}. If left blank, the instructor page is omitted. |
degree |
For Master's candidates. academic (学术学位, default) or professional (专业学位). Changes the cover layout significantly. |
major |
Major or discipline. |
department |
Department, School, or Institute. |
student-id |
Your 11-digit student ID. |
secret-level |
If your thesis is confidential. Options: none (default), i (秘密), ii (机密), iii (绝密). This adds the official secrecy stamp to the cover. |
secret-year |
Duration of secrecy (e.g., 五年). Required if secret-level is not none. |
keywords, keywords* |
Comma-separated list of keywords. Rendered at the bottom of the abstracts. |
clc |
Chinese Library Classification (中图分类号). Found via library search. |
jel |
JEL Classification code. Required primarily by candidates in the School of Economics. |
Common Pitfalls
- Missing Commas: Because
\fdusetupuses key-value pairs, forgetting a comma at the end of a line (e.g., aftermajor = {Physics}) will cause cryptic compilation errors on the next line. - Empty Fields causing Overfull Boxes: If a required field like
student-idis left entirely blank, the cover layout tables may collapse or throw underfull/overfull box warnings. If you must leave it blank temporarily, put a non-breaking space{~}.