From 5514b09a5f305ffd1753ed9957570546c81f8f53 Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Sun, 12 Sep 2021 20:36:26 +0000
Subject: njuthesis (12sep21)

git-svn-id: svn://tug.org/texlive/trunk@60486 c570f23f-e606-0410-a88d-b1316a301751
---
 .../texmf-dist/tex/latex/njuthesis/njuthesis.cls   | 96 ++++++++++++++++++++++
 1 file changed, 96 insertions(+)
 create mode 100644 Master/texmf-dist/tex/latex/njuthesis/njuthesis.cls

(limited to 'Master/texmf-dist/tex/latex/njuthesis/njuthesis.cls')

diff --git a/Master/texmf-dist/tex/latex/njuthesis/njuthesis.cls b/Master/texmf-dist/tex/latex/njuthesis/njuthesis.cls
new file mode 100644
index 00000000000..d8d8f57f3a8
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/njuthesis/njuthesis.cls
@@ -0,0 +1,96 @@
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesExplClass{njuthesis}{2021-09-11}{0.7.3}{NJU Thesis LaTeX Template}
+
+% 通过类传递参数
+\RequirePackage{l3keys2e}
+
+\LoadClass[
+  a4paper,
+  twoside,
+  UTF8,
+  scheme=chinese,
+  linespread=1.625,% laTex默认1.2行距，word默认行距是1.3，要求1.5倍word行距，故1.5/1.2*1.3 = 1.625
+  fontset=none,
+  zihao=-4
+  ]{ctexbook}[2018/04/01]
+
+% 定义模板键值
+% 用于格式控制的键值
+\keys_define:nn { nju }
+{
+  titlelength       .int_set:N    =   \nju_titlelength,
+  titlelength       .initial:n    =   1,
+
+  secondmentor      .bool_set:N   =   \nju_second_mentor,
+  secondmentor      .initial:n    =   false,
+
+  degree            .tl_set:N     =   \nju_degree,
+  degree            .initial:n    =   UG,
+
+  type              .tl_set:N     =   \nju_type,
+  type              .initial:n    =   thesis,
+
+  systemfont        .bool_set:N   =   \nju_systemfont,
+  systemfont        .initial:n    =   true,
+
+  customlatinfont   .tl_set:N     =   \nju_customlatinfont,
+  customlatinfont   .initial:n    =   windows,
+
+  customchinesefont .tl_set:N     =   \nju_customchinesefont,
+  customchinesefont .initial:n    =   windows,
+
+  info              .meta:nn      =   { nju / info } { #1 }
+}
+
+\keys_define:nn { nju / info }
+{
+  % 题目
+  TitleA            .tl_set:N     =   \nju_title_a,
+  TitleB            .tl_set:N     =   \nju_title_b,
+  TitleC            .tl_set:N     =   \nju_title_c,
+  TitleEN           .tl_set:N     =   \nju_title_en,
+
+  % 年级学号姓名
+  Grade             .tl_set:N     =   \nju_grade,
+  StudentID         .tl_set:N     =   \nju_student_id,
+  StudentName       .tl_set:N     =   \nju_student_name,
+  StudentNameEN     .tl_set:N     =   \nju_student_name_en,
+
+  % 院系专业方向
+  Department        .tl_set:N     =   \nju_department,
+  DepartmentEN      .tl_set:N     =   \nju_department_en,
+  Major             .tl_set:N     =   \nju_major,
+  MajorEN           .tl_set:N     =   \nju_major_en,
+  Field             .tl_set:N     =   \nju_field,
+  FieldEN           .tl_set:N     =   \nju_field_en,
+
+  % 导师
+  MentorA           .tl_set:N     =   \nju_mentor_a,
+  MentorAEN         .tl_set:N     =   \nju_mentor_a_en,
+  MentorATitle      .tl_set:N     =   \nju_mentor_a_title,
+  MentorATitleEN    .tl_set:N     =   \nju_mentor_a_title_en,
+
+  % 第二导师
+  MentorB           .tl_set:N     =   \nju_mentor_b,
+  MentorBEN         .tl_set:N     =   \nju_mentor_b_en,
+  MentorBTitle      .tl_set:N     =   \nju_mentor_b_title,
+  MentorBTitleEN    .tl_set:N     =   \nju_mentor_b_title_en,
+
+  % 日期
+  SubmitDate        .tl_set:N     =   \nju_submit_date,
+  DefenseDate       .tl_set:N     =   \nju_defense_date,
+}
+  
+\NewDocumentCommand \njusetup { m }
+{ \keys_set:nn { nju } { #1 } }
+  
+\ProcessKeysOptions { nju }
+
+% 输入配置文件
+\RequirePackage{profile/packages}
+\RequirePackage{profile/font}
+\RequirePackage{profile/page}
+\RequirePackage{profile/reference}
+\RequirePackage{profile/components}
+\RequirePackage{profile/cover}
+\RequirePackage{profile/abstract}
-- 
cgit v1.2.3

