Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

本科毕业设计(论文)模板计划 #5

Open
sikouhjw opened this issue Nov 18, 2021 · 7 comments
Open

本科毕业设计(论文)模板计划 #5

sikouhjw opened this issue Nov 18, 2021 · 7 comments

Comments

@sikouhjw
Copy link
Owner

主要参考资料

需求

多个学院的(副)院长希望制作本科的模板

主要困难

本科规范与研究生规范差别过大,不容易在同一个 cls 中修改,如果分成两个 cls,同步某些代码会很繁琐

@sikouhjw sikouhjw pinned this issue Nov 25, 2021
@PeterWang-dev
Copy link

支持一下学长!造福广大校友!

@note286
Copy link

note286 commented Aug 13, 2022

可以考虑使用dtx开发,这样拆分成两个cls,同时可以共用部分代码,非常方便。

可参考 note286/xduts: 西安电子科技大学LaTeX套装

@sikouhjw
Copy link
Owner Author

可以考虑使用dtx开发,这样拆分成两个cls,同时可以共用部分代码,非常方便。

可参考 note286/xduts: 西安电子科技大学LaTeX套装

好主意,就是我有点懒

@note286
Copy link

note286 commented Aug 13, 2022

哈哈哈,没有deadline,想啥时候干啥时候干。

@xkwxdyy
Copy link

xkwxdyy commented Aug 13, 2022

其实吧,不用 dtx 也可以共用。以我正在重写的 whu-thesis 为例:

% 页面尺寸设置

% 统一都是 A4 纸大小
\geometry{paper = a4paper}

% 开题报告
\cs_new:Npn \__whu_proposal_set_paper_size:
  {
    \geometry
      {
        left       = 31.75mm,
        right      = 31.75mm,
        top        = 25.4mm,
        bottom     = 25.4mm,
        headheight = 0pt,
        headsep    = 0pt
      }
  }
% 本科
\cs_new:Npn \__whu_bachelor_set_paper_size:
  {
    \geometry
      {
        left       = 30mm,
        right      = 30mm,
        top        = 25mm,
        bottom     = 20mm,
        headheight = 3mm,
        headsep    = 2mm,
        footskip   = 6mm
      }
  }
% 硕士
\cs_new:Npn \__whu_master_set_paper_size:
  {
    \geometry
      {
        left       = 28mm,
        right      = 25mm,
        top        = 30mm,
        bottom     = 29mm,
      }
  }
% 博士
\cs_new:Npn \__whu_doctor_set_paper_size:
  {
    \geometry
      {
        left       = 29mm,
        right      = 25mm,
        top        = 30mm,
        bottom     = 29mm,
      }
  }

\int_case:Vn \g__whu_thesis_type_int  
  {
    % 开题报告
    {1} { \__whu_proposal_set_paper_size: }
    % 本科
    {2} { \__whu_bachelor_set_paper_size: }
    % 硕士
    {3} { \__whu_master_set_paper_size: }
    % 博士
    {4} { \__whu_doctor_set_paper_size: }
  }

@note286
Copy link

note286 commented Aug 13, 2022

@xkwxdyy 快拥抱dtx,不能白教你(●'◡'●)

@xkwxdyy
Copy link

xkwxdyy commented Aug 13, 2022

@xkwxdyy 快拥抱dtx,不能白教你(●'◡'●)

目前来说,学习成本蛮高,因为不仅是 dtx 的相关,还要学一些 makefile 之类的操作,等以后有空再看看吧。不急,以后肯定还有很多项目会开发的

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants