diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def')
-rw-r--r-- | Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def | 338 |
1 files changed, 178 insertions, 160 deletions
diff --git a/Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def b/Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def index 852e5d36332..c9366ed4662 100644 --- a/Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def +++ b/Master/texmf-dist/tex/latex/njuthesis/njuthesis-undergraduate.def @@ -4,7 +4,7 @@ %% %% The original source files were: %% -%% njuthesis.dtx (with options: `definition-ug') +%% njuthesis.dtx (with options: `def-u') %% %% Copyright (C) 2021 - 2022 %% by Nanjing University Linux User Group @@ -23,119 +23,153 @@ %% To produce the documentation run the original source files ending with %% `.dtx' through XeTeX. %% -\GetIdInfo $Id: njuthesis.dtx 0.20.0 2022-06-10 14:42:00 +0800 NJU LUG <git+nju-lug-email-3104-issue-@yaoge123.cn>$ +\GetIdInfo $Id: njuthesis.dtx 1.0.0 2022-08-08 14:50:00 + +0800 NJU LUG <git+nju-lug-email-3104-issue-@yaoge123.cn>$ {Undergraduate definition file for njuthesis} \ProvidesExplFile{njuthesis-undergraduate.def} {\ExplFileDate}{\ExplFileVersion}{\ExplFileDescription} -\__nju_declare_element:nn { cover / ug / emblem-img } + +\ctex_at_end_preamble:n { - content = \__nju_emblem:N \c__nju_emblemwidth_dim, - bottom-skip = 1 cm, + \__nju_date:n { submit } + } +\__nju_declare_element:nn { u / cover / emblem-img } + { + content = \__nju_emblem:N \c__nju_emblemwd_dim, + bottom-skip = 10 pt, align = l } -\__nju_declare_element:nn { cover / ug / name-img } +\__nju_declare_element:nn { u / cover / name-img } + { + content = \__nju_name:N \c__nju_namewd_dim, + bottom-skip = 10 pt, + } +\__nju_declare_element:nn { u / cover / title } + { + content = + \dim_set:Nn \l__nju_tmpb_dim { 217 pt } + \__nju_box_spread_name:Nn \l__nju_tmpb_dim { type }, + format = \zihao { -1 } \bfseries, + bottom-skip = 10 pt plus 1 fill + } +\__nju_declare_element:nn { u / cover / info } + { + content = + \__nju_u_cover_info:NNNN + \c__nju_clabelwd_dim + \c__nju_crulewd_dim + \c__nju_hsep_dim + \c__nju_fmt_coverlabel_tl, + format = \zihao { 3 } + } +\cs_new_protected:Npn \__nju_u_cover_info:NNNN #1#2#3#4 + { + \dim_set_eq:NN \tex_baselineskip:D \c__nju_clineskip_dim + \__nju_cover_entry:NNNn #1 #2 #4 { dept } + \__nju_cover_entry:NNNn #1 #2 #4 { major } + \__nju_cover_entry_title:NNN #1 #2 #4 + \dim_set:Nn \l__nju_tmpb_dim { #2 * 1/2 - #1 * 1/2 - #3 } + \__nju_cover_entry:NNNnn #1 \l__nju_tmpb_dim #4 { grade } { id } + \__nju_cover_entry:NNNn #1 #2 #4 { author } + \__nju_cover_entry_supv:NNNn #1 \l__nju_tmpb_dim #4 { supv } + \bool_if:NT \l__nju_second_supvbool + { \__nju_cover_entry_supv:NNNn #1 \l__nju_tmpb_dim #4 { supvii } } + \__nju_cover_entry:NNNn #1 #2 #4 { submitdate } + } +\__nju_declare_element:nn { u / decl / orig / emblem } { - content = \__nju_name:N \c__nju_namewidth_dim, - bottom-skip = 1 cm + content = \__nju_emblem:N \c__nju_emblemwdi_dim, + bottom-skip = 30 pt } -\__nju_declare_element:nn { cover / ug / title } +\__nju_declare_element:nn { u / decl / orig / title } { - content = - \__nju_spread_box:nnV { 9 em } { \bf } \g__nju_info_type_tl, - format = \zihao { -1 }, - bottom-skip = 0 pt plus 1.5 fill + content = \c__nju_name_origdecl_tl, + format = \zihao { -1 } \sffamily, + bottom-skip = 50 pt } -\__nju_declare_element:nn { cover / ug / info } +\__nju_declare_element:nn { u / decl / orig / text } { - content = - \__nju_cover_info_ug:NN \c__nju_coverlabel_dim \c__nju_coveruline_dim, - format = \zihao { 3 } + content = \c__nju_text_origdecl_tl, + format = \zihao { -3 }, + align = n, + bottom-skip = 0 pt plus 1 fil } -\cs_new_protected:Npn \__nju_cover_info_ug:NN #1#2 +\__nju_declare_element:nn { u / decl / orig / sign } { - \begin{minipage} { #1 + #2 + \c__nju_smallhskip_dim } - \dim_set_eq:NN \baselineskip \c__nju_coverlineskip_dim - \dim_set:Nn \l__nju_tmpb_dim { .5 #2 - .5 #1 - \c__nju_smallhskip_dim } - \__nju_cover_entry:nnn { dept } { #1 } { #2 } - \__nju_cover_entry:nnn { major } { #1 } { #2 } - \__nju_cover_entry_title:nnn { \bf } { #1 } { #2 } - \__nju_cover_bientry:nnnn { grade } { id } { #1 } { \l__nju_tmpb_dim } - \__nju_cover_entry:nnn { author } { #1 } { #2 } - \__nju_cover_entry_supv:nnn { supv } { #1 } { \l__nju_tmpb_dim } - \bool_if:NT \l__nju_second_supv_bool - { \__nju_cover_entry_supv:nnn { supv_ii } { #1 } { \l__nju_tmpb_dim } } - \__nju_cover_entry:nnn { submitdate } { #1 } { #2 } - \end{minipage} + content = \__nju_decl_sign:, + format = \zihao { -3 }, + align = r } -\__nju_declare_page:nn { cover-ug-default } +\cs_new_protected:Npn \__nju_decl_sign: + { + \clist_map_inline:nn { origsign, id, date } + { \__nju_vskip: \__nju_name:n { ##1 } : \__nju_uline:n { 7 em } } + } +\__nju_declare_page:nn { cover-u } { element = { emblem-img, name-img, title, info }, - prefix = cover / ug /, - bottom-skip = 0.5 cm plus 1.5 fill + prefix = u / cover /, + bottom-skip = 0 pt plus 1 fill + } +\__nju_declare_page:nn { origdecl-u } + { + element = { emblem, title, text, sign }, + prefix = u / decl / orig /, + top-skip = 0 pt, + bottom-skip = 0 pt plus 1 fil } \cs_new_protected:Npn \__nju_make_cover: { - \UseInstance { nju } { cover-ug-default } + \UseInstance { nju } { cover-u } } -\cs_new_protected:Npn \__nju_make_origdecl: +\cs_new_protected:Npn \__nju_make_decl_i: { \cleardoublepage - \thispagestyle { empty } - \begin{center} - \njuemblem{2cm}{!}\\ - {\zihao{-1}\sffamily \c__nju_name_origdecl_tl } - \end{center} - \zihao{-3} - \hspace{2em} - \c__nju_text_origdecl_tl - \vfil - \begin{flushright} - \clist_map_inline:nn { origsign, id, origdate } - { \__nju_vskip: \__nju_name:n { ##1 } : \__nju_uline:n { 7 em } } - \end{flushright} - \vfil - \normalfont \normalsize + \UseInstance { nju } { origdecl-u } + \cleardoublepage } -\cs_new_protected:Npn \__nju_make_authdecl: +\cs_new_protected:Npn \__nju_make_decl_ii: { - \prg_do_nothing: } \__nju_declare_element:nn { abstract / title } { - content = \__nju_abs_title:V \c__nju_name_abstracttitle_tl, + content = \__nju_abs_title:N \c__nju_name_abstracttitle_tl, format = \bfseries \kaishu \zihao { -2 }, - bottom-skip = 1.2 cm + bottom-skip = 20 pt + } +\__nju_declare_element:nn { abstract / en / title } + { + content = \__nju_abs_title:N \c__nju_name_abstracttitle_en_tl, + format = \bfseries \kaishu \zihao { -2 }, + bottom-skip = 20 pt } \__nju_declare_element:nn { abstract / info } { - content = \__nju_abs_info_ug:nn { } { : }, + content = \__nju_abs_info_u:, format = \zihao { -4 } \kaishu, - bottom-skip = 1 cm, + bottom-skip = 15 pt, align = l } -\__nju_declare_element:nn { abstract / en / title } - { - content = \__nju_abs_title:V \c__nju_name_abstracttitle_en_tl, - format = \bfseries \kaishu \zihao { -2 }, - bottom-skip = 1.2 cm - } \__nju_declare_element:nn { abstract / en / info } { - content = \__nju_abs_info_ug:nn { _en } { :~ }, + content = \__nju_abs_info_en_u:, format = \zihao { -4 }, - bottom-skip = 1 cm, + bottom-skip = 15 pt, align = l } -\cs_new_protected:Npn \__nju_abs_info_ug:nn #1#2 +\cs_new_protected:Npn \__nju_abs_info_u: + { \__nju_abs_info_u:nn { } { \c__nju_name_colon_tl } } +\cs_new_protected:Npn \__nju_abs_info_en_u: + { \__nju_abs_info_u:nn { _en } { \c__nju_name_colon_en_tl } } +\cs_new_protected:Npn \__nju_abs_info_u:nn #1#2 { - \tl_if_blank:eTF { #1 } - { \c__nju_name_title_tl } - { \clist_item:Nn \c__nju_name_type_en_clist { \g__nju_info_type_int } } - #2 \tl_use:c { g__nju_info_title #1 _tl } \\ - \tl_set_eq:NN \c__nju_name_author_tl \c__nju_name_author_a_tl - \clist_map_inline:nn { dept, major, author, supvfull } - { \__nju_name:n { ##1 #1 } #2 \__nju_info:n { ##1 #1 } \\ } - \__nju_name:n { abstract #1 } #2 + \tl_set_eq:NN \c__nju_name_author_tl \c__nju_name_authora_tl + \clist_map_inline:nn { title, dept, major, author, supvfull } + { + \__nju_name:nn { abslabel #1 } { ##1 #1 } #2 + \__nju_info:n { ##1 #1 } \\ + } + \__nju_name:nn { abslabel #1 } { abstract #1 } #2 } \cs_new_protected:Npn \__nju_make_abstract: { @@ -149,69 +183,52 @@ } \clist_map_inline:nn { - { acknowledgement } { 致 \qquad{} 谢 }, - { tableofcontents } { 目 \qquad{} 录 }, - { id } { 学号 }, - { listoffigures } { 插图目录 }, - { listoftables } { 表格目录 }, - { notation } { 符号表 }, - { origdate } { 日期 }, - { paperlist } { 发表文章目录 }, - { pdfcreator } { LaTeX~ with~ njuthesis~ class }, - { preface } { 前 \qquad{} 言 }, - { supv_ii } { 第二导师 }, - { supv_ttl } { 职称 } - } - { \__nju_define_name:nn #1 } -\clist_map_inline:nn - { - { abstract } { 摘要 } { ABSTRACT }, - % 用于书签的摘要名称字样 - { abstract_a } { 中文摘要 } { ABSTRACT }, - % 用于小标题的摘要名称字样 - { abstract_b } { 摘\qquad{}要 } { ABSTRACT }, - { appendix } { 附录 } { appendix }, - { blankdate } { \qquad{}年 \quad{}月 \quad{}日 } { }, - { blankdate_a } { \njuline{\qquad\qquad} 年 - \njuline{\qquad} 月 \njuline{\qquad} 日 } { }, - { comma } { : } { :~ }, - { dept } { 院系 } { DEPARTMENT }, - { figure } { 图 } { figure }, - { keywords } { 关键词 } { Keywords }, - { lang } { 中文 } { 英文 }, - { nju } { 南京大学 } { Nanjing~ University }, - { table } { 表 } { table } - } - { \__nju_define_name:nnn #1 } -\clist_map_inline:nn - { - % 用于摘要的作者名称字样 - { author_a } { 本科生姓名 }, - { grade } { 年级 }, - { origdecl } { \c__nju_name_nju_tl - 本科毕业论文(设计) \\ 诚信承诺书 }, - { origsign } { 作者签名 }, - { submitdate } { 提交日期 }, - { supv } { 指导教师 }, - { title } { 题目 }, - { type } { 本科生毕业论文(设计、作品) }, - { ug } { 本科 } + { acknowledgement } { 致 \qquad{} 谢 }, + { author a } { 本科生姓名 }, + { date } { 日期 }, + { grade } { 年级 }, + { id } { 学号 }, + { listoffigures } { 插图目录 }, + { listoftables } { 表格目录 }, + { notation } { 符号表 }, + { orig decl } + { 南京大学本科毕业论文(设计) \\ 诚信承诺书 }, + { orig sign } { 作者签名 }, + { paper list } { 发表文章目录 }, + { pdf creator } { LaTeX~ with~ njuthesis~ class }, + { preface } { 前 \qquad{} 言 }, + { submit date } { 提交日期 }, + { supv } { 指导教师 }, + { supv ii } { 第二导师 }, + { supv title } { 职称 }, + { tableofcontents } { 目 \qquad{} 录 }, } { \__nju_define_name:nn #1 } \clist_map_inline:nn { + { abstract } { 摘要 } { ABSTRACT }, + { abstract a } { 中文摘要 } { ABSTRACT }, + { abstract b } { 摘\qquad{}要 } { ABSTRACT }, { abstracttitle } - { - \c__nju_name_nju_tl \c__nju_name_type_tl - \c__nju_name_lang_tl \c__nju_name_abstract_tl - } - { - \c__nju_name_nju_tl \c__nju_name_type_tl - \c__nju_name_lang_en_tl \c__nju_name_abstract_tl - }, - { author } { 学生姓名 } { UNDERGRADUATE }, - { major } { 专业 } { SPECIALIZATION }, - { supvfull } { 指导教师(姓名、职称) } { MENTOR } + { 南京大学本科生毕业论文(设计、作品)中文摘要 } + { 南京大学本科生毕业论文(设计、作品)英文摘要 }, + { appendix } { 附录 } { appendix }, + { author } { 学生姓名 } { UNDERGRADUATE }, + { blankdate } { \qquad{}年 \quad{}月 \quad{}日 } { }, + { blankdate a } { \njuline{\qquad\qquad} 年 + \njuline{\qquad} 月 \njuline{\qquad} 日 } { }, + { colon } { : } { : \c_space_tl }, + { dept } { 院系 } { DEPARTMENT }, + { figure } { 图 } { figure }, + { keywords } { 关键词 } { KEYWORDS }, + { lang } { 中文 } { 英文 }, + { major } { 专业 } { SPECIALIZATION }, + { nju } { 南京大学 } { Nanjing~ University }, + { suffix } { } { _en }, + { supv full } { 指导教师(姓名、职称) } { MENTOR }, + { table } { 表 } { table }, + { title } { 题目 } { THESIS }, + { type } { 本科毕业论文 } { u } } { \__nju_define_name:nnn #1 } \tl_const:Nn \c__nju_text_origdecl_tl @@ -224,39 +241,40 @@ } \clist_map_inline:nn { - { axiom } { 公理 } { Axiom }, - { corollary } { 推论 } { Corollary }, - { definition } { 定义 } { Definition }, - { example } { 例 } { Example }, - { lemma } { 引理 } { Lemma }, - { proof } { 证明 } { Proof }, - { theorem } { 定理 } { Theorem } - } - { \__nju_add_theorem_type:nnn #1 } -\clist_map_inline:nn - { - { coverlabel } { 68 pt }, - { coverlineskip } { 40 pt }, - { coveruline } { 270 pt }, - { emblemwidth } { 68 pt }, - { namewidth } { 300 pt }, - { smallhskip } { 5 pt }, - { smallvskip } { 1 ex } + { c lineskip } { 36 pt }, + { c label wd } { 68 pt }, + { c rule wd } { 270 pt }, + { emblem wd } { 68 pt }, + { emblem wd i } { 68 pt }, + { name wd } { 300 pt }, + { rule ht i } { .4 pt }, + { rule ht ii } { .8 pt }, + { rule dp i } { -.7 ex }, + { rule dp ii } { -.9 ex }, + { rule dp iii } { -1.2 ex }, + { h sep } { 5 pt }, + { v sep } { 1 ex }, + { chapter before } { 10 pt }, + { chapter after } { 60 pt } } { \__nju_define_dim:nn #1 } \clist_map_inline:nn { { pagestyle } { plain }, - { emblemcolor } { black }, - { namecolor } { black }, - { section } { \large \normalfont \sffamily }, - { chapter } { \c__nju_fmt_section_tl \centering }, - { chapterintoc } { \c__nju_fmt_section_tl }, - { subsection } { \c__nju_fmt_section_tl }, - { subsubsection } { \c__nju_fmt_section_tl }, - { paragraph } { \c__nju_fmt_section_tl }, - { subparagraph } { \c__nju_fmt_section_tl }, - { toctitle } { \centering \zihao { 3 } \bfseries }, + { abslabel } { \bfseries }, + { abslabel_en } { }, + { cover title } { \bfseries }, + { cover label } { \kaishu }, + { emblem color } { black }, + { name color } { black }, + { section } { \bigger \normalfont \sffamily }, + { chapter } { \c__nju_fmt_section_tl \centering }, + { chapterintoc } { \c__nju_fmt_section_tl }, + { subsection } { \c__nju_fmt_section_tl }, + { subsubsection } { \c__nju_fmt_section_tl }, + { paragraph } { \c__nju_fmt_section_tl }, + { subparagraph } { \c__nju_fmt_section_tl }, + { toc title } { \centering \zihao { 3 } \bfseries }, { header } { \small \kaishu }, { footer } { \small \rmfamily } } |