├── src ├── support │ ├── tutorial │ │ ├── build │ │ │ └── .gitkeep │ │ ├── head.png │ │ ├── plant.jpg │ │ ├── vi │ │ │ ├── sjtug.pdf │ │ │ └── sjtugtext.pdf │ │ ├── step22.tex │ │ ├── middle.tex │ │ ├── step1.tex │ │ ├── step8+.tex │ │ ├── contrib.tex │ │ ├── gen_outer.sh │ │ ├── maincontents.tex │ │ ├── step2shadow.tex │ │ ├── step2split.tex │ │ ├── step2tree.tex │ │ ├── step7+.tex │ │ ├── step2default.tex │ │ ├── step2sidebar.tex │ │ ├── step2infolines.tex │ │ ├── step2miniframes.tex │ │ ├── step2smoothbars.tex │ │ ├── step2smoothtree.tex │ │ ├── step6+.tex │ │ ├── step2.tex │ │ ├── test.csv │ │ ├── step9+.tex │ │ ├── step7s.tex │ │ ├── step0.tex │ │ ├── step5.tex │ │ ├── step23.tex │ │ ├── stepdual.tex │ │ ├── step10.tex │ │ ├── step25.tex │ │ ├── step11.tex │ │ ├── step17+_.tex │ │ ├── step12.tex │ │ ├── step4.tex │ │ ├── step15.tex │ │ ├── step16+-.tex │ │ ├── step19.tex │ │ ├── commonheader.tex │ │ ├── my.sty │ │ ├── step18+-.tex │ │ ├── step24.tex │ │ ├── step3.tex │ │ ├── step13.tex │ │ ├── step14.tex │ │ ├── stepalgorithm.tex │ │ ├── step21.tex │ │ ├── step2bd.tex │ │ ├── step2bl.tex │ │ ├── step20.tex │ │ ├── reference.bib │ │ ├── step2tb.tex │ │ └── stepalgo.tex │ ├── sjtug.pdf │ ├── sjtug_text.pdf │ ├── step.template.tex │ ├── newcontrib.template.tex │ ├── cover.tex │ ├── contrib.template.tex │ ├── beamerthemenosjtubeamer.sty │ ├── sjtubeamerthemenewcontrib.template.ltx │ └── cover.template.tex ├── source │ ├── vi │ │ ├── sjtu-vi-dlogo.pdf │ │ ├── sjtu-vi-enlogo.pdf │ │ ├── sjtu-vi-sjtubg.png │ │ ├── sjtu-vi-vlogo.pdf │ │ ├── sjtu-vi-zhlogo.pdf │ │ ├── sjtu-vi-sjtubadge.pdf │ │ ├── sjtu-vi-sjtugate.png │ │ └── sjtu-vi-sjtuphoto.jpg │ ├── beamerfontthemesjtubeamer.dtx │ ├── beamerthemesjtubeamer.ins │ ├── beamercolorthemesjtubeamer.dtx │ ├── beamerthemesjtubeamer.dtx │ └── beamerouterthemesjtubeamer.dtx ├── testfiles │ ├── font.tlg │ ├── outer.tlg │ ├── color.tlg │ ├── inner.tlg │ ├── outer.lvt │ ├── font.lvt │ ├── sjtuvi.tlg │ ├── inner.lvt │ ├── color.lvt │ └── sjtuvi.lvt ├── doc │ └── ref.bib └── MANIFEST.md ├── figures ├── Knuth.jpg ├── Lamport.jpg ├── sjtug-logo.pdf ├── slides-beamer.pdf ├── zut-fibeamer.pdf ├── sjtu-badge-blue.pdf ├── sjtu-logo-white.pdf ├── sjtuthesis-cover.pdf ├── TFZsuperellipse-crop.pdf ├── sjtuthesis-download.png └── ieee-conference-template.pdf ├── vi ├── sjtu-vi-dlogo.pdf ├── sjtu-vi-vlogo.pdf ├── sjtu-vi-enlogo.pdf ├── sjtu-vi-sjtubg.png ├── sjtu-vi-sjtugate.png ├── sjtu-vi-zhlogo.pdf ├── sjtu-vi-sjtubadge.pdf └── sjtu-vi-sjtuphoto.jpg ├── contrib ├── sjtug │ ├── vi │ │ ├── sjtug.pdf │ │ └── sjtugtext.pdf │ ├── sjtug.tex │ └── sjtubeamerthemesjtug.ltx ├── poster │ ├── ref.bib │ ├── poster.tex │ └── sjtubeamerthemeposter.ltx └── minted │ ├── minted.tex │ └── sjtubeamerthememinted.ltx ├── ref.bib ├── latexmkrc ├── latexindent.yaml ├── beamerfontthemesjtubeamer.sty ├── Makefile ├── CONTRIBUTING.md ├── beamercolorthemesjtubeamer.sty ├── beamerthemesjtubeamer.sty ├── beamerouterthemesjtubeamer.sty ├── main.tex ├── contents ├── summary.tex └── thesis.tex ├── README.md ├── README_en.md ├── sjtuvi.sty ├── LICENSE └── beamerinnerthemesjtubeamer.sty /src/support/tutorial/build/.gitkeep: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /figures/Knuth.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/Knuth.jpg -------------------------------------------------------------------------------- /figures/Lamport.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/Lamport.jpg -------------------------------------------------------------------------------- /vi/sjtu-vi-dlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-dlogo.pdf -------------------------------------------------------------------------------- /vi/sjtu-vi-vlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-vlogo.pdf -------------------------------------------------------------------------------- /figures/sjtug-logo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/sjtug-logo.pdf -------------------------------------------------------------------------------- /src/support/sjtug.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/sjtug.pdf -------------------------------------------------------------------------------- /vi/sjtu-vi-enlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-enlogo.pdf -------------------------------------------------------------------------------- /vi/sjtu-vi-sjtubg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-sjtubg.png -------------------------------------------------------------------------------- /vi/sjtu-vi-sjtugate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-sjtugate.png -------------------------------------------------------------------------------- /vi/sjtu-vi-zhlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-zhlogo.pdf -------------------------------------------------------------------------------- /figures/slides-beamer.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/slides-beamer.pdf -------------------------------------------------------------------------------- /figures/zut-fibeamer.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/zut-fibeamer.pdf -------------------------------------------------------------------------------- /vi/sjtu-vi-sjtubadge.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-sjtubadge.pdf -------------------------------------------------------------------------------- /vi/sjtu-vi-sjtuphoto.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/vi/sjtu-vi-sjtuphoto.jpg -------------------------------------------------------------------------------- /contrib/sjtug/vi/sjtug.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/contrib/sjtug/vi/sjtug.pdf -------------------------------------------------------------------------------- /figures/sjtu-badge-blue.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/sjtu-badge-blue.pdf -------------------------------------------------------------------------------- /figures/sjtu-logo-white.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/sjtu-logo-white.pdf -------------------------------------------------------------------------------- /figures/sjtuthesis-cover.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/sjtuthesis-cover.pdf -------------------------------------------------------------------------------- /src/support/sjtug_text.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/sjtug_text.pdf -------------------------------------------------------------------------------- /contrib/sjtug/vi/sjtugtext.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/contrib/sjtug/vi/sjtugtext.pdf -------------------------------------------------------------------------------- /src/support/tutorial/head.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/tutorial/head.png -------------------------------------------------------------------------------- /src/support/tutorial/plant.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/tutorial/plant.jpg -------------------------------------------------------------------------------- /figures/TFZsuperellipse-crop.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/TFZsuperellipse-crop.pdf -------------------------------------------------------------------------------- /figures/sjtuthesis-download.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/sjtuthesis-download.png -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-dlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-dlogo.pdf -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-enlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-enlogo.pdf -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-sjtubg.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-sjtubg.png -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-vlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-vlogo.pdf -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-zhlogo.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-zhlogo.pdf -------------------------------------------------------------------------------- /src/support/tutorial/vi/sjtug.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/tutorial/vi/sjtug.pdf -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-sjtubadge.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-sjtubadge.pdf -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-sjtugate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-sjtugate.png -------------------------------------------------------------------------------- /src/source/vi/sjtu-vi-sjtuphoto.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/source/vi/sjtu-vi-sjtuphoto.jpg -------------------------------------------------------------------------------- /figures/ieee-conference-template.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/figures/ieee-conference-template.pdf -------------------------------------------------------------------------------- /src/support/tutorial/vi/sjtugtext.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/sjtug/SJTUBeamer/main/src/support/tutorial/vi/sjtugtext.pdf -------------------------------------------------------------------------------- /src/testfiles/font.tlg: -------------------------------------------------------------------------------- 1 | This is a generated file for the l3build validation system. 2 | Don't change this file in any respect. 3 | [1 4 | ] 5 | -------------------------------------------------------------------------------- /src/testfiles/outer.tlg: -------------------------------------------------------------------------------- 1 | This is a generated file for the l3build validation system. 2 | Don't change this file in any respect. 3 | [1 4 | ] 5 | -------------------------------------------------------------------------------- /src/support/tutorial/step22.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \begin{document} 4 | \logo{\dlogo} 5 | \makebottom 6 | \end{document} -------------------------------------------------------------------------------- /src/testfiles/color.tlg: -------------------------------------------------------------------------------- 1 | This is a generated file for the l3build validation system. 2 | Don't change this file in any respect. 3 | [1 4 | ] 5 | [2 6 | ] 7 | -------------------------------------------------------------------------------- /src/support/tutorial/middle.tex: -------------------------------------------------------------------------------- 1 | \begin{frame} 2 | \frametitle{如何套用 SJTUBeamer?} 3 | 4 | 非常简单,只需 \texttt{\textbackslash{}usetheme\{sjtubeamer\}} 即可。 5 | 6 | \end{frame} -------------------------------------------------------------------------------- /src/testfiles/inner.tlg: -------------------------------------------------------------------------------- 1 | This is a generated file for the l3build validation system. 2 | Don't change this file in any respect. 3 | [1 4 | ] 5 | [2 6 | ] 7 | [3 8 | ] 9 | -------------------------------------------------------------------------------- /src/support/tutorial/step1.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | 欢迎使用 SJTUBeamer! 6 | \end{frame} 7 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step8+.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169] 2 | {ctexbeamer} 3 | \usetheme[min]{sjtubeamer} 4 | \begin{document} 5 | \part{SJTUBeamer} \include{maincontents.tex} 6 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/contrib.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[my]{sjtubeamer} 3 | \usesjtutheme{sjtug} 4 | \begin{document} 5 | \title{标题} 6 | \subtitle{副标题} 7 | \author{作者} 8 | \maketitle 9 | \end{document} -------------------------------------------------------------------------------- /src/support/step.template.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[]{sjtubeamer} 3 | 4 | % preamble... 5 | 6 | \begin{document} 7 | \begin{frame} 8 | 9 | % content ... 10 | 11 | \end{frame} 12 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/gen_outer.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | outers=(default infolines smoothbars sidebar split shadow tree smoothtree) 4 | for outer in ${outers[@]}; 5 | do 6 | sed -e "s|miniframes|$outer|g" step2miniframes.tex > step2$outer.tex 7 | done -------------------------------------------------------------------------------- /src/support/newcontrib.template.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \usesjtutheme{newcontrib} 4 | \begin{document} 5 | \begin{frame} 6 | \frametitle{newcontrib 插件} 7 | 8 | % 插件文档... 9 | 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/maincontents.tex: -------------------------------------------------------------------------------- 1 | \section{前言} 2 | \frame{} 3 | \section{SJTUBeamer 的安装} 4 | \frame{} 5 | \section{SJTUBeamer 的功能} 6 | \frame{} 7 | \subsection{标题页与结束页} 8 | \frame{} 9 | \subsection{可适应性} 10 | \frame{} 11 | \subsection{可扩展性} 12 | \frame{} -------------------------------------------------------------------------------- /src/support/tutorial/step2shadow.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[shadow]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2split.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[split]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2tree.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[tree]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step7+.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169]{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \AtBeginSubsection[]{ 5 | \begin{frame} 6 | \subsectionpage 7 | \end{frame} 8 | } 9 | \include{maincontents.tex} 10 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2default.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[default]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2sidebar.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[sidebar]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /contrib/poster/ref.bib: -------------------------------------------------------------------------------- 1 | @Misc{beamerposter, 2 | author = {Dreuw, Philippe and Deselaers, Thomas}, 3 | title = {The beamerposter package}, 4 | year = {2021}, 5 | url = {https://github.com/deselaers/latex-beamerposter}, 6 | } 7 | 8 | @Comment{jabref-meta: databaseType:bibtex;} 9 | -------------------------------------------------------------------------------- /src/support/tutorial/step2infolines.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[infolines]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2miniframes.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[miniframes]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2smoothbars.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[smoothbars]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2smoothtree.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[smoothtree]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step6+.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169]{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \frametitle{目录} 6 | \tableofcontents 7 | [hideallsubsections] 8 | \end{frame} 9 | \include{maincontents.tex} 10 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169]{ctexbeamer} 2 | \usetheme[blue,light,shadow]{sjtubeamer} 3 | \begin{document} 4 | \title[SJTUBeamer]{SJTUBeamer} 5 | \section{节} 6 | \subsection{小节} 7 | \begin{frame} 8 | \frametitle{标题} 9 | 正文 10 | \end{frame} 11 | \end{document} -------------------------------------------------------------------------------- /ref.bib: -------------------------------------------------------------------------------- 1 | @article{thelegendofjiang, 2 | title={《他改变了中国: 江泽民传》}, 3 | author={罗伯特 and 劳伦斯 and 库恩}, 4 | journal={中国企业家}, 5 | number={5}, 6 | pages={120--120}, 7 | year={2005} 8 | } 9 | 10 | @phdthesis{devoftech, 11 | title={新时期我国信息技术产业的发展}, 12 | author={江泽民}, 13 | year={2008} 14 | } 15 | -------------------------------------------------------------------------------- /src/testfiles/outer.lvt: -------------------------------------------------------------------------------- 1 | \documentclass[]{beamer} 2 | \useoutertheme[default]{sjtubeamer} 3 | \input{regression-test.tex} 4 | \begin{document} 5 | \START 6 | \begin{frame} 7 | \frametitle{Outer theme} 8 | Test for outer theme. 9 | \end{frame} 10 | \END 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/test.csv: -------------------------------------------------------------------------------- 1 | $n$ ,Quick,Cocktail 2 | 1 ,1.00 ,0.00 3 | 2 ,3.00 ,1.00 4 | 3 ,5.66667,3.00 5 | 4 ,8.83333,5.95833 6 | 5 ,12.40 ,9.975 7 | 6 ,16.30 ,14.6708 8 | 7 ,20.4857,20.5272 9 | 8 ,24.9214,27.0279 10 | 9 ,29.5794,34.4942 -------------------------------------------------------------------------------- /src/support/tutorial/step9+.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169]{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \AtBeginSection[]{ 5 | \begin{frame} 6 | \tableofcontents 7 | [currentsection, subsectionstyle=show/shaded/hide] 8 | \end{frame} 9 | } 10 | \include{maincontents.tex} 11 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step7s.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \begin{document} 4 | \setbeamertemplate{sectioning pages}[maxplus] 5 | \part{maxplus} \setbeamertemplate{sectioning pages}[max] 6 | \part{max} \setbeamertemplate{sectioning pages}[min] 7 | \setbeamertemplate{background}{} 8 | \part{min} 9 | \end{document} -------------------------------------------------------------------------------- /src/support/cover.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{pdfpages} 3 | \includepdfset{fitpaper=true,pages=1-last,nup=3x3,frame=true} 4 | 5 | \begin{document} 6 | \includepdf{cover-red-dark.pdf} 7 | \includepdf{cover-red-light.pdf} 8 | \includepdf{cover-blue-dark.pdf} 9 | \includepdf{cover-blue-light.pdf} 10 | \end{document} 11 | -------------------------------------------------------------------------------- /src/support/tutorial/step0.tex: -------------------------------------------------------------------------------- 1 | %&commonheader 2 | \endofdump 3 | \usepackage{ctex} 4 | \usetheme{sjtubeamer} 5 | \begin{document} 6 | \begin{frame} 7 | 欢迎使用 SJTUBeamer! 8 | \end{frame} 9 | \end{document} 10 | % This file will test the functionality of caching. 11 | % If this fails, the build system will fallback to normal compilation. -------------------------------------------------------------------------------- /src/support/tutorial/step5.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169] 2 | {ctexbeamer} 3 | \usetheme[maxplus,blue,shadow] 4 | {sjtubeamer} 5 | \begin{document} 6 | \title{SJTUBeamer} 7 | \subtitle{使用教程} 8 | \author{SJTUG} 9 | \institute[SJTU] 10 | {Shanghai Jiao Tong University} 11 | \date{\today} 12 | \maketitle 13 | \makebottom 14 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step23.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme[min,blue,light]{sjtubeamer} 3 | \begin{document} 4 | \title{SJTUBeamer} 5 | \subtitle{使用教程} 6 | \author{} 7 | \institute[School of Mathematical Sciences] 8 | {数学科学学院} 9 | \date{\today} 10 | \titlegraphic{ 11 | \includegraphics{head.png} 12 | } 13 | \maketitle 14 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/stepdual.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \setbeameroption{show notes on second screen} 4 | \begin{document} 5 | \title{讲座} 6 | \section{节} 7 | \subsection{小节} 8 | \begin{frame} 9 | \frametitle{含有备注} 10 | 这一页有一些备注。 11 | \note[item]{第一个备注。} 12 | \note[item]{第二个备注。} 13 | \end{frame} 14 | \end{document} -------------------------------------------------------------------------------- /src/testfiles/font.lvt: -------------------------------------------------------------------------------- 1 | \documentclass[draft]{beamer} 2 | \usefonttheme[]{sjtubeamer} 3 | \input{regression-test.tex} 4 | \begin{document} 5 | \START 6 | \begin{frame} 7 | \frametitle{Title test} 8 | \framesubtitle{Subtitle test} 9 | Content test. 10 | \end{frame} 11 | \END 12 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step10.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[blue,split]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \frametitle{SJTUBeamer 的功能} 6 | 7 | \paragraph{可适应性} 适应多种 \emph{外样式 Outer theme}。 8 | 9 | \highlight[csecondary]{可扩展性} 10 | 用户可以添加自己的\alert{模板}。 11 | 12 | \stamptext{注} SJTUBeamer 的功能在其他模板中可能不通用。 13 | \end{frame} 14 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step25.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[my]{sjtubeamer} 3 | \usepackage{my} 4 | \begin{document} 5 | \begin{frame} 6 | \frametitle{使用自定主题} 7 | \begin{itemize} 8 | \item 可以通过使用 \texttt{my} 选项 9 | \item 加载自定义的 \texttt{my} 包 10 | \item 使用自定义的 \texttt{vi} 徽标 11 | \item 来使用自定主题 12 | \end{itemize} 13 | \end{frame} 14 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step11.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[maxplus]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \frametitle{一些盒子} 6 | \begin{block}{盒子} 7 | 这是一个盒子 8 | \end{block} 9 | \begin{alertblock}{注意} 10 | 注意内容 11 | \end{alertblock} 12 | \begin{exampleblock}{示例} 13 | 示例内容 14 | \end{exampleblock} 15 | \end{frame} 16 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step17+_.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \usepackage{gbt7714} 4 | \begin{document} 5 | \begin{frame} 6 | SJTUBeamer 是基于上海交通大学视觉形象系统 \cite{viman} 制作的 \LaTeX{} 幻灯片模板。 7 | \end{frame} 8 | \begin{frame}[allowframebreaks] 9 | \frametitle{参考文献} 10 | \renewcommand{\bibfont}{\tiny} 11 | \bibliography{reference} 12 | \end{frame} 13 | \end{document} -------------------------------------------------------------------------------- /latexmkrc: -------------------------------------------------------------------------------- 1 | # Latexmk configuration file. 2 | 3 | # Set environment variables. 4 | 5 | # Set timezone. 6 | $ENV{'TZ'}='Asia/Shanghai'; 7 | 8 | $pdf_mode = 5; 9 | $postscript_mode = $dvi_mode = 0; 10 | 11 | # Always try to embed fonts, ignoring licensing flags, etc. 12 | $xdvipdfmx = 'xdvipdfmx -E -o %D %O %S'; 13 | 14 | # Files to clean. 15 | $clean_ext = 'bbl glo gls hd loa run.xml thm xdv'; 16 | -------------------------------------------------------------------------------- /src/support/tutorial/step12.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min,infolines]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \frametitle{图} 6 | \begin{figure} 7 | \centering 8 | \begin{stampbox} 9 | \includegraphics 10 | [height=.3\textheight] 11 | {plant.jpg} 12 | \end{stampbox} 13 | \caption{图片标题} 14 | \end{figure} 15 | \end{frame} 16 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step4.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169,draft]{ctexbeamer} 2 | \usetheme[blue,light,shadow]{sjtubeamer} 3 | \begin{document} 4 | 5 | %\include{intro.tex} 6 | 7 | \include{middle.tex} 8 | % \begin{frame} 9 | % \frametitle{如何套用 SJTUBeamer?} 10 | % 非常简单,只需 \texttt{\textbackslash{} 11 | % usetheme\{sjtubeamer\}} 即可。 12 | % \end{frame} 13 | 14 | %\include{end.tex} 15 | 16 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step15.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame}[fragile] 5 | \frametitle{代码块} 6 | \begin{codeblock} 7 | [language=c++] 8 | {C++代码} 9 | #include 10 | 11 | int main(){ 12 | // Console Output 13 | std::cout << "Hello, SJTU!" << std::endl; 14 | return 0; 15 | } 16 | \end{codeblock} 17 | \end{frame} 18 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step16+-.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[light]{sjtubeamer} 3 | \usepackage[style=gb7714-2015] 4 | {biblatex} 5 | \addbibresource{reference.bib} 6 | \begin{document} 7 | \begin{frame} 8 | 上海交通大学标准色是红色 9 | (C20 M100 Y100 K0)。 10 | 色彩的使用应遵守色彩规范。 11 | \footnote{详见视觉形象系统使用手册。} 12 | 13 | \texttt{beamer} 样式分为色彩样式、 14 | 字体样式、内样式和外样式。 15 | \footfullcite{beamerman} 16 | \end{frame} 17 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step19.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \usepackage{pgfplotstable} 4 | \begin{document} 5 | \begin{frame} 6 | \frametitle{表格} 7 | \begin{table} 8 | \caption{表格标题} 9 | \pgfplotstabletypeset[ 10 | columns/Quick/.style={ 11 | dec sep align}, 12 | columns/Cocktail/.style={ 13 | dec sep align}, 14 | column type=r] 15 | {test.csv} 16 | \end{table} 17 | \end{frame} 18 | \end{document} -------------------------------------------------------------------------------- /src/support/contrib.template.tex: -------------------------------------------------------------------------------- 1 | \documentclass{standalone} 2 | \usepackage{tcolorbox} 3 | \tcbuselibrary{raster} 4 | \tcbuselibrary{skins} 5 | \begin{document} 6 | \begin{tcbraster}[raster columns=3,colframe=gray,colback=white, 7 | colbacktitle=gray!50!white,fonttitle=\small\bfseries\ttfamily, 8 | left=0pt,right=0pt,top=0pt,bottom=0pt,boxsep=0pt,boxrule=0.6pt, 9 | toptitle=1mm,bottomtitle=1mm,drop lifted shadow,center title] 10 | \tcbincludepdf{.pdf} 11 | \end{tcbraster} 12 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/commonheader.tex: -------------------------------------------------------------------------------- 1 | \RequirePackage[OT1]{fontenc} % old 7-bit to dump 2 | \documentclass{beamer} 3 | \makeatletter 4 | \def\sjtubeamer@compatible{false} 5 | \makeatother 6 | \usepackage{sjtuvi} % contains TikZ. 7 | \usepackage[zh]{sjtucover} % temporarily use zh config, since the justification will first check if it is ctexbeamer then use caching. 8 | \usepackage{tcolorbox} 9 | \tcbuselibrary{skins} 10 | \tcbuselibrary{listingsutf8} 11 | \begin{document} 12 | % intentionally left blank 13 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/my.sty: -------------------------------------------------------------------------------- 1 | \usepackage{sjtuvi} 2 | \usepackage{sjtucover} 3 | \logo{\resizebox{1cm}{!}{\includegraphics{vi/sjtug.pdf}}} 4 | \titlegraphic{\includegraphics{sjtuphoto}} 5 | \definecolor{cprimary}{RGB}{225,111,11} 6 | \definelogo{sjtugtext}{vi/sjtugtext.pdf}{0}{0} 7 | \setbeamertemplate{background}{ 8 | \bgcenterbox{ 9 | \sjtugtext[cprimary,opacity=0.15] 10 | } 11 | } 12 | \setbeamertemplate{title page}[maxplus] 13 | \setbeamertemplate{bottom page}[min] 14 | \setbeamertemplate{sectioning pages}[min] -------------------------------------------------------------------------------- /src/support/tutorial/step18+-.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \begin{thebibliography}{00} 6 | \setbeamertemplate{bibliography item}[text] 7 | \bibitem{devoftech} 作者. 8 | \newblock 标题[J]. 9 | \newblock 期刊, 10 | \newblock 2008, 42(10): 1589. 11 | \end{thebibliography} 12 | \begin{bibliolist}{00} 13 | \bookitem \textsc{Author}. 14 | \newblock Title[M]. 15 | \newblock 2nd ed. Location: Press. 2004. 16 | \end{bibliolist} 17 | \end{frame} 18 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step24.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \tikzfading[name=fade cover, 4 | left color=transparent!20, 5 | right color=transparent!20 6 | ] 7 | \setbeamertemplate{background}{ 8 | \bgcenterbox{ 9 | \begin{tikzpicture} 10 | \stamparray{16pt}{(0,0)} 11 | {(\paperwidth,\paperheight)} 12 | \fill[white, path fading=fade cover] 13 | (0,0) rectangle (\paperwidth,\paperheight); 14 | \end{tikzpicture} 15 | } 16 | } 17 | \begin{document} 18 | \begin{frame} 19 | 背景采用了印记矩阵的设计。 20 | \end{frame} 21 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step3.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169,draft]{ctexbeamer} 2 | \usetheme[blue,light,shadow]{sjtubeamer} 3 | \begin{document} 4 | \title{SJTUBeamer} 5 | \begin{frame} 6 | \frametitle{SJTUBeamer 优势在哪?} 7 | \begin{columns} 8 | \column{0.6\linewidth} 9 | \begin{itemize} 10 | \item 内置多种标题与尾页模板 11 | \item 方便插入交大相关视觉元素 12 | \item 模板可扩展性好 13 | \end{itemize} 14 | \column{0.4\linewidth} 15 | \includegraphics[width=\textwidth]{vi/sjtu-vi-sjtuphoto.jpg} 16 | \end{columns} 17 | \end{frame} 18 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step13.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \begin{columns}[T] 6 | \begin{column}{.5\textwidth} 7 | \begin{stampblock}[1]{Word} 8 | Microsoft\textsuperscript{\circledR{}} Word 所见即所得,适合短文档的快捷编辑,适用性广,功能丰富。 9 | \end{stampblock} 10 | \end{column} 11 | \begin{column}{.5\textwidth} 12 | \begin{stampblock}[2]{\LaTeX{}} 13 | \LaTeX{} 更适合长文档的结构性编辑,命令个性化便捷,排版文档美观正式。 14 | \end{stampblock} 15 | \end{column} 16 | \end{columns} 17 | \end{frame} 18 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step14.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \begin{document} 4 | \begin{frame} 5 | \begin{columns}[T] 6 | \begin{column}{.5\textwidth} 7 | \alert{\textbf{Word}} 8 | \stamphrule 9 | Microsoft\textsuperscript{\circledR{}} Word 所见即所得,适合短文档的快捷编辑,适用性广,功能丰富。 10 | \end{column} 11 | \textcolor{cprimary}{\vrule}\hfill 12 | \begin{column}{.5\textwidth} 13 | \alert{\textbf{\LaTeX{}}} 14 | \stamphrule 15 | \LaTeX{} 更适合长文档的结构性编辑,命令个性化便捷,排版文档美观正式。 16 | \end{column} 17 | \end{columns} 18 | \end{frame} 19 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/stepalgorithm.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \usepackage[ruled, linesnumbered]{algorithm2e} 4 | \begin{document} 5 | \begin{frame} 6 | \scalebox{0.5}{ 7 | \begin{algorithm}[H] 8 | \caption{A* 多序列比对}\label{alg:astar} 9 | \KwIn{$L$个字符串列表$S$,$\alpha$,$\delta$} 10 | \KwOut{minimum cost} 11 | \BlankLine 12 | $dist[\cdot]\leftarrow\infty$\; 13 | % 算法内容... 14 | \Return{$\infty$}\; 15 | \end{algorithm} 16 | } 17 | \begin{minipage}[c]{0.45\textwidth} 18 | 对该算法的说明。 19 | \end{minipage} 20 | \end{frame} 21 | \end{document} -------------------------------------------------------------------------------- /src/testfiles/sjtuvi.tlg: -------------------------------------------------------------------------------- 1 | This is a generated file for the l3build validation system. 2 | Don't change this file in any respect. 3 | [1 4 | ] 5 | [3 6 | ] 7 | ============================================================ 8 | TEST 1: EqualOption 9 | ============================================================ 10 | FALSE 11 | ============================================================ 12 | ============================================================ 13 | TEST 2: IsEmpty 14 | ============================================================ 15 | TRUE 16 | TRUE 17 | TRUE 18 | FALSE 19 | TRUE 20 | FALSE 21 | ============================================================ 22 | [5 23 | ] 24 | -------------------------------------------------------------------------------- /contrib/sjtug/sjtug.tex: -------------------------------------------------------------------------------- 1 | % 使用文档推荐不超过 9 页 2 | \documentclass[aspectratio=169]{ctexbeamer} % 使用 16:9 比例 3 | \usetheme[my]{sjtubeamer} 4 | \usesjtutheme{sjtug} % 可以添加 debug 参数 5 | \begin{document} 6 | \title{标题} 7 | \subtitle{副标题} 8 | \author{作者} 9 | \maketitle 10 | \begin{frame}[fragile] % 含有 codeblock 的页需要使用 fragile 参数 11 | \frametitle{\sjtugtext 主题} 12 | 这个主题采用了 SJTUG 的 logo,采用了自定义标题页。 13 | 14 | \begin{codeblock}[]{使用方法} 15 | \usesjtutheme{sjtug} 16 | \end{codeblock} 17 | 18 | \begin{description} 19 | \item[\texttt{debug}] 参数可以在使用 Lua\LaTeX{} 编译时调用 \texttt{lua-visual-debug} 20 | 宏包显示区块边界。 21 | \end{description} 22 | \end{frame} 23 | \makebottom 24 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step21.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme{sjtubeamer} 3 | \usetikzlibrary{math} 4 | \tikzexternalize[prefix=build/] 5 | \begin{document} 6 | \begin{frame} 7 | \frametitle{缓存插图} 8 | \begin{tikzpicture}[scale=0.7] 9 | \foreach \x in {1,...,7}{ 10 | \foreach \y in {\x,...,7}{ 11 | \draw (\x,\y-1)--(\x,\y); 12 | \draw (\x+1,\y)--(\x,\y); 13 | } 14 | } 15 | \foreach \x in {1,...,8}{ 16 | \pgfmathparse{int(\x-1)} 17 | \foreach \y in {\pgfmathresult,...,7}{ 18 | \node[draw,circle,fill=white,scale=0.6] 19 | at (\x,\y) {\x,\y}; 20 | } 21 | } 22 | \end{tikzpicture} 23 | \end{frame} 24 | \end{document} -------------------------------------------------------------------------------- /src/testfiles/inner.lvt: -------------------------------------------------------------------------------- 1 | \documentclass[]{beamer} 2 | \useinnertheme[min]{sjtubeamer} 3 | \input{regression-test.tex} 4 | \setbeamertemplate{background}{} % omit background 5 | \begin{document} 6 | \logo{} 7 | \START 8 | \part{Part test} 9 | \begin{frame} 10 | \paragraph{SJTUBeamer} is a beamer template for Shanghai Jiao Tong University. 11 | \end{frame} 12 | \begin{frame} 13 | \begin{stampbox} 14 | Test for a stampbox. 15 | \end{stampbox} 16 | \stamphrule 17 | \end{frame} 18 | \OMIT 19 | \begin{frame}[fragile] 20 | \frametitle{Code Block} 21 | \lstset{language=[LaTeX]TeX} 22 | \begin{codeblock}[]{\LaTeX{} Code} 23 | \documentclass{article} 24 | \begin{document} 25 | Hello, world! 26 | \end{document} 27 | \end{codeblock} 28 | \end{frame} 29 | \TIMO 30 | \END 31 | \end{document} -------------------------------------------------------------------------------- /src/testfiles/color.lvt: -------------------------------------------------------------------------------- 1 | \documentclass[draft]{beamer} 2 | \usecolortheme[red,dark]{sjtubeamer} 3 | \input{regression-test.tex} 4 | \begin{document} 5 | \START 6 | \begin{frame} 7 | \frametitle{Base color test} 8 | \textcolor{cprimary}{\ttfamily cprimary} color. 9 | 10 | \textcolor{csecondary}{\ttfamily csecondary} color. 11 | 12 | \textcolor{ctertiary}{\ttfamily ctertiary} color. 13 | \end{frame} 14 | \begin{frame} 15 | \frametitle{Palette color test} 16 | \begin{beamercolorbox}{palette primary} 17 | \ttfamily palette primary 18 | \end{beamercolorbox} 19 | \begin{beamercolorbox}{palette secondary} 20 | \ttfamily palette secondary 21 | \end{beamercolorbox} 22 | \begin{beamercolorbox}{palette tertiary} 23 | \ttfamily palette tertiary 24 | \end{beamercolorbox} 25 | \end{frame} 26 | \END 27 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2bd.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme[blue]{sjtubeamer} 3 | \begin{document} 4 | 5 | \title[SJTU Beamer Template] % 页脚显示标题 6 | {\textbf{上海交通大学 Beamer 模版}} % 首页标题 7 | 8 | \author[Anxue Chen, Alexara Wu, Log Creative] 9 | {Anxue Chen, Alexara Wu, Log Creative} 10 | 11 | \institute[SJTU]{Shanghai Jiao Tong University} 12 | 13 | \date{\today} 14 | 15 | \subtitle{blue,dark,maxplus} 16 | \logo{\resizebox{!}{0.7cm}{\zhlogo}} 17 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 18 | \setbeamertemplate{title page}[maxplus] 19 | \maketitle 20 | 21 | \subtitle{blue,dark,max} 22 | \logo{\resizebox{!}{1cm}{\sjtubadge}} 23 | \titlegraphic{\sjtubg[opacity=0.2]} 24 | \setbeamertemplate{title page}[max] 25 | \maketitle 26 | 27 | \subtitle{blue,dark,min} 28 | \logo{\resizebox{!}{0.7cm}{\enlogo}} 29 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 30 | \setbeamertemplate{title page}[min] 31 | \maketitle 32 | 33 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/step2bl.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme[blue,light]{sjtubeamer} 3 | \begin{document} 4 | 5 | \title[SJTU Beamer Template] % 页脚显示标题 6 | {\textbf{上海交通大学 Beamer 模版}} % 首页标题 7 | 8 | \author[Anxue Chen, Alexara Wu, Log Creative] 9 | {Anxue Chen, Alexara Wu, Log Creative} 10 | 11 | \institute[SJTU]{Shanghai Jiao Tong University} 12 | 13 | \date{\today} 14 | 15 | \subtitle{blue,light,maxplus} 16 | \logo{\resizebox{!}{0.7cm}{\zhlogo}} 17 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 18 | \setbeamertemplate{title page}[maxplus] 19 | \maketitle 20 | 21 | \subtitle{blue,light,max} 22 | \logo{\resizebox{!}{1cm}{\sjtubadge}} 23 | \titlegraphic{\sjtubg[opacity=0.2]} 24 | \setbeamertemplate{title page}[max] 25 | \maketitle 26 | 27 | \subtitle{blue,light,min} 28 | \logo{\resizebox{!}{0.7cm}{\enlogo}} 29 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 30 | \setbeamertemplate{title page}[min] 31 | \maketitle 32 | 33 | \end{document} -------------------------------------------------------------------------------- /src/support/beamerthemenosjtubeamer.sty: -------------------------------------------------------------------------------- 1 | %% If you don't use SJTUBeamer theme, 2 | %% Use this theme and redirect the macros to dummy ones. 3 | %% What's more, you need to use XeLaTeX to compile. 4 | 5 | \usepackage{listingsutf8} 6 | \lstset{columns=flexible} 7 | \lstnewenvironment{codeblock}[2][]{\lstset{title=#2,#1}}{} 8 | \newcommand<>{\highlightline}{} 9 | \newcommand{\highlight}[2][]{\alert{#2}} 10 | \newcommand{\paragraph}[1]{\bfseries #1\hspace{.5em}} 11 | \usepackage{tikz} 12 | \newcommand{\stamptext}[1][red]{#1} 13 | \newenvironment{stampbox}[1][]{}{} 14 | \newcommand{\makebottom}{ 15 | \begin{frame} 16 | \begin{center} 17 | \Huge 18 | Thank You! 19 | \end{center} 20 | \end{frame} 21 | } 22 | \newcommand{\stamparray}[3]{} 23 | \newenvironment{bibliolist}[1]{\begin{thebibliography}{#1}}{\end{thebibliography}} 24 | \newcommand{\articleitem}{\item} 25 | \newcommand{\bookitem}{\item} 26 | \newcommand{\onlineitem}{\item} 27 | \newenvironment{shadedsection}{}{} -------------------------------------------------------------------------------- /latexindent.yaml: -------------------------------------------------------------------------------- 1 | # This is the configuration used by latexindent.pl 2 | defaultIndent: " " 3 | 4 | # codeblock is defined by sjtubeamer for code typesetting. 5 | # codeblockminted is defined by minted plugin. 6 | verbatimEnvironments: 7 | codeblock: 1 8 | codeblockminted: 1 9 | 10 | # In case that the indent for the command. 11 | verbatimCommands: 12 | url: 1 13 | link: 1 14 | href: 1 15 | 16 | # Apply to -m option 17 | # Chinese docs are restricted to 50 characters first. 18 | modifyLineBreaks: 19 | textWrapOptions: 20 | columns: 80 21 | 22 | # Apply to -r option 23 | # First remove the additional new line before \url, \link, \href. 24 | # Then remove the new line in the url. 25 | replacements: 26 | - 27 | substitution: s/\n+(\h*)\\(url|link|href)\{/\n$1\\$2\{/g 28 | when: after 29 | - 30 | substitution: s/\\(url|link|href)\{([^\}]*)\n\s*([^\}]*)\}/\\$1\{$2$3\}/g 31 | when: after 32 | 33 | # Don't generate too many backups. 34 | onlyOneBackUp: 1 35 | 36 | # Convert CRLF to LF. 37 | dos2unixlinebreaks: 1 38 | -------------------------------------------------------------------------------- /src/support/sjtubeamerthemenewcontrib.template.ltx: -------------------------------------------------------------------------------- 1 | %% ------------------------------------------------------------------------ 2 | %% Copyright (C) 3 | %% 4 | %% Licensed under the Apache License, Version 2.0 (the "License"); 5 | %% you may not use this file except in compliance with the License. 6 | %% You may obtain a copy of the License at 7 | %% 8 | %% http://www.apache.org/licenses/LICENSE-2.0 9 | %% 10 | %% Unless required by applicable law or agreed to in writing, software 11 | %% distributed under the License is distributed on an "AS IS" BASIS, 12 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | %% See the License for the specific language governing permissions and 14 | %% limitations under the License. 15 | %% ------------------------------------------------------------------------ 16 | % 文件元数据 17 | \ProvidesFile{sjtubeamerthemenewcontrib.ltx}[0000/00/00 newcontrib for sjtubeamer] 18 | % 传入选项的处理 19 | \if\EqualOption{newcontrib}{debug}{true} 20 | \PackageInfo{You are debugging newcontrib} 21 | \fi -------------------------------------------------------------------------------- /src/support/tutorial/step20.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \usepackage{pgfplots} 4 | \usepackage{pgfplotstable} 5 | \begin{document} 6 | \begin{frame} 7 | \frametitle{统计图} 8 | \begin{figure} 9 | \begin{tikzpicture} 10 | \begin{axis}[ 11 | xlabel={$n$}, ylabel={Average Steps}, ymin={0}, xmax={9}, 12 | xmin={1}, legend style={at={(0.5,1.05)}, anchor=south}, 13 | legend columns=2, grid, minor tick num=1] 14 | \pgfplotstableread 15 | {test.csv}{\foo}; 16 | \addplot+ [only marks, mark options={scale=0.8}] table [y=Quick] {\foo}; 17 | \addplot+ [only marks, mark options={scale=0.8}] table [y=Cocktail] 18 | {\foo}; 19 | \pgfplotsset{cycle list shift=-2}; 20 | \addplot+ [no markers, domain=1:9,] {1.502*x*ln(x)}; 21 | \addplot+ [no markers, domain=1:9,] {0.4453*x*x-0.1365*x-0.473}; 22 | \legend{Quick,Cocktail} 23 | \end{axis} 24 | \end{tikzpicture} 25 | \caption{统计图标题} 26 | \end{figure} 27 | \end{frame} 28 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/reference.bib: -------------------------------------------------------------------------------- 1 | % Encoding: UTF-8 2 | @Manual{beamerman, 3 | title = {The beamer class: User Guide for version 3.59.}, 4 | author = {Tantau, Till and Wright, Joseph and Mileti\'c, Vedran}, 5 | month = jul, 6 | year = {2020}, 7 | url = {https://github.com/josephwright/beamer}, 8 | } 9 | 10 | @Manual{pgfplotstableman, 11 | title = {{Manual for Package PgfplotsTable: Component of pgfplots, Version 1.17}}, 12 | author = {{Dr. Christian Feuers\"anger}}, 13 | month = feb, 14 | year = {2020}, 15 | url = {http://sourceforge.net/projects/pgfplots}, 16 | } 17 | 18 | @Manual{pgfplotsman, 19 | title = {{Manual for Package pgfplots: 2D/3D Plots in \LaTeX{}, Version 1.17}}, 20 | author = {{Dr. Christian Feuers\"anger}}, 21 | month = feb, 22 | year = {2020}, 23 | url = {http://sourceforge.net/projects/pgfplots}, 24 | } 25 | 26 | @Manual{viman, 27 | title = {上海交通大学视觉形象识别系统使用手册}, 28 | author = {上海交通大学}, 29 | month = apr, 30 | year = {2016}, 31 | groups = {SJ-Team}, 32 | url = {https://vi.sjtu.edu.cn/}, 33 | } 34 | 35 | @Comment{jabref-meta: databaseType:bibtex;} -------------------------------------------------------------------------------- /src/support/tutorial/step2tb.tex: -------------------------------------------------------------------------------- 1 | \documentclass[]{ctexbeamer} 2 | \usetheme[]{sjtubeamer} 3 | \begin{document} 4 | 5 | \title[SJTU Beamer Template] % 页脚显示标题 6 | {\textbf{上海交通大学 Beamer 模版}} % 首页标题 7 | 8 | \author[Anxue Chen, Alexara Wu, Log Creative] 9 | {Anxue Chen, Alexara Wu, Log Creative} 10 | 11 | \institute[SJTU]{Shanghai Jiao Tong University} 12 | 13 | \date{\today} 14 | 15 | \subtitle{red,dark,maxplus} 16 | \logo{\resizebox{!}{0.7cm}{\zhlogo}} 17 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 18 | \setbeamertemplate{title page}[maxplus] 19 | \maketitle 20 | \setbeamertemplate{bottom page}[maxplus] 21 | \makebottom 22 | 23 | \subtitle{red,dark,max} 24 | \logo{\resizebox{!}{1cm}{\sjtubadge}} 25 | \titlegraphic{\sjtubg[opacity=0.2]} 26 | \setbeamertemplate{title page}[max] 27 | \maketitle 28 | \setbeamertemplate{bottom page}[max] 29 | \makebottom 30 | 31 | \subtitle{red,dark,min} 32 | \logo{\resizebox{!}{0.7cm}{\enlogo}} 33 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 34 | \setbeamertemplate{title page}[min] 35 | \maketitle 36 | \setbeamertemplate{bottom page}[min] 37 | \makebottom 38 | 39 | \end{document} -------------------------------------------------------------------------------- /contrib/minted/minted.tex: -------------------------------------------------------------------------------- 1 | \documentclass[aspectratio=169]{ctexbeamer} 2 | \usetheme{sjtubeamer} % 不必使用 my 选项 3 | \usesjtutheme{minted} % 引入本插件,可以添加 draft 选项 4 | \begin{document} 5 | \begin{frame}[fragile] % frame 添加 fragile 选项 6 | \frametitle{minted 插件} 7 | 需要正确安装 \texttt{minted} 宏包,并在编译文件时使用 \texttt{-shell-escape} 8 | 标志。\texttt{sjtubeamer} 前不必使用 \texttt{my} 选项。 9 | \codeblockinputminted[firstline=5,lastline=9]{外部输入示例}{latex}{minted.tex} 10 | \end{frame} 11 | \begin{frame}[fragile] 12 | 你可以通过临时添加 \texttt{draft} 选项来减少编译时间。 13 | \codeblockinputminted[firstline=2, lastline=3]{}{latex}{minted.tex} 14 | 不仅可以使用 \texttt{\textbackslash{}codeblockinputminted} 用于抄录外部文件,还可以使用 15 | \texttt{codeblockminted} 环境使用 \texttt{minted} 引擎抄录文件内代码。 16 | \codeblockinputminted[firstline=16, lastline=18]{codeblockminted 17 | 环境(部分)}{latex}{minted.tex} 18 | \end{frame} 19 | \begin{frame}[fragile] % fragile 20 | \begin{codeblockminted}[]{C++ 代码}{cpp} 21 | #include 22 | 23 | int main(){ 24 | // Console Output 25 | std::cout << "Hello, SJTU!" << std::endl; 26 | return 0; 27 | } 28 | \end{codeblockminted} 29 | \end{frame} 30 | \end{document} -------------------------------------------------------------------------------- /src/support/tutorial/stepalgo.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[min]{sjtubeamer} 3 | \usepackage[ruled, linesnumbered]{algorithm2e} 4 | \begin{document} 5 | \begin{frame} 6 | \scalebox{0.5}{ 7 | \begin{algorithm}[H] 8 | \caption{A* 多序列比对}\label{alg:astar} 9 | \KwIn{$L$个字符串列表$S$,$\alpha$,$\delta$} 10 | \KwOut{minimum cost} 11 | \BlankLine 12 | $dist[\cdot]\leftarrow\infty$\; 13 | $move[\cdot]\leftarrow 0$\; 14 | $dist[start]\leftarrow 0$\; 15 | $move[start]\leftarrow 0$\; 16 | $openSet\leftarrow\textsc{Min-Heap}()$\; 17 | $openSet[start]=h(start)$\; 18 | $closeSet\leftarrow \{\}$\; 19 | \Repeat{$openSet$ is empty}{ 20 | $current\leftarrow openSet$.pop()\; 21 | \If{$current$=$finish$}{ 22 | \Return{$dist[current]$}\; 23 | } 24 | 25 | $closeSet$.add($current$)\; 26 | \ForEach{available move of $current$}{ 27 | $n\leftarrow$\texttt{pos}$+$\emph{available move}\; 28 | $g=dist(\mathit{current})+cost(\text{\emph{available move}})$\; 29 | \If{$g]{sjtubeamer} 5 | \begin{document} 6 | 7 | \title[SJTU Beamer Template] % 页脚显示标题 8 | {\textbf{上海交通大学 Beamer 模版}} % 首页标题 9 | 10 | \author[Anxue Chen, Alexara Wu, Log Creative] 11 | {Anxue Chen, Alexara Wu, Log Creative} 12 | 13 | \institute[SJTU]{Shanghai Jiao Tong University} 14 | 15 | \date{\today} 16 | 17 | \subtitle{,maxplus} 18 | \logo{\resizebox{!}{0.7cm}{\zhlogo}} 19 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 20 | \setbeamertemplate{background}{} 21 | \setbeamertemplate{title page}[maxplus] 22 | \maketitle 23 | \setbeamertemplate{part page}[maxplus] 24 | \part{,maxplus} 25 | \section{饮水思源} 26 | \section{爱国荣校} 27 | \setbeamertemplate{bottom page}[maxplus] 28 | \makebottom 29 | 30 | \subtitle{,min} 31 | \logo{\resizebox{!}{0.7cm}{\enlogo}} 32 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 33 | \setbeamertemplate{background}{} 34 | \setbeamertemplate{title page}[min] 35 | \maketitle 36 | \setbeamertemplate{part page}[min] 37 | \part{,min} 38 | \section{饮水思源} 39 | \section{爱国荣校} 40 | \setbeamertemplate{bottom page}[min] 41 | \makebottom 42 | 43 | \subtitle{,max} 44 | \logo{\resizebox{!}{1cm}{\sjtubadge}} 45 | \titlegraphic{\sjtubg[opacity=0.2]} 46 | \setbeamertemplate{background} 47 | {\bgcenterbox{\sjtubg[cprimary!50,opacity=0.2]}} 48 | \setbeamertemplate{title page}[max] 49 | \maketitle 50 | \setbeamertemplate{part page}[max] 51 | \part{,max} 52 | \section{饮水思源} 53 | \section{爱国荣校} 54 | \setbeamertemplate{bottom page}[max] 55 | \makebottom 56 | 57 | \end{document} -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # ---------------- 2 | # User commands 3 | # ---------------- 4 | 5 | LATEXINDENT_ARGS=-l latexindent.yaml -c build -m -r 6 | LATEXMK_ARGS=-halt-on-error -time -xelatex -outdir=build -shell-escape 7 | 8 | all: build 9 | 10 | prepare: 11 | mkdir -p build 12 | mkdir -p build/contents 13 | 14 | # Build latex files in root directory 15 | build: prepare 16 | latexmk main.tex $(LATEXMK_ARGS) 17 | cp build/main.pdf . 18 | 19 | # Format tex files in root directory 20 | format: 21 | latexindent main.tex -l latexindent.yaml -w $(LATEXINDENT_ARGS) 22 | 23 | # Install the package to TeX Live / MacTeX 24 | # For MiKTeX users, if you encounter `please use --texmfhome option`, 25 | # I wish you could do the job manually by using 26 | # `l3build install --texmfhome path/to/install`. 27 | # For more details, see the development guide. 28 | install: 29 | cd src && l3build install 30 | 31 | # Clean temporary files 32 | clean: 33 | latexmk -C $(LATEXMK_ARGS) 34 | 35 | # ---------------- 36 | # Developer commands 37 | # ---------------- 38 | 39 | # Format all tex and dtx files 40 | format-dev: 41 | .github/ci/format.sh $(LATEXINDENT_ARGS) 42 | 43 | # Clean all temporary files and generated files 44 | clean-dev: 45 | latexmk -C 46 | cd src && l3build clean 47 | git clean -dfX 48 | 49 | # Build all covers to `cover.pdf` 50 | build-cover: prepare 51 | .github/ci/gen_cover.sh $(LATEXMK_ARGS) 52 | cp build/cover.pdf . 53 | 54 | # Build sjtubeamer package 55 | # This will build online package automatically. 56 | build-dev: prepare 57 | .github/ci/build_package.sh 58 | 59 | # Build online distribution 60 | build-online: prepare 61 | .github/ci/build_online.sh 62 | 63 | # Build `main.tex` with multiple test variants 64 | build-test-variants: prepare 65 | .github/ci/build_test_variants.sh $(LATEXMK_ARGS) 66 | cp build/build-*.pdf . 67 | 68 | # Build `main.tex` with multiple release variants 69 | build-all-variants: prepare 70 | .github/ci/build_all_variants.sh $(LATEXMK_ARGS) 71 | cp build/build-*.pdf . 72 | 73 | # Generate `.sty` files and copy resources 74 | generate: 75 | (cd src/source && latex beamerthemesjtubeamer.ins && mv *.sty ../..) 76 | .github/ci/copy_resources.sh 77 | 78 | .PHONY: build format clean 79 | -------------------------------------------------------------------------------- /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # 向 SJTUBeamer 贡献插件 2 | 3 | SJTUBeamer 现在已经开放插件接口,存放于根目录的 `contrib/` 文件夹中。如果您实现了自己的主题模板,或者是基于 SJTUBeamer API 的插件,可以考虑通过下面的步骤向本存储库发 PR: 4 | 1. fork 仓库,克隆自己的仓库到本地。 5 | 2. 向你的电脑安装当前版本的 SJTUBeamer,`cd src && l3build install`,在 TeX 发布版中刷新文件名数据库,便于插件文档的编写。 6 | 3. 使用 `l3build add-contrib ` 命令在 `contrib` 文件夹中新建一个插件文件夹 ``,在文件夹中至少应该有下面两个文件: 7 | - 插件入口 `contrib//sjtubeamertheme.ltx` 8 | - 插件文档 `contrib//.tex` 9 | 4. 如果在插件中需要使用相对于该插件目录的文件,请使用下面的 API: 10 | - `\getcontribdir{}` 返回插件目录 `contrib/` 11 | - `\getcontribpath{}{}` 返回插件文件 `contrib//` 12 | 5. 发 PR 时,使用 `contrib: ` 作为标题,并向维护者发出代码审查请求。 13 | 6. 之后在根目录的主文件中就可以在 `\usetheme{sjtubeamer}`(如果是子主题需要指定 `my` 参数)后使用 `\usesjtutheme{}` 调用你的插件。 14 | 15 | 更多信息,请参阅开发文档。 16 | 17 | ----- 18 | 19 | # Contribute to SJTUBeamer 20 | 21 | SJTUBeamer is available for receiving plugins, which are stored in `contrib/` folder. If you want to contribute your own theme template or plugin based on SJTUBeamer API, you could make a pull request to this repo by the following steps: 22 | 1. Fork this repository and clone your own version to the machine. 23 | 2. Install the current version of `SJTUBeamer` to your computer for the convenience of writing documentation. 24 | `cd src && l3build install`, then refresh the database of filenames in your TeX distribution. 25 | 3. Use command `l3build add-contrib `. Create a new plugin folder `` in `contrib`. At least two files should be implemented in the folder: 26 | - Plugin entry point. `contrib//sjtubeamertheme.ltx` 27 | - Plugin documentation. `contrib//.tex` 28 | 4. If you want to use the file in your plugin directory, use the following API: 29 | - `\getcontribdir{}` returns the plugin directory `contrib/` 30 | - `\getcontribpath{}{}` returns plugin file path `contrib//` 31 | 5. Pull request to this repo naming `contrib: `, request a review from one of the collaborators. 32 | 6. Now, you could call your plugin by using `\usesjtutheme{}` (specify `my` option if it is a sub-theme) after `\usetheme{sjtubeamer}`. 33 | 34 | For more information, please refer to the development guide. -------------------------------------------------------------------------------- /src/source/beamerfontthemesjtubeamer.dtx: -------------------------------------------------------------------------------- 1 | % \iffalse meta-comment -------------------------------------------------- 2 | % Copyright (C) 2021-2024 SJTUG 3 | % 4 | % Licensed under the Apache License, Version 2.0 (the "License"); 5 | % you may not use this file except in compliance with the License. 6 | % You may obtain a copy of the License at 7 | % 8 | % http://www.apache.org/licenses/LICENSE-2.0 9 | % 10 | % Unless required by applicable law or agreed to in writing, software 11 | % distributed under the License is distributed on an "AS IS" BASIS, 12 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | % See the License for the specific language governing permissions and 14 | % limitations under the License. 15 | % ------------------------------------------------------------------------ \fi 16 | % \iffalse 17 | %<*package> 18 | \NeedsTeXFormat{LaTeX2e} 19 | \ProvidesPackage{beamerfontthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer font theme] 20 | % 21 | % \fi 22 | % \CheckSum{0} 23 | % \StopEventually{} 24 | % \iffalse 25 | %<*package> 26 | % ------------------------------------------------------------------------ \fi 27 | % 28 | % \subsection{Font Theme} 29 | % 30 | % 31 | % Ignore unwanted warnings. 32 | % \begin{macrocode} 33 | \RequirePackage{silence} 34 | \WarningFilter{latexfont}{Font shape} 35 | % \end{macrocode} 36 | % 37 | % Use \verb"professionalfonts" font theme to compress all formula environments, 38 | % which is in serif font style. 39 | % \begin{macrocode} 40 | \usefonttheme{professionalfonts} 41 | % \end{macrocode} 42 | % 43 | % Use \verb"structurebold" font theme to make the title in bfseries. 44 | % \begin{macrocode} 45 | \usefonttheme{structurebold} 46 | % \end{macrocode} 47 | % 48 | % Set the font size to normal size for the number indication in part page, 49 | % section page, and subsection page. 50 | % \begin{macrocode} 51 | \setbeamerfont{part name}{size=\normalsize} 52 | \setbeamerfont{section name}{size=\normalsize} 53 | \setbeamerfont{subsection name}{size=\normalsize} 54 | % \end{macrocode} 55 | % 56 | % Set the font size in the footnote to footnotesize. 57 | % \begin{macrocode} 58 | \setbeamerfont{footnote}{size=\footnotesize} 59 | % \end{macrocode} 60 | % \iffalse 61 | % 62 | % \fi 63 | % \Finale 64 | \endinput 65 | -------------------------------------------------------------------------------- /src/testfiles/sjtuvi.lvt: -------------------------------------------------------------------------------- 1 | \input{regression-test.tex} 2 | \documentclass{beamer} 3 | \usepackage{sjtuvi} 4 | \def\colorblock#1{ 5 | #1\hfill\tikz{\draw[black,fill=#1] (-1,-0.25) rectangle (1,0.25);}\par 6 | } 7 | \begin{document} 8 | \START 9 | \begin{frame} 10 | \frametitle{Predefined color} 11 | \ttfamily 12 | \colorblock{sjtuRedPrimary} 13 | \colorblock{sjtuRedSecondary} 14 | \colorblock{sjtuRedTertiary} 15 | \colorblock{sjtuBluePrimary} 16 | \colorblock{sjtuBlueSecondary} 17 | \colorblock{sjtuBlueTertiary} 18 | \end{frame} 19 | \OMIT 20 | \setbeamertemplate{background}{ 21 | \sjtubg 22 | } 23 | \begin{frame} 24 | \frametitle{Logo Insertion} 25 | \zhlogo 26 | \enlogo 27 | \dlogo 28 | \vlogo 29 | \sjtubadge 30 | \end{frame} 31 | \setbeamertemplate{background}{} 32 | \TIMO 33 | \begin{frame} 34 | \frametitle{Stamp shapes} 35 | \begin{tikzpicture} 36 | \stamparray{4pt}{(-3,-3)}{(3,3)} 37 | \end{tikzpicture} 38 | \begin{tikzpicture} 39 | \draw[decoration={ 40 | stampline, 41 | segment length=8pt, 42 | path has corners=true, 43 | },decorate,sjtuRedPrimary] (-2,-2) rectangle (2,2); 44 | \end{tikzpicture} 45 | \stamptext{Test} 46 | \end{frame} 47 | \OMIT 48 | \begin{frame} 49 | \frametitle{Secondary Institute Logo} 50 | \secondaryinstlogo{Institute Line\\ Institute Line}{\phantom{-}} 51 | \secondaryinstlogo[Institute Line\\ Institute Line]{Institute Line\\ Institute Line}{\phantom{-}} 52 | \end{frame} 53 | \TIMO 54 | \begin{frame} 55 | \frametitle{Condition Tests} 56 | \TEST{EqualOption}{ 57 | \if\EqualOption{sjtuvi}{test}{true}\TRUE\else\FALSE\fi 58 | } 59 | \TEST{IsEmpty}{ 60 | \def\aaa{} 61 | \def\bbb{\aaa} 62 | \def\ccc{a\\b} 63 | \if\IsEmpty{\aaa}\TRUE\else\FALSE\fi 64 | \if\IsEmpty{\bbb}\TRUE\else\FALSE\fi 65 | \if\IsEmpty{ }\TRUE\else\FALSE\fi 66 | \if\IsEmpty{ \\ }\TRUE\else\FALSE\fi 67 | \if\IsEmpty{\\ }\TRUE\else\FALSE\fi 68 | \if\IsEmpty{\ccc}\TRUE\else\FALSE\fi 69 | } 70 | \end{frame} 71 | \END 72 | \end{document} -------------------------------------------------------------------------------- /contrib/minted/sjtubeamerthememinted.ltx: -------------------------------------------------------------------------------- 1 | %% ------------------------------------------------------------------------ 2 | %% Copyright (C) 2022 LogCreative 3 | %% 4 | %% Licensed under the Apache License, Version 2.0 (the "License"); 5 | %% you may not use this file except in compliance with the License. 6 | %% You may obtain a copy of the License at 7 | %% 8 | %% http://www.apache.org/licenses/LICENSE-2.0 9 | %% 10 | %% Unless required by applicable law or agreed to in writing, software 11 | %% distributed under the License is distributed on an "AS IS" BASIS, 12 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | %% See the License for the specific language governing permissions and 14 | %% limitations under the License. 15 | %% ------------------------------------------------------------------------ 16 | \ProvidesFile{sjtubeamerthememinted.ltx}[2022/05/07 Minted implementations for codeblock] 17 | \if\EqualOption{minted}{draft}{true} 18 | % minted 会导致编译变慢,启用 draft 将会使得 minted 只采用底层的 fancyvrb 宏包编译。 19 | % 可以在一定程度上解决超时问题。仍然推荐只使用 listings 编译。 20 | \PassOptionsToPackage{draft}{minted} 21 | \fi 22 | % 启用 minted 23 | \tcbuselibrary{minted} 24 | % 设定 minted 基础样式: 25 | % * 字号 小 26 | % * 高亮颜色 27 | % * 自动断行 28 | % * 自动缩进 29 | \setminted{ 30 | fontsize=\small, 31 | highlightcolor=structure!25, 32 | breaklines, 33 | autogobble 34 | } 35 | % 更改编号颜色 36 | \renewcommand{\theFancyVerbLine}{\ttfamily 37 | \textcolor{cprimary!80}{\scriptsize\arabic{FancyVerbLine}}} 38 | % 使用现有的高亮色彩主题,minted 自定义高亮颜色并不方便。 39 | \usemintedstyle{colorful} 40 | % 添加 codeblockminted 环境,用于使用 minted 引擎。 41 | % 用法: 42 | % \begin{codeblockminted}[minted 选项]{标题}{语言} 43 | % 44 | % \end{codeblockminted} 45 | \newtcblisting{codeblockminted}[3][]{ 46 | listing only, 47 | listing engine=minted, 48 | minted language=#3, 49 | minted options={ 50 | numbers=left, 51 | numbersep=5pt, 52 | #1, 53 | }, 54 | enhanced, 55 | sharp corners, 56 | top=0mm, 57 | bottom=0mm, 58 | right*=0.5mm, 59 | title=#2, 60 | colback=cprimary!5, 61 | colframe=cprimary!80, 62 | overlay={ 63 | \begin{tcbclipinterior}\fill[cprimary!20]% 64 | (frame.south west) rectangle ([xshift=5.5mm]frame.north west); 65 | \end{tcbclipinterior} 66 | } 67 | } 68 | % 添加 \codeblockinputminted 命令,用于从现有的文件中使用代码抄录。 69 | % 用法: 70 | % \codeblockinputminted[minted 选项]{标题}{语言}{文件} 71 | \newtcbinputlisting{\codeblockinputminted}[4][]{ 72 | listing engine=minted, 73 | listing file={#4}, 74 | title={#2}, 75 | minted language={#3}, 76 | minted options={ 77 | numbers=left, 78 | numbersep=5pt, 79 | #1, 80 | }, 81 | listing only, 82 | enhanced, 83 | sharp corners, 84 | top=0mm, 85 | bottom=0mm, 86 | right*=0.5mm, 87 | title=#2, 88 | colback=cprimary!5, 89 | colframe=cprimary!80, 90 | overlay={ 91 | \begin{tcbclipinterior}\fill[cprimary!20]% 92 | (frame.south west) rectangle ([xshift=5.5mm]frame.north west); 93 | \end{tcbclipinterior} 94 | } 95 | } 96 | % 97 | % 注意使用该插件时, 98 | % 需要正确安装 minted 与 python Pygments, 99 | % 并在编译时启用 -shell-escape 选项。 100 | -------------------------------------------------------------------------------- /contrib/sjtug/sjtubeamerthemesjtug.ltx: -------------------------------------------------------------------------------- 1 | %% ------------------------------------------------------------------------ 2 | %% Copyright (C) 2022 LogCreative 3 | %% 4 | %% Licensed under the Apache License, Version 2.0 (the "License"); 5 | %% you may not use this file except in compliance with the License. 6 | %% You may obtain a copy of the License at 7 | %% 8 | %% http://www.apache.org/licenses/LICENSE-2.0 9 | %% 10 | %% Unless required by applicable law or agreed to in writing, software 11 | %% distributed under the License is distributed on an "AS IS" BASIS, 12 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | %% See the License for the specific language governing permissions and 14 | %% limitations under the License. 15 | %% ------------------------------------------------------------------------ 16 | % 设置文件元数据 17 | \ProvidesFile{sjtubeamerthemesjtug.ltx}[2022/05/07 SJTUG subtheme for SJTUBeamer] 18 | % 设置组织名称 19 | \institute[SJTU Linux User Group]{上海交通大学 Linux 用户组} 20 | % 设置徽标 21 | \logo{\resizebox{1cm}{!}{\includegraphics{\getcontribpath{sjtug}{vi/sjtug.pdf}}}} 22 | % 设置头图 23 | \titlegraphic{\includegraphics{vi/sjtu-vi-sjtuphoto.jpg}} 24 | % 设定主色 25 | \definecolor{cprimary}{RGB}{225,111,11} 26 | % 定义自定可变色 logo 27 | \definelogo{sjtugtext}{\getcontribpath{sjtug}{vi/sjtugtext.pdf}}{0}{0.8} 28 | % 设置背景为 SJTUG 文字 29 | \setbeamertemplate{background}{ 30 | \bgcenterbox{ 31 | \sjtugtext[cprimary, opacity=0.1] 32 | } 33 | } 34 | % 判断传递的选项 35 | \if\EqualOption{sjtug}{debug}{true} 36 | \PackageWarning{sjtug}{ 37 | You are debugging \CurrentFilePath/\CurrentFile. \MessageBreak 38 | Use lualatex compilation to see the visual reference line 39 | } 40 | \usepackage{lua-visual-debug} 41 | \fi 42 | % 制作自定标题页 43 | \defbeamertemplate*{title page}{sjtug}[1][]{ 44 | \vbox{} 45 | \usebeamercolor{palette primary} 46 | \begin{tikzpicture}[overlay] 47 | \fill [palette primary.bg] (-0.2*\the\paperwidth,-1*\the\paperheight) 48 | rectangle (1*\the\paperwidth, 0.3*\the\paperheight); 49 | \end{tikzpicture} 50 | \vfill 51 | \color{palette primary.fg} 52 | \hbox to \textwidth{ 53 | \hfil 54 | \vbox to 3.5cm{ 55 | \vskip3pt 56 | \hbox{\resizebox{2.5cm}{!}{\insertlogo}} 57 | \hbox{\hfill\,\,\sjtugtext[palette primary.fg]\,\hfill} 58 | \vfill 59 | } 60 | \hfil 61 | \vbox to 3.5cm{ 62 | \vfill 63 | \hbox{\LARGE\bfseries\inserttitle} 64 | \vskip4pt 65 | \hbox{\large\insertsubtitle} 66 | \vskip2pt 67 | \hbox{\scriptsize\insertauthor} 68 | \hbox{\scriptsize\insertdate} 69 | \vfill 70 | } 71 | \hskip20pt 72 | \hfil 73 | } 74 | \vfill 75 | } 76 | % 设置结束页 77 | \setbeamertemplate{bottom page}[min] 78 | % 设置部分页、节页和小节页 79 | \setbeamertemplate{sectioning pages}[min] 80 | % 当然也可以分别设置: 81 | % \setbeamertemplate{part page}[min] 82 | % \setbeamertemplate{section page}[min] 83 | % \setbeamertemplate{subsection page}[min] 84 | 85 | % 下面不属于常规操作,会导致徽标不可更改, 86 | % 不使用时请注释掉 87 | % 88 | % 更改徽标为含有当前章节名称 89 | \xdef\oldlogo{\expandbeamertemplate{logo}} 90 | \logo{\insertpart\oldlogo} 91 | % 重定义标题页命令以局部使用老徽标定义 92 | \let\oldmaketitle=\maketitle 93 | \def\maketitle{ 94 | { 95 | \logo{\oldlogo} 96 | \oldmaketitle 97 | } 98 | } 99 | % 重定义结尾页命令以局部使用老徽标定义 100 | \let\oldmakebottom=\makebottom 101 | \def\makebottom{ 102 | { 103 | \logo{\oldlogo} 104 | \oldmakebottom 105 | } 106 | } 107 | % 新的数字节标题环境 108 | \newenvironment{shadedsection}{ 109 | \newcommand{\shadedfont}[2][1pt]{ 110 | % ##1 (optional): shadow distance 111 | % ##2: the text needed to be shaded 112 | \hbox{\rlap{\color{gray}\hskip##1##2}##2} 113 | } 114 | \setcounter{section}{-1} 115 | \newcommand{\updatelogo}{ 116 | \logo{ 117 | \raise.3ex\hbox{\tiny\insertsection}\shadedfont{\arabic{section}} 118 | } 119 | } 120 | \let\oldsection=\section 121 | \renewcommand{\section}[1]{\oldsection{##1}\updatelogo} 122 | }{} 123 | -------------------------------------------------------------------------------- /beamercolorthemesjtubeamer.sty: -------------------------------------------------------------------------------- 1 | %% 2 | %% This is file `beamercolorthemesjtubeamer.sty', 3 | %% generated with the docstrip utility. 4 | %% 5 | %% The original source files were: 6 | %% 7 | %% beamercolorthemesjtubeamer.dtx (with options: `package') 8 | %% ------------------------------------------------------------------------ 9 | %% Copyright (C) 2021-2024 SJTUG 10 | %% 11 | %% Licensed under the Apache License, Version 2.0 (the "License"); 12 | %% you may not use this file except in compliance with the License. 13 | %% You may obtain a copy of the License at 14 | %% 15 | %% http://www.apache.org/licenses/LICENSE-2.0 16 | %% 17 | %% Unless required by applicable law or agreed to in writing, software 18 | %% distributed under the License is distributed on an "AS IS" BASIS, 19 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | %% See the License for the specific language governing permissions and 21 | %% limitations under the License. 22 | %% ------------------------------------------------------------------------ 23 | \NeedsTeXFormat{LaTeX2e} 24 | \ProvidesPackage{beamercolorthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer color theme] 25 | \RequirePackage{sjtuvi} 26 | \DefineOption{color}{color}{red} 27 | \DefineOption{color}{color}{blue} 28 | \ExecuteOptionsBeamer{red} 29 | \DefineOption{color}{lum}{light} 30 | \DefineOption{color}{lum}{dark} 31 | \ExecuteOptionsBeamer{dark} 32 | \ProcessOptionsBeamer 33 | \if\EqualOption{color}{color}{red} 34 | \colorlet{cprimary}{sjtuRedPrimary} 35 | \colorlet{csecondary}{sjtuRedSecondary} 36 | \colorlet{ctertiary}{sjtuRedTertiary} 37 | \colorlet{cquanternary}{black} 38 | \else 39 | \colorlet{cprimary}{sjtuBluePrimary} 40 | \colorlet{csecondary}{sjtuBlueSecondary} 41 | \colorlet{ctertiary}{sjtuBlueTertiary} 42 | \colorlet{cquanternary}{white} 43 | \fi 44 | \setbeamercolor{structure}{fg=cprimary} 45 | \if\EqualOption{color}{lum}{light} 46 | \setbeamercolor{palette primary}{bg=white,fg=cprimary} 47 | \setbeamercolor{palette secondary}{bg=white,fg=cprimary!50!csecondary} 48 | \setbeamercolor{palette tertiary}{bg=white,fg=csecondary} 49 | \else 50 | \setbeamercolor{palette primary}{bg=cprimary,fg=white} 51 | \setbeamercolor{palette secondary}{bg=cprimary!50!csecondary,fg=white} 52 | \setbeamercolor{palette tertiary}{bg=csecondary,fg=white} 53 | \fi 54 | \setbeamercolor{background canvas}{bg=white} 55 | \setbeamercolor{normal text}{fg=black,bg=black!40} 56 | \setbeamercolor*{block title}{parent=structure} 57 | \setbeamercolor{titlelike}{bg=,fg=cprimary} 58 | \setbeamercolor{title}{use={palette primary},fg=palette primary.fg,bg=} 59 | \setbeamercolor{subtitle}{use={palette secondary},fg=palette secondary.fg,bg=} 60 | \setbeamercolor{author}{use={palette primary},bg=,fg=palette primary.fg} 61 | \setbeamercolor{institute}{parent=author} 62 | \setbeamercolor{date}{parent=author} 63 | \setbeamercolor{logo}{bg=,fg=cprimary} 64 | \setbeamercolor{block title}{fg=white,bg=cprimary!90} 65 | \setbeamercolor{block title alerted}{use=alerted text, 66 | fg=white,bg=csecondary} 67 | \setbeamercolor{block title example}{use=example text, 68 | fg=cquanternary,bg=ctertiary} 69 | \setbeamercolor{block body}{parent=normal text,use=block title, 70 | bg=block title.bg!15} 71 | \setbeamercolor{block body alerted}{parent=normal text, 72 | use=block title alerted,bg=block title alerted.bg!15} 73 | \setbeamercolor{block body example}{parent=normal text, 74 | use=block title example,bg=block title example.bg!15} 75 | \setbeamercolor{block body stamp}{bg=} 76 | \setbeamercolor{footnote}{fg=cprimary,bg=} 77 | \setbeamercolor{part title}{parent={palette primary}} 78 | \setbeamercolor{section title}{parent={palette secondary}} 79 | \setbeamercolor{subsection title}{parent={palette tertiary}} 80 | \setbeamercolor{section in head/foot}{fg=white,bg=cprimary} 81 | \setbeamercolor{subsection in head/foot}{fg=cprimary,bg=cprimary!20} 82 | \setbeamercolor{institute in head/foot}{fg=white,bg=} 83 | \setbeamercolor{page number in head/foot}{fg=white,bg=} 84 | \setbeamercolor{frametitle}{use=titlelike,bg=white,fg=titlelike.fg} 85 | \setbeamercolor{frametitle right}{parent=subsection in head/foot} 86 | \setbeamercolor{alerted text}{fg=cprimary} 87 | \endinput 88 | %% 89 | %% End of file `beamercolorthemesjtubeamer.sty'. 90 | -------------------------------------------------------------------------------- /beamerthemesjtubeamer.sty: -------------------------------------------------------------------------------- 1 | %% 2 | %% This is file `beamerthemesjtubeamer.sty', 3 | %% generated with the docstrip utility. 4 | %% 5 | %% The original source files were: 6 | %% 7 | %% beamerthemesjtubeamer.dtx (with options: `package,maxplus,max,min,my') 8 | %% ------------------------------------------------------------------------ 9 | %% Copyright (C) 2021-2024 SJTUG 10 | %% 11 | %% Licensed under the Apache License, Version 2.0 (the "License"); 12 | %% you may not use this file except in compliance with the License. 13 | %% You may obtain a copy of the License at 14 | %% 15 | %% http://www.apache.org/licenses/LICENSE-2.0 16 | %% 17 | %% Unless required by applicable law or agreed to in writing, software 18 | %% distributed under the License is distributed on an "AS IS" BASIS, 19 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | %% See the License for the specific language governing permissions and 21 | %% limitations under the License. 22 | %% ------------------------------------------------------------------------ 23 | \NeedsTeXFormat{LaTeX2e} 24 | \ProvidesPackage{beamerthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer parent theme] 25 | \DeclareOptionBeamer{maxplus}{ 26 | \def\sjtubeamer@cover{maxplus}\def\sjtubeamer@logopos{topright}} 27 | \DeclareOptionBeamer{max}{ 28 | \def\sjtubeamer@cover{max}\def\sjtubeamer@logopos{bottomright}} 29 | \DeclareOptionBeamer{min}{ 30 | \def\sjtubeamer@cover{min}\def\sjtubeamer@logopos{topright}} 31 | \DeclareOptionBeamer{my}{ 32 | \def\sjtubeamer@cover{my}\def\sjtubeamer@logopos{bottomright}} 33 | % reserved for customization 34 | \ExecuteOptionsBeamer{ 35 | maxplus, 36 | min, 37 | my, 38 | max, 39 | } 40 | \DeclareOptionBeamer{red}{\def\sjtubeamer@color{red}} 41 | \DeclareOptionBeamer{blue}{\def\sjtubeamer@color{blue}} 42 | \ExecuteOptionsBeamer{red} 43 | \DeclareOptionBeamer{light}{\def\sjtubeamer@lum{light}} 44 | \DeclareOptionBeamer{dark}{\def\sjtubeamer@lum{dark}} 45 | \ExecuteOptionsBeamer{dark} 46 | \DeclareOptionBeamer{zh}{\def\sjtubeamer@lang{zh}} 47 | \DeclareOptionBeamer{en}{\def\sjtubeamer@lang{en}} 48 | \@ifclassloaded{ctexbeamer}{\ExecuteOptionsBeamer{zh}}{ 49 | \ExecuteOptionsBeamer{en}} 50 | \DeclareOptionBeamer{miniframes}{\def\sjtubeamer@nav{miniframes}} 51 | \DeclareOptionBeamer{infolines}{\def\sjtubeamer@nav{infolines}} 52 | \DeclareOptionBeamer{sidebar}{\def\sjtubeamer@nav{sidebar}} 53 | \DeclareOptionBeamer{default}{\def\sjtubeamer@nav{default}} 54 | \DeclareOptionBeamer{smoothbars}{\def\sjtubeamer@nav{smoothbars}} 55 | \DeclareOptionBeamer{split}{\def\sjtubeamer@nav{split}} 56 | \DeclareOptionBeamer{shadow}{\def\sjtubeamer@nav{shadow}} 57 | \DeclareOptionBeamer{tree}{\def\sjtubeamer@nav{tree}} 58 | \DeclareOptionBeamer{smoothtree}{\def\sjtubeamer@nav{smoothtree}} 59 | \ExecuteOptionsBeamer{miniframes} 60 | \DeclareOptionBeamer{topright}{\def\sjtubeamer@logopos{topright}} 61 | \DeclareOptionBeamer{bottomright}{\def\sjtubeamer@logopos{bottomright}} 62 | \ProcessOptionsBeamer 63 | \PassOptionsToPackage{\sjtubeamer@cover}{beamerinnerthemesjtubeamer} 64 | \PassOptionsToPackage{\sjtubeamer@color}{beamercolorthemesjtubeamer} 65 | \PassOptionsToPackage{\sjtubeamer@color}{beamerinnerthemesjtubeamer} 66 | \PassOptionsToPackage{\sjtubeamer@lum}{beamercolorthemesjtubeamer} 67 | \PassOptionsToPackage{\sjtubeamer@lang}{beamerinnerthemesjtubeamer} 68 | \PassOptionsToPackage{\sjtubeamer@nav}{beamerouterthemesjtubeamer} 69 | \PassOptionsToPackage{\sjtubeamer@logopos}{beamerouterthemesjtubeamer} 70 | \mode 71 | \usecolortheme{sjtubeamer} 72 | \usefonttheme{sjtubeamer} 73 | \useinnertheme{sjtubeamer} 74 | \useoutertheme{sjtubeamer} 75 | \newrobustcmd*\usesjtutheme[2][]{ 76 | \def\sjtubeamer@mythemeoptions{#1} 77 | \def\sjtubeamer@mythemelist{#2} 78 | \@for\sjtubeamer@mythemename:=\sjtubeamer@mythemelist\do{ 79 | \@for\sjtubeamer@mythemeoption:=\sjtubeamer@mythemeoptions\do{ 80 | \expandafter\def\csname sjtubeamer@\sjtubeamer@mythemename 81 | @\sjtubeamer@mythemeoption\endcsname{true} 82 | } 83 | \def\sjtubeamer@mythemefile{sjtubeamertheme\sjtubeamer@mythemename.ltx} 84 | \IfFileExists{\sjtubeamer@mythemefile}{ 85 | \PackageWarning{\sjtubeamer@mythemename}{ 86 | Local ltx file is found. For documentation use only. \MessageBreak 87 | Move to \getcontribdir{\sjtubeamer@mythemename} for release. 88 | Unexpected error in other ltx may occur} 89 | \renewcommand{\getcontribdir}[1]{.} 90 | }{} 91 | \input{\getcontribpath{\sjtubeamer@mythemename}{\sjtubeamer@mythemefile}} 92 | } 93 | } 94 | \endinput 95 | %% 96 | %% End of file `beamerthemesjtubeamer.sty'. 97 | -------------------------------------------------------------------------------- /src/source/beamerthemesjtubeamer.ins: -------------------------------------------------------------------------------- 1 | %% ------------------------------------------------------------------------ 2 | %% Copyright (C) 2021-2024 SJTUG 3 | %% 4 | %% Licensed under the Apache License, Version 2.0 (the "License"); 5 | %% you may not use this file except in compliance with the License. 6 | %% You may obtain a copy of the License at 7 | %% 8 | %% http://www.apache.org/licenses/LICENSE-2.0 9 | %% 10 | %% Unless required by applicable law or agreed to in writing, software 11 | %% distributed under the License is distributed on an "AS IS" BASIS, 12 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | %% See the License for the specific language governing permissions and 14 | %% limitations under the License. 15 | %% ------------------------------------------------------------------------ 16 | 17 | \input docstrip.tex % 18 | \keepsilent 19 | \askforoverwritefalse 20 | \usedir{tex/latex/sjtubeamer} 21 | \def\preserveoption{,maxplus,max,min,my} % reduce the option will reduce the related module extracting. Full option should be ",maxplus,max,min,my" 22 | 23 | \preamble 24 | ------------------------------------------------------------------------ 25 | Copyright (C) 2021-2024 SJTUG 26 | 27 | Licensed under the Apache License, Version 2.0 (the "License"); 28 | you may not use this file except in compliance with the License. 29 | You may obtain a copy of the License at 30 | 31 | http://www.apache.org/licenses/LICENSE-2.0 32 | 33 | Unless required by applicable law or agreed to in writing, software 34 | distributed under the License is distributed on an "AS IS" BASIS, 35 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 36 | See the License for the specific language governing permissions and 37 | limitations under the License. 38 | ------------------------------------------------------------------------ 39 | \endpreamble 40 | 41 | \generate{\file{beamerthemesjtubeamer.sty}{% 42 | \from{beamerthemesjtubeamer.dtx}{package\preserveoption}} 43 | } 44 | \generate{\file{beamerinnerthemesjtubeamer.sty}{% 45 | \from{beamerinnerthemesjtubeamer.dtx}{package\preserveoption}} 46 | } 47 | \generate{\file{beamerouterthemesjtubeamer.sty}{% 48 | \from{beamerouterthemesjtubeamer.dtx}{package}} 49 | } 50 | \generate{\file{beamerfontthemesjtubeamer.sty}{% 51 | \from{beamerfontthemesjtubeamer.dtx}{package}} 52 | } 53 | \generate{\file{beamercolorthemesjtubeamer.sty}{% 54 | \from{beamercolorthemesjtubeamer.dtx}{package}} 55 | } 56 | 57 | \preamble 58 | ------------------------------------------------------------------------ 59 | Copyright (C) Shanghai Jiao Tong University 60 | The definition in this file is referred to the Visual Identity System 61 | from Shanghai Jiao Tong University (SJTU). 62 | See https://vi.sjtu.edu.cn for more information. 63 | 64 | SJTUG implements the design but doesn't hold the copyright. 65 | Any commercial usage in this file should be acknowledged by 66 | the administration of SJTU. 67 | More infomation about the license, 68 | see https://vi.sjtu.edu.cn/index.php/articles/bulletin/16. 69 | ------------------------------------------------------------------------ 70 | \endpreamble 71 | 72 | \generate{\file{sjtucover.sty}{% 73 | \from{sjtucover.dtx}{package\preserveoption}} 74 | } 75 | \generate{\file{sjtuvi.sty}{% 76 | \from{sjtuvi.dtx}{package}} 77 | } 78 | 79 | \obeyspaces 80 | \Msg{**************************************************************} 81 | \Msg{* *} 82 | \Msg{* To finish the installation you have to move the following *} 83 | \Msg{* files into a directory searched by TeX: *} 84 | \Msg{* *} 85 | \Msg{* beamerthemesjtubeamer.sty *} 86 | \Msg{* beamerinnerthemesjtubeamer.sty *} 87 | \Msg{* beamerouterthemesjtubeamer.sty *} 88 | \Msg{* beamerfontthemesjtubeamer.sty *} 89 | \Msg{* beamercolorthemesjtubeamer.sty *} 90 | \Msg{* sjtucover.sty *} 91 | \Msg{* sjtuvi.sty *} 92 | \Msg{* vi/ *} 93 | \Msg{* *} 94 | \Msg{* To produce the documentation run the file *} 95 | \Msg{* sjtubeamertheme.tex *} 96 | \Msg{* For Development documentation, run the file *} 97 | \Msg{* sjtubeamerdevguide.tex *} 98 | \Msg{* through XeLaTeX. *} 99 | \Msg{* *} 100 | \Msg{* Happy TeXing! *} 101 | \Msg{* *} 102 | \Msg{**************************************************************} 103 | 104 | \endbatchfile 105 | -------------------------------------------------------------------------------- /src/doc/ref.bib: -------------------------------------------------------------------------------- 1 | % Encoding: UTF-8 2 | 3 | @Misc{miktex, 4 | title = {{MiK\TeX{}}}, 5 | url = {https://miktex.org/}, 6 | } 7 | 8 | @Misc{perl, 9 | title = {Perl}, 10 | url = {https://www.perl.org/}, 11 | } 12 | 13 | @Misc{upgrade, 14 | author = {{TUG}}, 15 | title = {{Upgrade from \TeX{} Live 2020 to 2021}}, 16 | url = {http://www.tug.org/texlive/upgrade.html}, 17 | } 18 | 19 | @Manual{beamerman, 20 | title = {The beamer class: User Guide for version 3.59.}, 21 | author = {Tantau, Till and Wright, Joseph and Mileti\'c, Vedran}, 22 | month = jul, 23 | year = {2020}, 24 | url = {https://github.com/josephwright/beamer}, 25 | } 26 | 27 | @Misc{lsp3, 28 | author = {{Log Creative}}, 29 | title = {{\LaTeX{} Sparkle Project}}, 30 | url = {https://logcreative.github.io/LaTeXSparkle/}, 31 | } 32 | 33 | @Misc{ab, 34 | author = {{Log Creative}}, 35 | title = {{AutoBeamer}}, 36 | url = {https://github.com/LogCreative/AutoBeamer}, 37 | } 38 | 39 | @Misc{pgfedt, 40 | author = {{Log Creative}}, 41 | title = {{PGFPlotsEdt}}, 42 | url = {https://github.com/LogCreative/PGFPlotsEdt/}, 43 | } 44 | 45 | @Misc{lact, 46 | author = {{xu-cheng}}, 47 | title = {{\LaTeX{}-action}}, 48 | url = {https://github.com/xu-cheng/latex-action} 49 | } 50 | 51 | @Manual{viman, 52 | title = {{SJTU VI} Manual}, 53 | author = {{Shanghai Jiao Tong University}}, 54 | month = apr, 55 | year = {2016}, 56 | groups = {SJ-Team}, 57 | url = {https://vi.sjtu.edu.cn/}, 58 | } 59 | 60 | @Misc{texsc, 61 | title = {{\TeX{} Stack Exchange}}, 62 | url = {https://tex.stackexchange.com/}, 63 | } 64 | 65 | @Manual{tikzman, 66 | title = {{The Ti\emph{k}Z and \textsc{PGF} Packages}}, 67 | author = {Till Tantau}, 68 | month = oct, 69 | organization = {{Institut für Theoretische Informatik, Universität zu Lübeck}}, 70 | year = {2020}, 71 | url = {https://github.com/pgf-tikz/pgf}, 72 | } 73 | 74 | @Misc{tikzedt, 75 | author = {Thomas and Julian}, 76 | month = mar, 77 | title = {{Ti\emph{k}ZEdt -- A semigraphical Ti\emph{k}Z-editor}}, 78 | year = {2014}, 79 | url = {http://www.tikzedt.org/}, 80 | } 81 | 82 | @Misc{tikztuna, 83 | author = {Paul}, 84 | month = oct, 85 | title = {{Tunight: A Drawing Guide for Ti\emph{k}Z}}, 86 | year = {2020}, 87 | url = {https://tuna.moe/event/2020/tikz/}, 88 | } 89 | 90 | @Manual{tcolorbox, 91 | title = {{tcolorbox: manual for version 4.42}}, 92 | address = {D-85577 Neubiberg}, 93 | author = {Thomas F. Sturm}, 94 | month = oct, 95 | organization = {Institut für Mathematik und Informatik, Universität der Bundeswehr München}, 96 | year = {2020}, 97 | url = {https://github.com/T-F-S/tcolorbox}, 98 | } 99 | 100 | @Book{texbook, 101 | author = {Knuth and Donald Ervin}, 102 | publisher = {American Mathematical Society and Addison-Wesley Publishing Company}, 103 | title = {{The \TeX{}book}}, 104 | year = {1991}, 105 | isbn = {0-201-13448-9}, 106 | month = may, 107 | url = {https://github.com/seuliang/the-texbook-cn}, 108 | } 109 | 110 | @Manual{texnote, 111 | title = {{Notes On Programming in \TeX{}}}, 112 | author = {{{Dr. Christian Feuers\"anger}}}, 113 | month = feb, 114 | year = {2020}, 115 | url = {https://mirrors.sjtug.sjtu.edu.cn/CTAN/graphics/pgf/contrib/pgfplots/doc/TeX-programming-notes.pdf}, 116 | } 117 | 118 | @Misc{tex2017, 119 | month = apr, 120 | title = {{Tunight: \TeX{} Workshop 2017}}, 121 | year = {2017}, 122 | organization = {TUNA}, 123 | url = {https://www.youtube.com/watch?v=fysg1IaCq2s&t=5328s}, 124 | } 125 | 126 | @Manual{hyperref, 127 | title = {{Hypertext marks in \LaTeX{}}}, 128 | author = {Rahtz, Sebastian and Oberdiek, Heiko}, 129 | month = may, 130 | organization = {{The \LaTeX{}3 Project}}, 131 | year = {2020}, 132 | url = {https://github.com/latex3/hyperref}, 133 | } 134 | 135 | @Manual{graphics, 136 | title = {{Using Import graphics in \LaTeXe{}}}, 137 | author = {Keith Reckdahl}, 138 | month = dec, 139 | year = {1997}, 140 | url = {https://www.latexstudio.net/archives/10738}, 141 | } 142 | 143 | @Misc{mylatexot1, 144 | author = {David Carlisle}, 145 | month = mar, 146 | title = {Answer to ``Precompiled header with \hologo{XeLaTeX} not working''}, 147 | year = {2017}, 148 | url = {https://tex.stackexchange.com/a/359900/253485}, 149 | } 150 | 151 | @Manual{ctex, 152 | title = {C\TeX{} 宏集手册}, 153 | author = {CTEX.ORG}, 154 | month = jun, 155 | year = {2021}, 156 | url = {https://github.com/CTeX-org/ctex-kit}, 157 | } 158 | 159 | @Manual{l3buildman, 160 | title = {The l3build package: Checking and building packages}, 161 | author = {{The \LaTeX{} Project}}, 162 | month = sep, 163 | year = {2022}, 164 | url = {https://github.com/latex3/l3build}, 165 | } 166 | 167 | @Manual{latexindent, 168 | title = {{latexindent.pl}}, 169 | author = {Chris Hughes}, 170 | month = jun, 171 | year = {2022}, 172 | url = {https://github.com/cmhughes/latexindent.pl}, 173 | } 174 | 175 | @Comment{jabref-meta: databaseType:bibtex;} 176 | -------------------------------------------------------------------------------- /beamerouterthemesjtubeamer.sty: -------------------------------------------------------------------------------- 1 | %% 2 | %% This is file `beamerouterthemesjtubeamer.sty', 3 | %% generated with the docstrip utility. 4 | %% 5 | %% The original source files were: 6 | %% 7 | %% beamerouterthemesjtubeamer.dtx (with options: `package') 8 | %% ------------------------------------------------------------------------ 9 | %% Copyright (C) 2021-2024 SJTUG 10 | %% 11 | %% Licensed under the Apache License, Version 2.0 (the "License"); 12 | %% you may not use this file except in compliance with the License. 13 | %% You may obtain a copy of the License at 14 | %% 15 | %% http://www.apache.org/licenses/LICENSE-2.0 16 | %% 17 | %% Unless required by applicable law or agreed to in writing, software 18 | %% distributed under the License is distributed on an "AS IS" BASIS, 19 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 20 | %% See the License for the specific language governing permissions and 21 | %% limitations under the License. 22 | %% ------------------------------------------------------------------------ 23 | \NeedsTeXFormat{LaTeX2e} 24 | \ProvidesPackage{beamerouterthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer outer theme] 25 | \RequirePackage{sjtuvi} 26 | \DefineOption{outer}{nav}{miniframes} 27 | \DefineOption{outer}{nav}{infolines} 28 | \DefineOption{outer}{nav}{sidebar} 29 | \DefineOption{outer}{nav}{default} 30 | \DefineOption{outer}{nav}{smoothbars} 31 | \DefineOption{outer}{nav}{split} 32 | \DefineOption{outer}{nav}{shadow} 33 | \DefineOption{outer}{nav}{tree} 34 | \DefineOption{outer}{nav}{smoothtree} 35 | \ExecuteOptionsBeamer{miniframes} 36 | \DefineOption{outer}{logopos}{topright} 37 | \DefineOption{outer}{logopos}{bottomright} 38 | \ExecuteOptionsBeamer{bottomright} 39 | \ProcessOptionsBeamer 40 | \beamer@compresstrue 41 | \if\EqualOption{outer}{logopos}{topright} 42 | \AtBeginDocument{ 43 | \defbeamertemplate*{frametitle}{sjtubeamer}[1][] 44 | {% 45 | \ifbeamercolorempty[bg]{frametitle}{}{\nointerlineskip}% 46 | \@tempdima=\textwidth% 47 | \advance\@tempdima by\beamer@leftmargin% 48 | \advance\@tempdima by\beamer@rightmargin% 49 | \begin{beamercolorbox}[sep=0.15cm,leftskip=0.15cm,#1,wd=\the\@tempdima]{frametitle} 50 | \begingroup 51 | \usebeamerfont{frametitle} 52 | \vbox{} 53 | \ifx\insertframesubtitle\@empty\vskip-0.5ex% 54 | \else\vskip-0.7ex\fi% 55 | \if@tempswa\else\csname beamer@fte#1\endcsname\fi% 56 | \strut\insertframetitle\strut\par% 57 | {% 58 | \ifx\insertframesubtitle\@empty% 59 | \else% 60 | { 61 | \usebeamerfont{framesubtitle} 62 | \usebeamercolor[fg]{framesubtitle} 63 | \strut\insertframesubtitle\strut\par 64 | }% 65 | \fi 66 | }% 67 | \vskip-1.07ex% 68 | \endgroup% 69 | \raggedleft% 70 | \begingroup 71 | \ifx\insertframesubtitle\@empty\vskip-2.2ex% 72 | \else\vskip-3.05ex\fi% 73 | \resizebox{!}{3ex}{\vphantom{-}\usebeamertemplate{logo}}\hspace*{10pt}% 74 | \endgroup% 75 | \ifx\insertframesubtitle\@empty% 76 | \else\vskip0.75ex\fi% 77 | \if@tempswa\else\vskip-.3cm\fi% 78 | \end{beamercolorbox}% 79 | } 80 | } 81 | \if\EqualOption{outer}{nav}{default} 82 | \AtBeginDocument{ 83 | \setbeamertemplate{frametitle}[sjtubeamer][leftskip=0cm,sep=0.3cm] 84 | } 85 | \fi 86 | \fi 87 | \if\EqualOption{outer}{nav}{miniframes} 88 | \useoutertheme[footline=institutetitle]{miniframes} 89 | \else\if\EqualOption{outer}{nav}{sidebar} 90 | \useoutertheme{sidebar} 91 | \logo{\resizebox{!}{1cm}{\sjtubadge}} 92 | \def\sjtubeamer@outer@logopos{topright} 93 | \AtBeginDocument{ 94 | \setbeamertemplate{frametitle}[sidebar theme] 95 | } 96 | \else 97 | \useoutertheme{\sjtubeamer@outer@nav} 98 | \setbeamercolor{title in head/foot}{use=structure,bg=white,fg=structure.fg} 99 | \fi\fi 100 | \if\EqualOption{outer}{nav}{default} 101 | \setbeamercolor{frametitle}{use=palette primary, 102 | bg=palette primary.bg,fg=palette primary.fg} 103 | \else\if\EqualOption{outer}{nav}{infolines} 104 | \setbeamercolor{author in head/foot}{use=structure,fg=white,bg=structure} 105 | \setbeamercolor{title in head/foot}{use=structure,fg=structure,bg=structure!10} 106 | \setbeamercolor{date in head/foot}{use=structure,fg=structure,bg=structure!20} 107 | \setbeamercolor{section in head/foot}{parent=author in head/foot} 108 | \setbeamercolor{subsection in head/foot}{parent=date in head/foot} 109 | \setbeamersize{text margin left=1cm,text margin right=1cm} 110 | \else 111 | \setbeamercolor{frametitle}{use=titlelike,bg=white,fg=titlelike.fg} 112 | \setbeamercolor{frametitle right}{parent=subsection in head/foot} 113 | \fi\fi 114 | \setbeamertemplate{sidebar right}{} 115 | \addtobeamertemplate{navigation symbols}{}{ 116 | \hbox{ 117 | \raisebox{1.2pt}[0pt][0pt]{ 118 | \usebeamerfont{footline} 119 | \usebeamercolor{footline} 120 | \color{footline.fg!50} 121 | \insertframenumber/\inserttotalframenumber 122 | \hspace*{0.2em} 123 | } 124 | } 125 | } 126 | \if\EqualOption{outer}{logopos}{bottomright} 127 | \addtobeamertemplate{footline}{ 128 | \hfill% 129 | \usebeamertemplate***{navigation symbols}% 130 | \llap{\raisebox{1pc}[0pt][0pt]{\insertlogo}} 131 | \hspace*{0.1cm}\par 132 | \vskip 4pt 133 | }{} 134 | \else 135 | \addtobeamertemplate{footline}{ 136 | \hfill% 137 | \usebeamertemplate***{navigation symbols}% 138 | \hspace*{0.1cm}\par 139 | \vskip 4pt 140 | }{} 141 | \fi 142 | \setbeamertemplate{page number in head/foot}{} 143 | \endinput 144 | %% 145 | %% End of file `beamerouterthemesjtubeamer.sty'. 146 | -------------------------------------------------------------------------------- /contrib/poster/poster.tex: -------------------------------------------------------------------------------- 1 | \documentclass{ctexbeamer} 2 | \usetheme[red]{sjtubeamer} 3 | \usesjtutheme{poster} 4 | % \usesjtutheme[landscape]{poster} 5 | % \usesjtutheme[sepinst]{poster} 6 | % \usesjtutheme[noindent]{poster} 7 | \usepackage{subcaption} 8 | \usepackage[style=gb7714-2015]{biblatex} 9 | \addbibresource{\getcontribpath{poster}{ref.bib}} 10 | \usepackage{zhlipsum} 11 | \begin{document} 12 | % 当标题较长时,可以使用 \\ 换行。 13 | \title{poster 子主题\\使用说明} 14 | \author{作者} 15 | \logo{\zhlogo} 16 | \institute[Test Institute]{测试机构} 17 | \footline[左脚注]{右脚注} 18 | \begin{frame}[fragile] 19 | \begin{columns}[T] 20 | \begin{column}{.45\textwidth} 21 | 22 | \begin{stampblock}{主题概述} 23 | \texttt{poster} 子主题基于 \texttt{beamerposter} 宏包\cite{beamerposter},对 24 | SJTUBeamer 进行适配以制作海报,展示您的成果。 25 | \codeblockinput[firstline=1,lastline=3]{开始使用}{poster.tex} 26 | \end{stampblock} 27 | 28 | \begin{stampblock}{风格建议} 29 | 建议使用 \texttt{stampblock} 环境分割不同的区块。你也可以使用 \texttt{block} 30 | 环境分割不同的区块。相较于普通 \texttt{beamer} 幻灯片文字较少的情形,\texttt{poster} 31 | 更有可能会写入大段文字,所以默认情况下这些区块内部会有首行缩进。由于 \texttt{column} 32 | 环境内部不受外部首行缩进的影响,所以不推荐之间在 33 | \texttt{column} 环境中书写内容,而应该再套一层 \texttt{stampblock} 或 \texttt{block}。 34 | 35 | 可以插入图片来丰富你的海报内容,但请注意由于海报的纸张尺寸较大,像一些高 DPI 36 | 显示的场景一样,会对文字大小进行缩放,但是度量上却没有发生变化,请注意要使用相对于平时更大的度量插入图片。 37 | 38 | 不推荐直接插入 Ti\emph{k}Z 的代码,推荐使用 \texttt{standalone} 文档类产生 PDF 39 | 文件后再插入,否则会导致图片内的文字过大而排版错乱。 40 | \end{stampblock} 41 | 42 | \begin{stampblock}{多栏对齐} 43 | 推荐使用 \texttt{columns} 环境分割多栏,环境可选选项可以用于指定顶部对齐 \texttt{t},居中对齐 44 | \texttt{c},底部对齐 \texttt{b}。 45 | 46 | \codeblockinput[firstline=16,lastline=16,firstnumber=1]{多栏}{poster.tex} 47 | \end{stampblock} 48 | 49 | \end{column} 50 | \begin{column}{.45\textwidth} 51 | 52 | \begin{stampblock}{图文混排} 53 | 由于 \texttt{beamer} 关闭了浮动体浮动,所以推荐使用多栏分割的方式实现图文混排。 54 | 或者是多图并排放置。 55 | \begin{columns} 56 | \begin{column}{0.7\textwidth} 57 | 上海交通大学的东大门---紫气东来门,简称庙门,位于上海市闵行区莲花南路 4800 号。 58 | \end{column} 59 | \begin{column}{0.3\textwidth} 60 | \begin{figure} 61 | \includegraphics[width=\textwidth]{vi/sjtu-vi-sjtuphoto.jpg} 62 | \caption{庙门} 63 | \end{figure} 64 | \end{column} 65 | \end{columns} 66 | \begin{figure} 67 | \begin{subfigure}{0.4\textwidth} 68 | \resizebox{\textwidth}{!}{\secondaryinstlogo[Test 69 | Institute]{测试机构}{\zhlogo}} 70 | \caption{中文} 71 | \end{subfigure}\hspace*{20pt} 72 | \begin{subfigure}{0.4\textwidth} 73 | \resizebox{\textwidth}{!}{\secondaryinstlogo[]{Test 74 | Institute}{\enlogo}} 75 | \caption{英文} 76 | \end{subfigure} 77 | \caption{二级机构徽标} 78 | \end{figure} 79 | \end{stampblock} 80 | 81 | \begin{stampblock}{参考文献} 82 | 83 | 可以使用图标样式的参考文献。 84 | 85 | \begin{bibliolist}{00} 86 | \onlineitem \textsc{Tantau T}, \textsc{Wright J}, and 87 | \textsc{Mileti\'c V}.\newblock 88 | The beamer class: User Guide for version 3.67[OL].\newblock 89 | 2022. \url{https://github.com/josephwright/beamer} 90 | \articleitem \textsc{上海交通大学}.\newblock 91 | 上海交通大学视觉形象识别系统[OL].\newblock 92 | 2016. \url{https://vi.sjtu.edu.cn} 93 | \bookitem \textsc{Knuth DE}.\newblock 94 | The \TeX{}book[M].\newblock 95 | Addison-Wesley. 1986. 96 | \end{bibliolist} 97 | 98 | 你也可以使用 \texttt{biblatex} 插入参考文献。 99 | 100 | \printbibliography 101 | 102 | \end{stampblock} 103 | 104 | \end{column} 105 | \end{columns} 106 | 107 | % 正文中的分割线使用 \posterstamphrule 108 | \posterstamphrule[cprimary] 109 | 110 | \begin{columns} 111 | \begin{column}{0.45\textwidth} 112 | \begin{block}{选项} 113 | \texttt{poster} 子主题拥有一些选项。 114 | \begin{description} 115 | \item[\texttt{sepinst}] 分离徽标与机构于两侧 116 | \item[\texttt{landscape}] 横向海报 117 | \item[\texttt{noindent}] 首行不缩进 118 | \end{description} 119 | \end{block} 120 | \begin{alertblock}{脚注} 121 | 使用 \texttt{\textbackslash{}footline[左脚注]\{右脚注\}} 设定左脚注和右脚注。 122 | \end{alertblock} 123 | \begin{exampleblock}{区块} 124 | 仍然可以使用内置的 \texttt{block}, \texttt{alertblock}, \texttt{exampleblock} 125 | 插入对应的区块。 126 | \end{exampleblock} 127 | \end{column} 128 | \begin{column}{0.45\textwidth} 129 | 130 | \begin{stampblock}[a]{印记区块} 131 | 使用 \texttt{stampblock} 环境插入带有印记图案的区块,编号会自动递增。你也可以通过指定可选参数来设置编号内容。 132 | \end{stampblock} 133 | 134 | \begin{codeblock}[numbers=none]{代码块} 135 | % 应当减少代码块的使用,增加了标题栏的高度。 136 | % 关闭代码行号编号可以在 codeblock 上添加选项 numbers=none 137 | \end{codeblock} 138 | 139 | \begin{columns}[b] 140 | \begin{column}{.5\textwidth} 141 | \begin{stampbox} 142 | \includegraphics[width=16cm]{vi/sjtu-vi-sjtuphoto.jpg} 143 | \end{stampbox} 144 | \end{column} 145 | \begin{column}{.5\textwidth} 146 | $\leftarrow$ 你仍然可以使用 \texttt{stampbox} 环境插入带边框的图片\vspace{1ex} 147 | % column 环境中的分割线仍然使用 \stamphrule 148 | \stamphrule 149 | \end{column} 150 | \end{columns} 151 | \end{column} 152 | \end{columns} 153 | \end{frame} 154 | \title{} 155 | \author{} 156 | \logo{} 157 | \institute[]{} 158 | \begin{frame} 159 | \begin{columns} 160 | 161 | \begin{column}{.5\textwidth} 162 | \begin{stampblock}{测试} 163 | \zhlipsum[1] 164 | \end{stampblock} 165 | 166 | \begin{stampblock}{测试} 167 | \zhlipsum[2] 168 | \end{stampblock} 169 | 170 | \vspace*{0.5ex} 171 | 172 | \begin{stampblock}{测试} 173 | \zhlipsum[3] 174 | \end{stampblock} 175 | \end{column} 176 | 177 | \end{columns} 178 | 179 | \end{frame} 180 | \end{document} -------------------------------------------------------------------------------- /main.tex: -------------------------------------------------------------------------------- 1 | % !TeX encoding = UTF-8 2 | 3 | %% ------------------------------------------------------------------------ 4 | %% Copyright (C) 2021-2023 SJTUG 5 | %% 6 | %% SJTUBeamer Example Document by SJTUG 7 | %% 8 | %% SJTUBeamer Example Document is licensed under a 9 | %% Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. 10 | %% 11 | %% You should have received a copy of the license along with this 12 | %% work. If not, see . 13 | %% 14 | %% For a quick start, check out src/doc/sjtubeamerquickstart.tex 15 | %% Join discussions: https://github.com/sjtug/SJTUBeamer/discussions 16 | %% ----------------------------------------------------------------------- 17 | 18 | \documentclass[xcolor=table,dvipsnames,svgnames,aspectratio=169]{ctexbeamer} 19 | % 可以通过 fontset=macnew / fontset=ubuntu / fontset=windows 选项切换字体集; 20 | % 如遇无法显示的数学符号,尝试对 ctexbeamer 文档类添加 no-math 选项; 21 | % 写纯英文幻灯片可以改用 beamer 文档类。 22 | 23 | \usepackage{tikz} 24 | \usepackage[normalem]{ulem} 25 | \usetikzlibrary{arrows} 26 | \usepackage{amsmath} 27 | \usepackage{graphicx} 28 | \usepackage{hologo} 29 | \usepackage{colortbl} 30 | \usepackage{shapepar} 31 | \usepackage{hyperxmp} 32 | \usepackage{booktabs} 33 | \usepackage{listings} 34 | \usepackage{tipa} 35 | \usepackage{multicol} 36 | \usepackage{datetime2} 37 | \usepackage{fontawesome5} 38 | \usepackage{hyperref} 39 | 40 | % 参考文献设置,使用 style=gb7714-2015 样式为标准顺序编码制, 41 | % 使用 style=gb7714-2015ay 样式可以改为著者-出版年制。 42 | \usepackage[backend=biber,style=gb7714-2015]{biblatex} 43 | \addbibresource{ref.bib} 44 | 45 | % 该行指定了图像的额外搜索路径 46 | \graphicspath{{figures/}} 47 | 48 | \hypersetup{ 49 | pdfcopyright = {Licensed under CC-BY-SA 4.0. Some rights reserved.}, 50 | pdflicenseurl = {http://creativecommons.org/licenses/by-sa/4.0/}, 51 | unicode = true, 52 | psdextra = true, 53 | pdfdisplaydoctitle = true 54 | } 55 | 56 | \pdfstringdefDisableCommands{ 57 | \let\\\relax 58 | \let\quad\relax 59 | \let\hspace\@gobble 60 | } 61 | 62 | \renewcommand{\TeX}{\hologo{TeX}} 63 | \renewcommand{\LaTeX}{\hologo{LaTeX}} 64 | \newcommand{\BibTeX}{\hologo{BibTeX}} 65 | \newcommand{\XeTeX}{\hologo{XeTeX}} 66 | \newcommand{\pdfTeX}{\hologo{pdfTeX}} 67 | \newcommand{\LuaTeX}{\hologo{LuaTeX}} 68 | \newcommand{\MiKTeX}{\hologo{MiKTeX}} 69 | \newcommand{\MacTeX}{Mac\hologo{TeX}} 70 | \newcommand{\beamer}{\textsc{beamer}} 71 | \newcommand{\XeLaTeX}{\hologo{Xe}\kern-.13em\LaTeX{}} 72 | \newcommand{\pdfLaTeX}{pdf\LaTeX{}} 73 | \newcommand{\LuaLaTeX}{Lua\LaTeX{}} 74 | \def\TeXLive{\TeX{} Live} 75 | \let\TL=\TeXLive 76 | 77 | \newcommand{\SJTUThesis}{\textsc{SJTUThesis}} 78 | \newcommand{\SJTUThesisVersion}{2.0.3} 79 | \newcommand{\SJTUThesisDate}{2023/9/25} 80 | \newcommand{\SJTUBeamer}{\textsc{SJTUBeamer}} 81 | \newcommand{\SJTUBeamerVersion}{3.0.0} 82 | \newcommand{\SJTUBeamerDate}{2022/11/22} 83 | 84 | \newcommand\link[1]{\href{#1}{\faLink}} 85 | \newcommand\pkg[1]{\texttt{#1}} 86 | 87 | \def\cmd#1{\texttt{\color{structure}\footnotesize $\backslash$#1}} 88 | \def\env#1{\texttt{\color{structure}\footnotesize #1}} 89 | \def\cmdxmp#1#2#3{\small{\texttt{\color{structure}$\backslash$#1}\{#2\} 90 | \hspace{1em}\\ $\Rightarrow$\hspace{1em} {#3}\par\vskip1em}} 91 | 92 | \usetheme[maxplus]{sjtubeamer} 93 | % 使用 maxplus/max/min 切换标题页样式 94 | % 使用 red/blue 切换主色调 95 | % 使用 light/dark 切换亮/暗色模式 96 | % 使用外样式关键词以获得不同的边栏样式 97 | % miniframes infolines sidebar 98 | % default smoothbars split 99 | % shadow tree smoothtree 100 | % 使用 topright/bottomright 切换徽标位置 101 | % 使用逗号分隔列表以同时使用多种选项 102 | 103 | % \setbeamertemplate{background}{} 104 | % 对于 max 主题,如果需要关闭正文背景图,请取消注释上一行。 105 | 106 | % \tikzexternalize[prefix=build/] 107 | % 如果您需要缓存 tikz 图像,请取消注释上一行,并在编译选项中添加 -shell-escape。 108 | 109 | \lstset{ 110 | language=[LaTeX]TeX, % 更改高亮语言 111 | texcsstyle=*\color{cprimary}, % 只在高亮 LaTeX 语言时必须 112 | tabsize=2, 113 | basicstyle=\ttfamily\small,% 114 | keywordstyle=\color{cprimary},% 115 | stringstyle=\color{csecondary},% 116 | commentstyle=\color{ctertiary!50!gray},% 117 | breaklines,% 118 | } 119 | 120 | \author{Alexara Wu} 121 | \institute[SJTUG]{上海交通大学 Linux 用户组} 122 | \date{\the\year 年 \the\month 月} 123 | \subject{上海交通大学图书馆专题培训讲座} 124 | \keywords{LaTeX, 论文排版, SJTUThesis} 125 | 126 | \title[\SJTUBeamer 示例文档] % 页脚显示标题 127 | {\textbf{如何使用 \LaTeX{} 排版论文}} % 首页标题 128 | 129 | \subtitle{\SJTUBeamer 示例文档} 130 | 131 | \begin{document} 132 | 133 | % 使用节目录 134 | \AtBeginSection[]{ 135 | \begin{frame} 136 | %% 使用传统节目录,也可以将 subsectionstyle=... 换成 hideallsubsections 以隐藏所有小节信息 137 | \tableofcontents[currentsection,subsectionstyle=show/show/hide] 138 | %% 或者使用节页 139 | % \sectionpage 140 | \end{frame} 141 | } 142 | 143 | % 使用小节目录 144 | \AtBeginSubsection[]{ % 在每小节开始 145 | \begin{frame} 146 | %% 使用传统小节目录 147 | \tableofcontents[currentsection,subsectionstyle=show/shaded/hide] 148 | %% 或者使用小节页 149 | % \subsectionpage 150 | \end{frame} 151 | } 152 | 153 | \maketitle 154 | 155 | \begin{frame} 156 | \frametitle{来源} 157 | \begin{thebibliography}{00} 158 | \setbeamertemplate{bibliography item}[online] 159 | \bibitem{} Alexara Wu. 160 | \newblock 如何使用 \LaTeX{} 排版论文[EB/OL]. 161 | \newblock 2021. 162 | \url{https://github.com/sjtug/sjtulib-latex-talk/tree/alexara-2021} 163 | \end{thebibliography} 164 | 165 | \vspace*{2ex} 166 | 167 | \begin{itemize} 168 | \item 本示例文档的源码结构适用于简短的单次报告,仅展示 \beamer{} 文档类的通 169 | 用功能,更多地在使用 \SJTUBeamer{} 的样式信息。 170 | \item 为发挥 \SJTUBeamer{} 的全部功能,参见发布区 171 | \link{https://github.com/sjtug/SJTUBeamer/releases} 的快速入门、用户手 172 | 册与开发文档。 173 | \item 就制作一组讲座而言,相关源码结构可以参考新讲座 174 | \link{https://github.com/sjtug/sjtulib-latex-talk/tree/logcreative-2022}。 175 | 新讲座使用了社区版主题的同时也展示了 \SJTUBeamer{} 的特殊用法。 176 | \end{itemize} 177 | 178 | \end{frame} 179 | 180 | \begin{frame}{目录} 181 | \tableofcontents[hideallsubsections] % 隐藏所有小节信息 182 | \end{frame} 183 | 184 | \include{contents/introduction} 185 | \include{contents/basis} 186 | \include{contents/thesis} 187 | \include{contents/summary} 188 | 189 | \begin{frame} 190 | \frametitle{参考文献} 191 | \printbibliography[heading=none] 192 | \end{frame} 193 | 194 | \makebottom 195 | 196 | \end{document} 197 | -------------------------------------------------------------------------------- /contents/summary.tex: -------------------------------------------------------------------------------- 1 | % !TeX encoding = UTF-8 2 | % !TeX root = ../main.tex 3 | 4 | %% ------------------------------------------------------------------------ 5 | %% Copyright (C) 2021-2023 SJTUG 6 | %% 7 | %% SJTUBeamer Example Document by SJTUG 8 | %% 9 | %% SJTUBeamer Example Document is licensed under a 10 | %% Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. 11 | %% 12 | %% You should have received a copy of the license along with this 13 | %% work. If not, see . 14 | %% ----------------------------------------------------------------------- 15 | 16 | \section{总结} 17 | 18 | \begin{frame}{常见 \LaTeX{} 困惑} 19 | \begin{itemize} 20 | \item \alert{编译不通过} 缺少必要宏包,命令拼写错误,括号未配对等 21 | \item \alert{表格图片乱跑} 非问题,\LaTeX{} 浮动定位算法 22 | \link{https://liam.page/2017/04/30/floats-in-LaTeX-the-positioning-algorithm/} 23 | \item \alert{段落间距变大} 非问题,\LaTeX{} 排版算法 24 | \item \alert{参考文献} 推荐使用 \BibTeX{} 或者 Bib\LaTeX{}(视模板而定),也可以手写 \cmd{bibitem} 25 | \link{https://github.com/hushidong/biblatex-gb7714-2015} 26 | \end{itemize} 27 | \end{frame} 28 | 29 | \begin{frame}{系统学习} 30 | \begin{itemize} 31 | \item 包太雷 《\LaTeX{} Notes(第二版)》~(3小时)(lnotes2) 32 | \link{http://dralpha.altervista.org/zh/tech/lnotes2.pdf} 33 | \item Stefan Kottwitz 《LaTeX Cookbook》 34 | \item WikiBooks:英文 \link{https://en.wikibooks.org/wiki/LaTeX}、中文 35 | \link{https://zh.wikibooks.org/wiki/LaTeX} 36 | \item 在线教程:OverLeaf 帮助文档 \link{https://www.overleaf.com/learn} 37 | \item 经典文档(亦可能比较过时) 38 | \begin{itemize} 39 | \item 仔细阅读《一份不太简短的~\LaTeXe{} 介绍》(lshort-zh-cn)~(1--2 天) 40 | \link{https://mirrors.sjtug.sjtu.edu.cn/CTAN/info/lshort/chinese/lshort-zh-cn.pdf} 41 | \item 粗略阅读《\LaTeXe{} 插图指南》~(2--3 小时) 42 | \end{itemize} 43 | \item 从~\SJTUThesis{} 示例文档入手 44 | \end{itemize} 45 | \end{frame} 46 | 47 | \begin{frame}{扩展阅读} 48 | \begin{itemize} 49 | \item 一份其实很短的 \LaTeX 入门文档 (Liam Huang) 50 | \link{https://liam.page/2014/09/08/latex-introduction/} 51 | \item 网站推荐: 52 | \begin{itemize} 53 | \item http://www.latexstudio.net/ 54 | \item http://www.chinatex.org/ 55 | \end{itemize} 56 | \item 知乎 \LaTeX{} 专栏(偏技术) 57 | \link{http://zhuanlan.zhihu.com/LaTeX} 58 | % \item \LaTeX{}杂谈(刘海洋) 59 | \item 《\LaTeX{}入门》(刘海洋) 60 | \item 现代 LaTeX入门讲座(曾祥东) 61 | \link{https://github.com/stone-zeng/latex-talk/releases/tag/2019-04-18} 62 | \item “黑科技”:在 \LaTeX{} 中书写 Markdown 进行排版 63 | \link{https://liam.page/2020/03/30/writing-manuscript-in-Markdown-and-typesetting-with-LaTeX/} 64 | \end{itemize} 65 | \end{frame} 66 | 67 | \begin{frame}[fragile]{利用文档} 68 | \begin{itemize} 69 | \item 常用文档(\verb|texdoc |) 70 | \begin{itemize} 71 | \item \pkg{symbols}: 符号大全 72 | \item \pkg{Mathmode}: 数学参考 73 | \item \pkg{ctex}, \pkg{xeCJK}: 中文支持 74 | \item \pkg{texlive-zh}: \TL 安装与使用 75 | \item 所用宏包文档 76 | \end{itemize} 77 | \item 工具 78 | \begin{itemize} 79 | \item \verb|tlmgr|: \TL 管理器 80 | \item \verb|texdoc|: \TeX{} 文档查看器\\ 81 | 例如:\verb|texdoc lshort-zh-cn| 82 | \item 在线文档 \TeX{}doc \link{http://texdoc.net/} 83 | \item \TeX{}studio 和 WinEdt 都支持在帮助里看文档 84 | \end{itemize} 85 | \end{itemize} 86 | \end{frame} 87 | 88 | \begin{frame}{一点人生的经验} 89 | \begin{itemize} 90 | \item 不要着急安装,先在 OverLeaf 上熟悉各类操作 91 | \item 不要过于相信网上的中文文档 92 | \begin{itemize} 93 | \item 简单鉴别方法: 排版的好看程度 94 | \end{itemize} 95 | \item 湿兄用U盘拷给你的的 \CTeX{} 套装一定是过时的,\SJTUThesis{} 八成是老版本的 96 | \item 如果你要处理中文 97 | \begin{itemize} 98 | \item 使用 \XeLaTeX{}, 使用 \XeLaTeX{}, 使用 \XeLaTeX{} 99 | \item 忘记 \pkg{CJK}, 忘记 \pkg{CJK}, 忘记 \pkg{CJK} 100 | \item 使用 \pkg{ctex} 宏包(2.0以上版本)(跟 \CTeX{} 套装仅仅是名字像) 101 | \end{itemize} 102 | \item 写一点,编译一次,减小排错搜索空间 103 | \end{itemize} 104 | \end{frame} 105 | 106 | \begin{frame}[fragile] 107 | \frametitle{Git版本管理} 108 | \begin{itemize} 109 | \item 版本管理的必要性 110 | \begin{itemize} 111 | \item 远离「初稿,第二稿……终稿,终稿(打死也不改了)」命名 112 | \item 方便与他人协同合作 113 | \end{itemize} 114 | \item 基本用法 115 | \begin{itemize} 116 | \item 跟踪更改:\verb|git init|、\verb|git add| 117 | \verb|git commit| 118 | \item 撤销与回滚:\verb|git reset|、\verb|git revert| 119 | \item 分支与高级用法:\verb|git branch|、\verb|git checkout| 120 | \verb|git rebase| 121 | \item 远端仓库操作:\verb|git pull|、\verb|git push|、 122 | \verb|git fetch| 123 | \item 推荐用 VS Code 等进行可视化操作 124 | \item 参考链接:\link{https://git-scm.com/book/en/v2} 125 | \link{https://www.liaoxuefeng.com/wiki/0013739516305929606dd18361248578c67b8067c8c017b000} 126 | \end{itemize} 127 | \item 在线 Git 服务 128 | \begin{itemize} 129 | \item GitHub \href{https://github.com}{\faGithub} 130 | \item 上海交通大学源代码管理平台(基于 GitLab) 131 | \link{https://git.sjtu.edu.cn} 132 | \end{itemize} 133 | \end{itemize} 134 | \end{frame} 135 | 136 | % 寻求帮助 137 | \begin{frame}{求助} 138 | \begin{columns}[c] 139 | \begin{column}{.45\textwidth} 140 | \begin{itemize} 141 | \item BBS 142 | \begin{itemize} 143 | \item 水源社区 \link{https://shuiyuan.sjtu.edu.cn/tag/latex} 144 | \item \sout{\CTeX 社区} (已关闭) \link{http://bbs.ctex.org/} 145 | \item 转移到 GitHub 的 \CTeX 社区 146 | \link{https://github.com/CTeX-org/forum} 147 | \end{itemize} 148 | \item \TeX{} FAQ \link{https://www.texfaq.org/} 149 | \item \TeX{} StackExchange \link{https://tex.stackexchange.com/} 150 | \item Google, Bing, etc. 151 | \begin{itemize} 152 | \item 使用\textbf{英语}搜索 153 | \end{itemize} 154 | \end{itemize} 155 | \end{column} 156 | \begin{column}{.45\textwidth} 157 | \includegraphics[width=\textwidth]{TFZsuperellipse-crop.pdf} 158 | \end{column} 159 | \end{columns} 160 | \end{frame} 161 | 162 | \begin{frame}{你也可以帮助} 163 | \begin{itemize} 164 | \item 错误反馈、改进建议:GitHub Issues 165 | \link{https://github.com/sjtug/SJTUThesis/issues} 166 | \item 出力维护:\LaTeX{} 宏包、模板编写,bug 修复 167 | \item 科普、答疑 168 | \item \sout{来当主讲人} 169 | \end{itemize} 170 | \end{frame} 171 | -------------------------------------------------------------------------------- /src/source/beamercolorthemesjtubeamer.dtx: -------------------------------------------------------------------------------- 1 | % \iffalse meta-comment -------------------------------------------------- 2 | % Copyright (C) 2021-2024 SJTUG 3 | % 4 | % Licensed under the Apache License, Version 2.0 (the "License"); 5 | % you may not use this file except in compliance with the License. 6 | % You may obtain a copy of the License at 7 | % 8 | % http://www.apache.org/licenses/LICENSE-2.0 9 | % 10 | % Unless required by applicable law or agreed to in writing, software 11 | % distributed under the License is distributed on an "AS IS" BASIS, 12 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | % See the License for the specific language governing permissions and 14 | % limitations under the License. 15 | % ------------------------------------------------------------------------ \fi 16 | % \iffalse 17 | %<*package> 18 | \NeedsTeXFormat{LaTeX2e} 19 | \ProvidesPackage{beamercolorthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer color theme] 20 | % 21 | % \fi 22 | % \CheckSum{0} 23 | % \StopEventually{} 24 | % \iffalse 25 | %<*package> 26 | % ----------------------------------------------------------------------- \fi 27 | % 28 | % \subsection{Color Theme} 29 | % 30 | % Load SJTU VI Library to get the pre-defined color. 31 | % \begin{macrocode} 32 | \RequirePackage{sjtuvi} 33 | % \end{macrocode} 34 | % 35 | % \begin{macro}{\sjtubeamer@color@color} 36 | % \begin{macrocode} 37 | \DefineOption{color}{color}{red} 38 | \DefineOption{color}{color}{blue} 39 | \ExecuteOptionsBeamer{red} 40 | % \end{macrocode} 41 | % \end{macro} 42 | % 43 | % \begin{macro}{\sjtubeamer@color@lum} 44 | % \begin{macrocode} 45 | \DefineOption{color}{lum}{light} 46 | \DefineOption{color}{lum}{dark} 47 | \ExecuteOptionsBeamer{dark} 48 | % \end{macrocode} 49 | % \end{macro} 50 | % 51 | % \begin{macrocode} 52 | \ProcessOptionsBeamer 53 | % \end{macrocode} 54 | % 55 | % Intermediate color palette depending on the choice of color theme. 56 | % 57 | % NOTICE: inner theme has a replica of the following code. 58 | % To fullfill with the standfree requirements. 59 | % \begin{macrocode} 60 | \if\EqualOption{color}{color}{red} 61 | \colorlet{cprimary}{sjtuRedPrimary} 62 | \colorlet{csecondary}{sjtuRedSecondary} 63 | \colorlet{ctertiary}{sjtuRedTertiary} 64 | \colorlet{cquanternary}{black} 65 | \else 66 | \colorlet{cprimary}{sjtuBluePrimary} 67 | \colorlet{csecondary}{sjtuBlueSecondary} 68 | \colorlet{ctertiary}{sjtuBlueTertiary} 69 | \colorlet{cquanternary}{white} 70 | \fi 71 | % \end{macrocode} 72 | % 73 | % Main color palatte depending on the choice of lumination. 74 | % Especially, the \verb"structure" interface could not be derived from 75 | % any other color palette. 76 | % \begin{macrocode} 77 | \setbeamercolor{structure}{fg=cprimary} 78 | \if\EqualOption{color}{lum}{light} 79 | \setbeamercolor{palette primary}{bg=white,fg=cprimary} 80 | \setbeamercolor{palette secondary}{bg=white,fg=cprimary!50!csecondary} 81 | \setbeamercolor{palette tertiary}{bg=white,fg=csecondary} 82 | \else 83 | \setbeamercolor{palette primary}{bg=cprimary,fg=white} 84 | \setbeamercolor{palette secondary}{bg=cprimary!50!csecondary,fg=white} 85 | \setbeamercolor{palette tertiary}{bg=csecondary,fg=white} 86 | \fi 87 | % \end{macrocode} 88 | % 89 | % This part defines the color scheme of title. 90 | % \begin{macrocode} 91 | \setbeamercolor{background canvas}{bg=white} 92 | \setbeamercolor{normal text}{fg=black,bg=black!40} 93 | \setbeamercolor*{block title}{parent=structure} 94 | \setbeamercolor{titlelike}{bg=,fg=cprimary} 95 | \setbeamercolor{title}{use={palette primary},fg=palette primary.fg,bg=} 96 | \setbeamercolor{subtitle}{use={palette secondary},fg=palette secondary.fg,bg=} 97 | \setbeamercolor{author}{use={palette primary},bg=,fg=palette primary.fg} 98 | \setbeamercolor{institute}{parent=author} 99 | \setbeamercolor{date}{parent=author} 100 | % \end{macrocode} 101 | % 102 | % Logo color system is now controlled by \verb"logo.fg". 103 | % If you want to use a logo with its color definition in \verb"logo", 104 | % use \verb"\insertlogo". Otherwise, if you want to use a logo that matches 105 | % the current text color, use \verb"\usebeamertemplate{logo}". 106 | % \begin{macrocode} 107 | \setbeamercolor{logo}{bg=,fg=cprimary} 108 | % \end{macrocode} 109 | % 110 | % This part defines the color of block title. 111 | % \begin{macrocode} 112 | \setbeamercolor{block title}{fg=white,bg=cprimary!90} 113 | \setbeamercolor{block title alerted}{use=alerted text, 114 | fg=white,bg=csecondary} 115 | \setbeamercolor{block title example}{use=example text, 116 | fg=cquanternary,bg=ctertiary} 117 | % \end{macrocode} 118 | % 119 | % This part defines the color of block body. 120 | % \begin{macrocode} 121 | \setbeamercolor{block body}{parent=normal text,use=block title, 122 | bg=block title.bg!15} 123 | \setbeamercolor{block body alerted}{parent=normal text, 124 | use=block title alerted,bg=block title alerted.bg!15} 125 | \setbeamercolor{block body example}{parent=normal text, 126 | use=block title example,bg=block title example.bg!15} 127 | % \end{macrocode} 128 | % 129 | % Set up the background color for stampblock. 130 | % In case you want to change to something like \verb"cprimary!10". 131 | % \begin{macrocode} 132 | \setbeamercolor{block body stamp}{bg=} 133 | % \end{macrocode} 134 | % 135 | % This part defines the color of footline. 136 | % \begin{macrocode} 137 | \setbeamercolor{footnote}{fg=cprimary,bg=} 138 | % \end{macrocode} 139 | % 140 | % This part defines the color of part page, section page, and subsection page. 141 | % \begin{macrocode} 142 | \setbeamercolor{part title}{parent={palette primary}} 143 | \setbeamercolor{section title}{parent={palette secondary}} 144 | \setbeamercolor{subsection title}{parent={palette tertiary}} 145 | % \end{macrocode} 146 | % 147 | % Set the footline color. 148 | % \begin{macrocode} 149 | \setbeamercolor{section in head/foot}{fg=white,bg=cprimary} 150 | \setbeamercolor{subsection in head/foot}{fg=cprimary,bg=cprimary!20} 151 | \setbeamercolor{institute in head/foot}{fg=white,bg=} 152 | \setbeamercolor{page number in head/foot}{fg=white,bg=} 153 | % \end{macrocode} 154 | % 155 | % Color patch for sidebar, shadow, and smoothtrees. 156 | % WARNING: This is a replica from outer theme, 157 | % just in case if you want to use color theme seperately. 158 | % But it is useless in the overall theming. 159 | % \begin{macrocode} 160 | \setbeamercolor{frametitle}{use=titlelike,bg=white,fg=titlelike.fg} 161 | \setbeamercolor{frametitle right}{parent=subsection in head/foot} 162 | % \end{macrocode} 163 | % 164 | % As is native to beamer, you could also use \verb"\alert" command 165 | % to highlight the text. The color is redirected to the cprimary. 166 | % \begin{macrocode} 167 | \setbeamercolor{alerted text}{fg=cprimary} 168 | % \end{macrocode} 169 | % 170 | % 171 | % \iffalse 172 | % 173 | % \fi 174 | % \Finale 175 | \endinput 176 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # SJTUBeamer 🤓 2 | 3 | [![TeXPage](https://img.shields.io/badge/SJTUBeamer-TeXPage-495A80)](https://www.texpage.com/template/c0decdfd-ca66-4f4a-807d-5217f729dcfa) 4 | [![Overleaf](https://img.shields.io/badge/SJTUBeamer-Overleaf-098842)](https://www.overleaf.com/latex/templates/sjtubeamer/dgvrnpndrtjh) 5 | [![discussions](https://img.shields.io/github/discussions/sjtug/SJTUBeamer)](https://github.com/sjtug/SJTUBeamer/discussions) 6 | [![Build](https://github.com/sjtug/SJTUBeamer/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/sjtug/SJTUBeamer/actions/workflows/build.yml) 7 | 8 | 欢迎使用 SJTUBeamer! 🥳 9 | 10 | SJTUBeamer 是上海交通大学的非官方 Beamer 模版。您可以使用 SJTUBeamer 制作幻灯片,展示您的成果。 11 | 12 | 这个仓库中包含 SJTUBeamer 所使用的宏包 `sjtubeamer`,以及一个示例文档。 13 | 14 | ## 快速上手 👋 15 | 16 | 目前的 `main.tex` 是一个示例文档《如何使用 LaTeX 排版论文》。您可以将里面的内容替换掉。下面是一个最简示例: 17 | 18 |
19 | 20 | 点击展开代码片段 21 | 22 | ```latex 23 | \documentclass[ 24 | % draft, % 草稿模式 25 | aspectratio=169, % 使用 16:9 比例 26 | ]{ctexbeamer} 27 | \mode 28 | 29 | \usetheme[min]{sjtubeamer} 30 | % 使用 maxplus/max/min 切换标题页样式 31 | % 使用 red/blue 切换主色调 32 | % 使用 light/dark 切换亮/暗色模式 33 | % 使用外样式关键词以获得不同的边栏样式 34 | % miniframes infolines sidebar 35 | % default smoothbars split 36 | % shadow tree smoothtree 37 | % 使用 topright/bottomright 切换徽标位置 38 | % 使用逗号分隔列表以同时使用多种选项 39 | 40 | % \tikzexternalize[prefix=build/] 41 | % 如果您需要缓存 tikz 图像,请取消注释上一行,并在编译选项中添加 -shell-escape。 42 | 43 | \usepackage[backend=biber,style=gb7714-2015]{biblatex} 44 | \addbibresource{thesis.bib} 45 | 46 | \institute[SJTUG]{上海交通大学 Linux 用户组} % 组织 47 | 48 | \title{SJTUBeamer 幻灯片模板} % 标题 49 | \subtitle{SJTUBeamer Template} % 副标题 50 | \author{SJTUG} % 作者 51 | \date{\today} % 日期 52 | 53 | \begin{document} 54 | 55 | \maketitle % 创建标题页 56 | 57 | \part{第一部分} 58 | 59 | % 使用节目录 60 | \AtBeginSection[]{ 61 | \begin{frame} 62 | % \tableofcontents[currentsection,hideallsubsections] % 传统节目录 63 | \sectionpage % 节页 64 | \end{frame} 65 | } 66 | 67 | \section{第 1 节} 68 | 69 | \begin{frame} 70 | \frametitle{标题} 71 | \paragraph{列表} 这个\alert{幻灯片}有下面几项: 72 | \begin{itemize} 73 | \item 第 1 项 74 | \item 第 2 项 75 | \item 第 3 项 76 | \end{itemize} 77 | \end{frame} 78 | 79 | \begin{frame} 80 | \frametitle{标题} 81 | \framesubtitle{子标题} 82 | \begin{equation} 83 | x^2+2x+1=(x+1)^2 84 | \end{equation} 85 | \end{frame} 86 | 87 | \section{第 2 节} 88 | \begin{frame} 89 | \frametitle{一些盒子} 90 | \begin{block}{盒子} 91 | 这是一个盒子\cite{thelegendofjiang} 92 | \end{block} 93 | \begin{alertblock}{注意} 94 | 注意内容 95 | \end{alertblock} 96 | \begin{exampleblock}{示例} 97 | 示例内容 98 | \end{exampleblock} 99 | \end{frame} 100 | 101 | \begin{frame}[fragile] % 注意添加 fragile 标记 102 | \frametitle{代码块} 103 | % 代码块参数:语言,标题 104 | % 请减少代码初始的缩进 105 | \begin{codeblock}[language=c++]{C++代码} 106 | #include 107 | 108 | int main(){ 109 | // Console Output 110 | std::cout << "Hello, SJTU!" << std::endl; 111 | return 0; 112 | } 113 | \end{codeblock} 114 | \end{frame} 115 | 116 | \part{参考文献} 117 | \begin{frame}[allowframebreaks] 118 | \printbibliography[heading=none] 119 | \end{frame} 120 | 121 | \makebottom % 创建结束页 122 | 123 | \end{document} 124 | ``` 125 | 126 |
127 | 128 | ## 使用方法 🧰 129 | 130 | 普通用户只需编辑 `main.tex` 即可开始使用。 131 | 132 | ### 模版下载与编译 133 | 134 | * TeXPage/Overleaf 135 | * 直接使用 [TeXPage 模板库链接](https://www.texpage.com/template/c0decdfd-ca66-4f4a-807d-5217f729dcfa)/[Overleaf 模板库链接](https://www.overleaf.com/latex/templates/sjtubeamer/dgvrnpndrtjh)。 136 | * 或者手动上传至 TeXPage/Overleaf 使用: 137 | * 下载开发版压缩包。页面右上角 Code - Download Zip 即可。 138 | * 或下载 [最新版](https://github.com/sjtug/SJTUBeamer/releases) 压缩包,点击 “Source Code (zip)” 即可下载。 139 | * 或下载 [最新版](https://github.com/sjtug/SJTUBeamer/releases) 最小依赖压缩包,点击 `sjtubeamer-online.zip` 下载。 140 | * 上传至 TeXPage/Overleaf。 141 | * TeXPage/Overleaf 的设置中需要选择“XeLaTeX”编译器编译。 142 | * 本地使用 143 | * 安装 TeXLive 套件。 144 | * 下载模板至本地: 145 | * 使用 git 克隆仓库 `git clone https://github.com/sjtug/SJTUBeamer/` 或 `git clone https://mirror.sjtu.edu.cn/git/SJTUBeamer.git/`。 146 | * 或下载开发版压缩包。页面右上角 Code - Download Zip 即可。 147 | * 或下载 [最新版](https://github.com/sjtug/SJTUBeamer/releases) 压缩包。点击 “Source Code (zip)” 即可下载。 148 | * 之后通过 `latexmk -xelatex main.tex` 命令进行编译即可。 149 | * VSCode 用户可以使用 LaTeX Workshop 中的 “Recipe: latexmk (latexmkrc)” 进行编译。 150 | 151 | 目前模版最新的稳定版是 v3.1.0。您可以在 [发布页](https://github.com/sjtug/SJTUBeamer/releases) 查看修改日志和更多资料。通常来说,SJTUBeamer 的一个稳定版本包括如下内容: 152 | 153 | * `sjtubeamerquickstart.pdf`:SJTUBeamer 快速入门,另见对应 [源代码](https://github.com/sjtug/SJTUBeamer/blob/main/src/doc/sjtubeamerquickstart.tex)。 154 | * `sjtubeamer.pdf`: **强烈推荐在使用前阅读一遍 👍👍👍** SJTUBeamer 用户文档。 155 | * `sjtubeamerdevguide.pdf`: SJTUBeamer 开发指南。 156 | * `sjtulib-talk-max-red.pdf`: 示例文档《如何使用 LaTeX 排版论文》的 `max,red` 主题版本。 157 | * `sjtulib-talk-maxplus-blue.pdf`: 示例文档《如何使用 LaTeX 排版论文》的 `maxplus,blue` 主题版本。 158 | * `sjtulib-talk-maxplus-red.pdf`: 示例文档《如何使用 LaTeX 排版论文》的 `maxplus,red` 主题版本。 159 | * `sjtulib-talk-min-red.pdf`: 示例文档《如何使用 LaTeX 排版论文》的 `min,red` 主题版本。 160 | * `sample-all-covers.pdf`: 所有配色主题的封面封底。 161 | * `sjtubeamer-ctan.zip`: 包含所有文档和样式的压缩包。 162 | * `sjtubeamer-online.zip`:包含插件与最小依赖,适合于在线平台使用。 163 | * SJTUBeamer 源代码。 164 | 165 | 请使用 Chrome 浏览器或 Adobe Acrobat 打开 SJTUBeamer 用户文档,以避免 PDF 兼容性导致的显示问题。 166 | 167 | ## 使用反馈与贡献代码 👷 168 | 169 | * 文件清单详见 [MANIFEST](src/MANIFEST.md)。 170 | * 在使用过程中,您可以在 [GitHub Discussions](https://github.com/sjtug/SJTUBeamer/discussions) 讨论区提问任何使用上的问题、交流想法。 171 | * 在开发过程中,您可以通过 [GitHub Issues](https://github.com/sjtug/SJTUBeamer/issues) 提供 SJTUBeamer 的 Bug 反馈和新功能提案。同时,也欢迎您直接提交 [Pull Request](https://github.com/sjtug/SJTUBeamer/pulls) 代码修改帮助我们改进。 172 | * 所有对模版的修改应该在 `.dtx` 文件中进行,而后用 l3build 生成 sty 文件。 173 | * 您可以阅读发布页面中的《SJTUBeamer 开发指南》`sjtubeamerdevguide.pdf` 了解模版的实现细节与编译方法。 174 | 175 | 整个开发流程如下: 176 | 177 | * 修改 `.dtx` 文件。 178 | * 运行 `make generate` 将生成的 sty 文件拷贝到根目录下。 179 | * 更新 `main.tex`,运行 `make build` 查看模版修改后的效果。 180 | * 更新开发文档,运行 `make build-dev` 编译所有开发文档,运行单元测试。 181 | * (可选)运行 `make format-dev` 格式化所有文件。 182 | * 发 PR。 183 | 184 | 新贡献者可以将自己的信息加入 `src/doc/sjtubeamerdevguide.tex` 的 `Developer` 章节。 185 | 186 | ## 展示 🧐 187 | 188 | 详细展示见 [样式一览](https://github.com/sjtug/SJTUBeamer/discussions/138)。 189 | 190 | 191 | 192 | Red Cover 193 | 194 | 195 | 196 | 197 | Blue Cover 198 | 199 | 200 | ## 许可证 201 | 202 | SJTUBeamer 仓库同时包含 SJTUBeamer 包和一个示例文档。其中内容的许可证各不相同。您可以阅读各个文件的开头部分,了解该文件所使用的许可证。 203 | 204 | * SJTUBeamer 包使用的许可证为 Apache-2.0。 205 | * SJTUBeamer 示例文档使用 CC-BY-SA 4.0 许可。 206 | * sjtuvi 和 sjtucover 库及其附属徽标、图片由上海交通大学持有版权。校属各单位及个人以经营为目的使用视觉形象识别系统,须向学校申请使用许可。校外单位及个人未经许可,不得制作或使用载有视觉形象识别系统的物品。您可以在 [vi.sjtu.edu.cn](https://vi.sjtu.edu.cn/index.php/articles/bulletin/16) 阅读许可协议。 207 | -------------------------------------------------------------------------------- /contrib/poster/sjtubeamerthemeposter.ltx: -------------------------------------------------------------------------------- 1 | %% ------------------------------------------------------------------------ 2 | %% Copyright (C) 2022-2024 LogCreative 3 | %% 4 | %% Licensed under the Apache License, Version 2.0 (the "License"); 5 | %% you may not use this file except in compliance with the License. 6 | %% You may obtain a copy of the License at 7 | %% 8 | %% http://www.apache.org/licenses/LICENSE-2.0 9 | %% 10 | %% Unless required by applicable law or agreed to in writing, software 11 | %% distributed under the License is distributed on an "AS IS" BASIS, 12 | %% WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | %% See the License for the specific language governing permissions and 14 | %% limitations under the License. 15 | %% ------------------------------------------------------------------------ 16 | % 设置文件元数据 17 | \ProvidesFile{sjtubeamerthemeposter.ltx}[2022/10/18 Beamerposter adapter for SJTUBeamer] 18 | \PassOptionsToPackage{orientation=portrait}{beamerposter} 19 | \if\EqualOption{poster}{landscape}{true} 20 | \PassOptionsToPackage{orientation=landscape}{beamerposter} 21 | \fi 22 | % 加载 beamerposter 23 | \usepackage[size=a0,scale=1.4]{beamerposter} 24 | % 设置 headline 颜色跟随亮色/暗色 25 | \setbeamercolor{headline}{parent=palette primary} 26 | \AtBeginDocument{ 27 | \newsavebox{\maintitle} % 标题盒子变量 28 | \newlength{\titlebottom} % 标题盒子的高度 29 | % 修改 headline,需要在文档起始处覆盖,防止 default 的行为 30 | \setbeamertemplate{headline}{ 31 | \begin{beamercolorbox}[wd=\paperwidth,sep=0.02\paperwidth]{headline} 32 | \begin{columns} 33 | \begin{column}{0.25\textwidth} 34 | \hspace*{0.02\paperwidth} 35 | \if\EqualOption{poster}{sepinst}{true}% 36 | \resizebox{!}{4cm}{\vphantom{-}\usebeamertemplate{logo}} 37 | \else% 38 | \if\EqualOption{inner}{lang}{en}% 39 | \resizebox{!}{4cm}{\vphantom{-}\secondaryinstlogo{\csname beamer@shortinstitute\endcsname}{\usebeamertemplate{logo}}} 40 | \else% 41 | \resizebox{!}{4cm}{\vphantom{-}\secondaryinstlogo[\insertshortinstitute]{\insertinstitute}{\usebeamertemplate{logo}}} 42 | \fi% 43 | \fi% 44 | \end{column} 45 | \savebox{\maintitle}{% 46 | \begin{column}{0.5\textwidth} 47 | \vfill 48 | \centering 49 | \usebeamercolor{title in headline}{% 50 | \color{fg}\textbf{\LARGE{\inserttitle}}\vskip2.5ex% 51 | } 52 | \usebeamercolor{author in headline}{% 53 | \color{fg}\large{\insertauthor}% 54 | } 55 | \vfill 56 | \end{column} 57 | } 58 | \usebox{\maintitle} 59 | \begin{column}{0.25\textwidth} 60 | \if\EqualOption{poster}{sepinst}{true} 61 | \hfill 62 | \if\EqualOption{inner}{lang}{en} 63 | \resizebox{!}{4cm}{\vphantom{-}\secondaryinstlogo{\csname beamer@shortinstitute\endcsname}{}} 64 | \else 65 | \resizebox{!}{4cm}{\vphantom{-}\secondaryinstlogo[\insertshortinstitute]{\insertinstitute}{}} 66 | \fi 67 | \hspace*{0.03\paperwidth} 68 | \fi 69 | \end{column} 70 | \end{columns} 71 | \if\EqualOption{poster}{sepinst}{true}\else 72 | \begin{tikzpicture}[overlay, remember picture] 73 | \def\stampsize{60pt} 74 | \if\EqualOption{poster}{landscape}{true} 75 | \def\stampheight{0.08} 76 | \else 77 | \def\stampheight{0.05} 78 | \fi 79 | \usebeamercolor{palette primary} 80 | \setlength{\titlebottom}{\dimexpr\ht\maintitle-0.02\paperwidth\relax} 81 | \stamparray{\stampsize}{(0.75\paperwidth,0.2\paperwidth)}{(\paperwidth,\titlebottom)} 82 | \fill[bg, path fading=fade right] (0.75\paperwidth,0.2\paperwidth) rectangle (1.35\paperwidth, \titlebottom); 83 | \end{tikzpicture} 84 | \fi 85 | \end{beamercolorbox} 86 | } 87 | } 88 | % 新的命令 设置底栏 \footline[左脚注]{右脚注} 89 | \newif\ifposterfootline 90 | \def\posterrightfootline{} 91 | \def\posterleftfootline{} 92 | \providecommand{\footline}[2][]{ 93 | \def\posterleftfootline{#1} 94 | \def\posterrightfootline{#2} 95 | } 96 | % 底栏为空时不会出现 97 | \setbeamercolor{footline}{parent=palette primary} 98 | \setbeamertemplate{footline}{% 99 | \resizebox{\paperwidth}{!}{\sjtugate[cprimary]}% 100 | \if\EqualOption{poster}{landscape}{true}% 101 | \vskip-12cm% 102 | \else% 103 | \vskip-6cm% 104 | \fi\par 105 | \posterfootlinetrue 106 | \ifx\posterleftfootline\relax 107 | \ifx\posterrightfootline\relax 108 | \posterfootlinefalse 109 | \fi 110 | \fi 111 | \ifposterfootline 112 | \begin{beamercolorbox}[wd=\paperwidth]{footline} 113 | \small\vskip1.5ex\hspace*{0.02\paperwidth}\posterleftfootline\hfill 114 | \posterrightfootline\hspace*{0.02\paperwidth}\vskip3ex 115 | \end{beamercolorbox} 116 | \fi 117 | } 118 | % 重置区块间隙 119 | \setbeamertemplate{block begin}{ 120 | \vskip.75ex 121 | \begin{beamercolorbox}[colsep*=.75ex]{block title}% 122 | \usebeamerfont*{block title}\insertblocktitle 123 | \end{beamercolorbox}% 124 | {\ifbeamercolorempty[bg]{block body}{}{\nointerlineskip\vskip-0.5pt}}% 125 | \usebeamerfont{block body}% 126 | \begin{beamercolorbox}[colsep*=.75ex,vmode]{block body}% 127 | \ifbeamercolorempty[bg]{block body}{\vskip-.25ex}{\vskip-.75ex}\vbox{}% 128 | } 129 | \setbeamertemplate{block end}{ 130 | \end{beamercolorbox} 131 | } 132 | \setbeamertemplate{block alerted begin}{ 133 | \vskip.75ex 134 | \begin{beamercolorbox}[colsep*=.75ex]{block title alerted}% 135 | \usebeamerfont*{block title}\insertblocktitle 136 | \end{beamercolorbox}% 137 | {\ifbeamercolorempty[bg]{block body}{}{\nointerlineskip\vskip-0.5pt}}% 138 | \usebeamerfont{block body}% 139 | \begin{beamercolorbox}[colsep*=.75ex,vmode]{block body alerted}% 140 | \ifbeamercolorempty[bg]{block body}{\vskip-.25ex}{\vskip-.75ex}\vbox{}% 141 | } 142 | \setbeamertemplate{block alerted end}{ 143 | \end{beamercolorbox} 144 | } 145 | \setbeamertemplate{block example begin}{ 146 | \vskip.75ex 147 | \begin{beamercolorbox}[colsep*=.75ex]{block title example}% 148 | \usebeamerfont*{block title}\insertblocktitle 149 | \end{beamercolorbox}% 150 | {\ifbeamercolorempty[bg]{block body}{}{\nointerlineskip\vskip-0.5pt}}% 151 | \usebeamerfont{block body}% 152 | \begin{beamercolorbox}[colsep*=.75ex,vmode]{block body example}% 153 | \ifbeamercolorempty[bg]{block body}{\vskip-.25ex}{\vskip-.75ex}\vbox{}% 154 | } 155 | \setbeamertemplate{block example end}{ 156 | \end{beamercolorbox} 157 | } 158 | % 在正文环境内(不包含小栏) 159 | % 需要使用 \posterstamphrule[cprimary] 插入较短的分割线。 160 | % 该分割线自带两边 2ex 的纵向间距。 161 | \newcommand{\posterstamphrule}[1][cprimary]{% 162 | \vskip2ex% 163 | \vskip-0.5\baselineskip% 164 | \begin{minipage}{0.94\textwidth}% 165 | \leavevmode% 166 | \stamphrule[#1]% 167 | \end{minipage}% 168 | \vskip2ex% 169 | } 170 | % tcolorbox 设定 171 | \tcbset{toptitle=2.5mm,bottomtitle=2.5mm} 172 | \if\EqualOption{poster}{noindent}{true}\else% 173 | % 首行缩进 174 | \setlength{\parindent}{2em}% 175 | % 重定义 stampblock 的首行缩进 176 | \addtobeamertemplate{block stamp begin}{}{% 177 | \setlength{\parindent}{2em}% 178 | } 179 | % 重定义 block 的缩进 180 | \addtobeamertemplate{block begin}{}{% 181 | \setlength{\parindent}{2em}% 182 | } 183 | \addtobeamertemplate{block alerted begin}{}{% 184 | \setlength{\parindent}{2em}% 185 | } 186 | \addtobeamertemplate{block example begin}{}{% 187 | \setlength{\parindent}{2em}% 188 | } 189 | \fi% 190 | % 重设引用条目同名图标大小 191 | \pgfdeclareimage[height=26pt]{beamericonbook}{beamericonbook} 192 | \pgfdeclareimage[height=26pt]{beamericonbookshaded}{beamericonbook.20} 193 | \pgfdeclareimage[height=34pt]{beamericonarticle}{beamericonarticle} 194 | \pgfdeclareimage[height=34pt]{beamericonarticleshaded}{beamericonarticle.20} 195 | \pgfdeclareimage[height=32pt]{beamericononline}{beamericononline} 196 | \pgfdeclareimage[height=32pt]{beamericononlineshaded}{beamericononline.20} 197 | % 为了防止无法悬挂对齐的情形,直接使用 text 模式的 bibliography item 198 | % 可以改为正常的 article, book, online 等。 199 | % 注意!如果使用 gb7714-2015ay 样式,请手动删除本行。 200 | \setbeamertemplate{bibliography item}[text] -------------------------------------------------------------------------------- /src/MANIFEST.md: -------------------------------------------------------------------------------- 1 | # Manifest for sjtubeamer 2 | 3 | This file is a listing of all files considered to be part of this package. 4 | It is automatically generated with `l3build manifest`. 5 | 6 | 7 | ## Minimal manifest 8 | 9 | The following group lists all the necessary files that required by the runtime. 10 | You could install these files to your TeX distribution or distribute them with 11 | your main document. 12 | ### Minimal workset 13 | 14 | * vi/ 15 | * beamercolorthemesjtubeamer.sty 16 | * beamerfontthemesjtubeamer.sty 17 | * beamerinnerthemesjtubeamer.sty 18 | * beamerouterthemesjtubeamer.sty 19 | * beamerthemesjtubeamer.sty 20 | * sjtucover.sty 21 | * sjtuvi.sty 22 | 23 | 24 | ## Repository manifest 25 | 26 | The following groups list the files included in the development repository of the package. 27 | Files listed with a ‘†’ marker are included in the TDS but not CTAN files, and files listed 28 | with ‘‡’ are included in both. 29 | 30 | ### Source files 31 | 32 | These are source files for a number of purposes, including the `unpack` process which 33 | generates the installation files of the package. Additional files included here will also 34 | be installed for processing such as testing. 35 | 36 | | File | Flag | Description | 37 | | --- | --- | --- | 38 | | beamerthemesjtubeamer.ins | ‡ | | 39 | | beamercolorthemesjtubeamer.dtx | ‡ | sjtubeamer color theme | 40 | | beamerfontthemesjtubeamer.dtx | ‡ | sjtubeamer font theme | 41 | | beamerinnerthemesjtubeamer.dtx | ‡ | sjtubeamer inner theme | 42 | | beamerouterthemesjtubeamer.dtx | ‡ | sjtubeamer outer theme | 43 | | beamerthemesjtubeamer.dtx | ‡ | sjtubeamer parent theme | 44 | | sjtucover.dtx | ‡ | cover library for sjtubeamer | 45 | | sjtuvi.dtx | ‡ | Visual Identity System library for sjtubeamer | 46 | 47 | ### Typeset documentation source files 48 | 49 | These files are typeset using LaTeX to produce the PDF documentation for the package. 50 | 51 | | File | Flag | Description | 52 | | --- | --- | --- | 53 | | sjtubeamer.tex | ‡ | User Manual for sjtubeamer (Chinese) | 54 | | sjtubeamerdevguide.tex | ‡ | Development Guide for sjtubeamer (English) | 55 | | sjtubeamerquickstart.tex | ‡ | Quick Start for sjtubeamer (Chinese) | 56 | 57 | ### Derived files 58 | 59 | **Installation (1/2)** The files created by ‘unpacking’ the package sources. This typically includes 60 | `.sty` and `.cls` files created from DocStrip `.dtx` files. 61 | 62 | * beamercolorthemesjtubeamer.sty † 63 | * beamerfontthemesjtubeamer.sty † 64 | * beamerinnerthemesjtubeamer.sty † 65 | * beamerouterthemesjtubeamer.sty † 66 | * beamerthemesjtubeamer.sty † 67 | * sjtucover.sty † 68 | * sjtuvi.sty † 69 | 70 | ### Graphics resources 71 | 72 | **Installation (2/2)** These files are in `vi/` directory ‡. To provide the basic 73 | graphics resources for creating presentations. 74 | 75 | * sjtu-vi-dlogo.pdf 76 | * sjtu-vi-enlogo.pdf 77 | * sjtu-vi-sjtubadge.pdf 78 | * sjtu-vi-sjtubg.png 79 | * sjtu-vi-sjtugate.png 80 | * sjtu-vi-sjtuphoto.jpg 81 | * sjtu-vi-vlogo.pdf 82 | * sjtu-vi-zhlogo.pdf 83 | 84 | ### Typeset documents 85 | 86 | The output files (PDF, essentially) from typesetting the various source, demo, 87 | etc., package files. 88 | 89 | * sjtubeamer.pdf ‡ 90 | * sjtubeamerdevguide.pdf ‡ 91 | * sjtubeamerquickstart.pdf ‡ 92 | 93 | ### Test files 94 | 95 | **Regression Tests** 96 | These files form the test suite for the package. `.lvt` or `.lte` files are the individual 97 | unit tests, and `.tlg` are the stored output for ensuring changes to the package produce 98 | the same output. These output files are sometimes shared and sometime specific for 99 | different engines (pdfTeX, XeTeX, LuaTeX, etc.). 100 | 101 | * color.lvt 102 | * font.lvt 103 | * inner.lvt 104 | * outer.lvt 105 | * sjtuvi.lvt 106 | * color.tlg 107 | * font.tlg 108 | * inner.tlg 109 | * outer.tlg 110 | * sjtuvi.tlg 111 | 112 | ### Tutorial files 113 | 114 | **Unit Tests** 115 | Files included to demonstrate package functionality. And they are also the demo files for the user guide. 116 | These files will be typesetted first before typesetting the documentation source files. 117 | They could be cached in the next round by `l3build cache-demo`. 118 | The cache could be cleaned by `l3build clean-demo`. 119 | To add a demo file, use `l3build add-demo 20`. 120 | 121 | * step0.tex 122 | * step1.tex 123 | * step10.tex 124 | * step11.tex 125 | * step12.tex 126 | * step13.tex 127 | * step14.tex 128 | * step15.tex 129 | * step16+-.tex 130 | * step17+_.tex 131 | * step18+-.tex 132 | * step19.tex 133 | * step2.tex 134 | * step20.tex 135 | * step21.tex 136 | * step22.tex 137 | * step23.tex 138 | * step24.tex 139 | * step25.tex 140 | * step2bd.tex 141 | * step2bl.tex 142 | * step2default.tex 143 | * step2infolines.tex 144 | * step2miniframes.tex 145 | * step2shadow.tex 146 | * step2sidebar.tex 147 | * step2smoothbars.tex 148 | * step2smoothtree.tex 149 | * step2split.tex 150 | * step2tb.tex 151 | * step2tree.tex 152 | * step3.tex 153 | * step4.tex 154 | * step5.tex 155 | * step6+.tex 156 | * step7+.tex 157 | * step7s.tex 158 | * step8+.tex 159 | * step9+.tex 160 | * stepalgo.tex 161 | * stepalgorithm.tex 162 | * stepdual.tex 163 | 164 | 165 | ## TDS manifest 166 | 167 | The following groups list the files included in the TeX Directory Structure used to install 168 | the package into a TeX distribution. 169 | 170 | ### Source files (TDS) 171 | 172 | All files included in the `sjtubeamer/source` directory. 173 | 174 | * beamercolorthemesjtubeamer.dtx 175 | * beamerfontthemesjtubeamer.dtx 176 | * beamerinnerthemesjtubeamer.dtx 177 | * beamerouterthemesjtubeamer.dtx 178 | * beamerthemesjtubeamer.dtx 179 | * beamerthemesjtubeamer.ins 180 | * sjtucover.dtx 181 | * sjtuvi.dtx 182 | 183 | ### TeX files (TDS) 184 | 185 | All files included in the `sjtubeamer/tex` directory. This directory contains all the files in the **Minimal workset**. 186 | 187 | * vi/ 188 | * beamercolorthemesjtubeamer.sty 189 | * beamerfontthemesjtubeamer.sty 190 | * beamerinnerthemesjtubeamer.sty 191 | * beamerouterthemesjtubeamer.sty 192 | * beamerthemesjtubeamer.sty 193 | * sjtucover.sty 194 | * sjtuvi.sty 195 | 196 | ### Doc files (TDS) 197 | 198 | All files included in the `sjtubeamer/doc` directory. 199 | 200 | * MANIFEST.md 201 | * ref.bib 202 | * sjtubeamer.pdf 203 | * sjtubeamer.tex 204 | * sjtubeamerdevguide.pdf 205 | * sjtubeamerdevguide.tex 206 | * sjtubeamerquickstart.pdf 207 | * sjtubeamerquickstart.tex 208 | 209 | 210 | ## CTAN manifest 211 | 212 | The following group lists the files included in the CTAN package. 213 | 214 | ### CTAN files 215 | 216 | * vi/ 217 | * MANIFEST.md 218 | * beamercolorthemesjtubeamer.dtx 219 | * beamerfontthemesjtubeamer.dtx 220 | * beamerinnerthemesjtubeamer.dtx 221 | * beamerouterthemesjtubeamer.dtx 222 | * beamerthemesjtubeamer.dtx 223 | * beamerthemesjtubeamer.ins 224 | * ref.bib 225 | * sjtubeamer.pdf 226 | * sjtubeamer.tex 227 | * sjtubeamerdevguide.pdf 228 | * sjtubeamerdevguide.tex 229 | * sjtubeamerquickstart.pdf 230 | * sjtubeamerquickstart.tex 231 | * sjtucover.dtx 232 | * sjtuvi.dtx 233 | 234 | 235 | ## Online manifest 236 | 237 | The following group lists the files included in the online distribution. 238 | You could upload the package to any online plateforms. Compared with 239 | **Minimal workset**, this distribution comes with all the plugins and 240 | quick start guide as the main file. 241 | You could generate the package by going to the root directory and 242 | using the command `make build-online` in the terminal. 243 | 244 | ### Online files 245 | 246 | * contrib/ 247 | * build/ 248 | * vi/ 249 | * beamercolorthemesjtubeamer.sty 250 | * beamerfontthemesjtubeamer.sty 251 | * beamerinnerthemesjtubeamer.sty 252 | * beamerouterthemesjtubeamer.sty 253 | * beamerthemesjtubeamer.sty 254 | * ref.bib 255 | * sjtubeamerquickstart.tex 256 | * sjtucover.sty 257 | * sjtuvi.sty 258 | -------------------------------------------------------------------------------- /README_en.md: -------------------------------------------------------------------------------- 1 | # SJTUBeamer 🤓 2 | 3 | [![Overleaf](https://img.shields.io/badge/SJTUBeamer-Overleaf-098842)](https://www.overleaf.com/latex/templates/sjtubeamer/dgvrnpndrtjh) 4 | [![TeXPage](https://img.shields.io/badge/SJTUBeamer-TeXPage-495A80)](https://www.texpage.com/template/c0decdfd-ca66-4f4a-807d-5217f729dcfa) 5 | [![discussions](https://img.shields.io/github/discussions/sjtug/SJTUBeamer)](https://github.com/sjtug/SJTUBeamer/discussions) 6 | [![Build](https://github.com/sjtug/SJTUBeamer/actions/workflows/build.yml/badge.svg?branch=main)](https://github.com/sjtug/SJTUBeamer/actions/workflows/build.yml) 7 | 8 | Welcome! 🥳 9 | 10 | This is the beamer template exclusively for Shanghai Jiaotong University students to give a speech on group meeting or course project. 11 | 12 | ## Starting Up 👋 13 | 14 | Current document `main.tex` is an example documentation of *How to Use LaTeX to Typeset Thesis*. You could replace the content with the following minimum working example: 15 | 16 |
17 | 18 | Expand to show the code block 19 | 20 | ```latex 21 | \documentclass[ 22 | % draft, % draft mode 23 | aspectratio=169, % use 16:9 ratio 24 | ]{beamer} 25 | \mode 26 | 27 | \usetheme[maxplus]{sjtubeamer} 28 | % use maxplus/max/min to change covers. 29 | % use red/blue to change main color. 30 | % use light/dark to change dominate color. 31 | % use the following keywords to make different navigations: 32 | % miniframes infolines sidebar 33 | % default smoothbars split 34 | % shadow tree smoothtree 35 | % use topright/bottomright to change the position of the logo. 36 | % use comma seperated list to use multiple options at the same time. 37 | 38 | % \tikzexternalize[prefix=build/] 39 | % To cache the tikz picture, please uncomment the previous line. 40 | 41 | \usepackage{biblatex} 42 | \addbibresource{thesis.bib} 43 | 44 | \institute{SJTUG} 45 | 46 | \title{SJTUBeamer} 47 | \subtitle{A Beamer Template} 48 | \author{SJTUG} 49 | \date{\today} 50 | 51 | \begin{document} 52 | 53 | \maketitle 54 | 55 | \part{Intro} 56 | 57 | \AtBeginSection[]{ 58 | \begin{frame}[plain] 59 | \sectionpage 60 | \end{frame} 61 | } 62 | 63 | \section{Basics} 64 | 65 | \begin{frame} 66 | \frametitle{Title} 67 | \paragraph{List} This \alert{slide} contains the following items: 68 | \begin{itemize} 69 | \item Item 1 70 | \item Item 2 71 | \item Item 3 72 | \end{itemize} 73 | \end{frame} 74 | 75 | \begin{frame} 76 | \frametitle{Title} 77 | \framesubtitle{Subtitle} 78 | \begin{equation} 79 | x^2+2x+1=(x+1)^2 80 | \end{equation} 81 | \end{frame} 82 | 83 | \section{Blocks} 84 | \begin{frame} 85 | \frametitle{Some boxes} 86 | \begin{block}{block} 87 | This is a box. 88 | % \cite{} 89 | \end{block} 90 | \begin{alertblock}{alertblock} 91 | Text. 92 | \end{alertblock} 93 | \begin{exampleblock}{exampleblock} 94 | Text. 95 | \end{exampleblock} 96 | \end{frame} 97 | 98 | \begin{frame}[fragile] % fragile 99 | \frametitle{codeblock} 100 | \begin{codeblock}[language=c++]{C++ Code} 101 | #include 102 | 103 | int main(){ 104 | // Console Output 105 | std::cout << "Hello, SJTU!" << std::endl; 106 | return 0; 107 | } 108 | \end{codeblock} 109 | \end{frame} 110 | 111 | \part{Bibliography} 112 | \begin{frame}[allowframebreaks] 113 | \printbibliography[heading=none] 114 | \end{frame} 115 | 116 | \makebottom % create the bottom page 117 | 118 | \end{document} 119 | ``` 120 | 121 |
122 | 123 | ## Usage 🧰 124 | 125 | Edit `main.tex` and start to use. 126 | 127 | ### Template Download & Compilation 128 | 129 | * Overleaf/TeXPage 130 | * You could use the [Overleaf Template Gallery link](https://www.overleaf.com/latex/templates/sjtubeamer/dgvrnpndrtjh)/[TeXPage Template Gallery link](https://www.texpage.com/template/c0decdfd-ca66-4f4a-807d-5217f729dcfa). 131 | * Or upload to Overleaf/TeXPage manually: 132 | * Download the development version by clicking "Code - Download Zip". 133 | * Or download [the latest version](https://github.com/sjtug/SJTUBeamer/releases). Click "Source Code (zip)" to download. 134 | * Or download [the latest version](https://github.com/sjtug/SJTUBeamer/releases). Click `sjtubeamer-online` to download the minimal workset. 135 | * Upload to Overleaf/TeXPage. 136 | * Set to "XeLaTeX" for compilation. 137 | * Local Use 138 | * Install TeXLive. 139 | * Download the template to your local machine: 140 | * Run `git clone https://github.com/sjtug/SJTUBeamer/` or `git clone https://mirror.sjtu.edu.cn/git/SJTUBeamer.git/`. 141 | * Or download the development version by clicking "Code - Download Zip". 142 | * Or download [the latest version](https://github.com/sjtug/SJTUBeamer/releases). Click "Source Code (zip)" to download. 143 | * Run `latexmk -xelatex main.tex` to compile 144 | * VSCode LaTeX Workshop: use “Recipe: latexmk (latexmkrc)” to compile 145 | 146 | The current stable version is v3.1.0。You could visit [the release page](https://github.com/sjtug/SJTUBeamer/releases) for the changelog and more details. Generally speaking, a release of SJTUBeamer has the following content: 147 | 148 | * `sjtubeamerquickstart.pdf`:SJTUBeamer Quick Start. You could also read the [source code](https://github.com/sjtug/SJTUBeamer/blob/main/src/doc/sjtubeamerquickstart.tex) of the document. 149 | * `sjtubeamer.pdf`: SJTUBeamer User Guide. 150 | * `sjtubeamerdevguide.pdf`: SJTUBeamer Development Guide. 151 | * `sjtulib-talk-max-red.pdf`: `max,red` version of `main.tex`. 152 | * `sjtulib-talk-maxplus-blue.pdf`: `maxplus,blue` version of `main.tex`. 153 | * `sjtulib-talk-maxplus-red.pdf`: `maxplus,red` version of `main.tex`. 154 | * `sjtulib-talk-min-red.pdf`: `min,red` version of `main.tex`. 155 | * `sample-all-covers.pdf`: all covers (title page and bottom page). 156 | * `sjtubeamer-ctan.zip`: the installation package. 157 | * `sjtubeamer-online.zip`: the minimal workset suitable for online platforms. 158 | * SJTUBeamer source code. 159 | 160 | Please use Chrome browser or Adobe Acrobat to open user guide, otherwise there could be display issues. 161 | 162 | ## Feedback & Contribution 👷 163 | 164 | * You could get the repository manifest in [MANIFEST](src/MANIFEST.md). 165 | * For regular users, feel free to ask questions and share ideas in [GitHub Discussions](https://github.com/sjtug/SJTUBeamer/discussions). 166 | * For developers, Feel free to file an issue with [GitHub Issues](https://github.com/sjtug/SJTUBeamer/issues) to submit a bug report or a feature request. At the same time, [PRs](https://github.com/sjtug/SJTUBeamer/pulls) are always welcomed for direct code changes. 167 | * The source code should be modified in `.dtx` files. Then use l3build to generate sty files. 168 | * You could get more implementation details in `sjtubeamerdevguide.pdf`. 169 | 170 | The development process is as follows: 171 | 172 | * Modify `.dtx` files. 173 | * Run `make generate` and copy the style file to the root. 174 | * Update `main.tex`, and run `make build` for previewing modification. 175 | * Update dev guide, and run `make build-dev` ro compile the doc and run tests. 176 | * (Optional) Run `make format-dev` to format all the files. 177 | * Submit a Pull Request. 178 | 179 | New contributors could add your name to the developer list in `sjtubeamerdevguide.tex`. 180 | 181 | ## Appearance 🧐 182 | 183 | You could get more details in [the discussion post](https://github.com/sjtug/SJTUBeamer/discussions/138). 184 | 185 | 186 | 187 | Red Cover 188 | 189 | 190 | 191 | 192 | Blue Cover 193 | 194 | 195 | ## License 196 | 197 | 198 | * SJTUBeamer is licensed under Apache-2.0. 199 | * SJTUBeamer is licensed under CC-BY-SA 4.0. 200 | * sjtuvi and sjtucover library and related graphics is under [No commercial](https://vi.sjtu.edu.cn/index.php/articles/bulletin/16). 201 | -------------------------------------------------------------------------------- /contents/thesis.tex: -------------------------------------------------------------------------------- 1 | % !TeX encoding = UTF-8 2 | % !TeX root = ../main.tex 3 | 4 | %% ------------------------------------------------------------------------ 5 | %% Copyright (C) 2021-2023 SJTUG 6 | %% 7 | %% SJTUBeamer Example Document by SJTUG 8 | %% 9 | %% SJTUBeamer Example Document is licensed under a 10 | %% Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International License. 11 | %% 12 | %% You should have received a copy of the license along with this 13 | %% work. If not, see . 14 | %% ----------------------------------------------------------------------- 15 | 16 | \section{学位论文排版} 17 | \subsection{\SJTUThesis 上海交通大学学位论文模板} 18 | 19 | \begin{frame}{\SJTUThesis} 20 | \framesubtitle{上海交通大学学位论文 \LaTeX{} 模板} 21 | \begin{columns} 22 | \begin{column}{.7\textwidth} 23 | \begin{itemize} 24 | \item 最早由韦建文于 2009 年 11 月发布 0.1a 版,2018 年起由 SJTUG 接手维护 25 | \item 最新版:\SJTUThesisVersion{} (\SJTUThesisDate) 26 | \item 支持本科、硕士、博士学位论文以及课程论文的排版 27 | \end{itemize} 28 | \end{column} 29 | \begin{column}{.2\textwidth} 30 | \begin{figure}[htbp] 31 | \centering 32 | { 33 | \setlength{\fboxsep}{0pt} 34 | \fcolorbox{black}{white}{\includegraphics[height=.5\textheight]{sjtuthesis-cover.pdf}} 35 | } 36 | \end{figure} 37 | \end{column} 38 | \end{columns} 39 | \end{frame} 40 | 41 | \begin{frame}[fragile]{获取\SJTUThesis{}} 42 | \begin{columns} 43 | \begin{column}{.65\textwidth} 44 | \begin{itemize} 45 | \item 下载最新版(推荐) 46 | \begin{itemize} 47 | \item GitHub Releases \link{https://github.com/sjtug/SJTUThesis/releases} 48 | \item OverLeaf 49 | \link{https://www.overleaf.com/latex/templates/sjtuthesis-latex-thesis-template-for-shanghai-jiao-tong-university/mkdwbyjbtfgg?r=b3b31f49&rm=d&rs=b} 50 | \end{itemize} 51 | \item 下载最新开发版(高级 / 想尝鲜 / 着急的用户) 52 | \begin{itemize} 53 | \item \url{https://github.com/sjtug/SJTUThesis} 54 | \item 点右边栏 55 | \href{https://github.com/sjtug/SJTUThesis/archive/dev.zip}{Download ZIP} 按钮 56 | \end{itemize} 57 | \item 编译 58 | \begin{itemize} 59 | \item 解压缩看文档 \verb|README.md| 60 | \item Windows: 双击 \verb|Compile.bat| 脚本编译 61 | \item Linux \& macOS: 使用 \verb|Makefile| 62 | \item 使用 \verb|latexmk -xelatex main| 63 | \end{itemize} 64 | \end{itemize} 65 | \end{column} 66 | \begin{column}{.25\textwidth} 67 | \begin{figure}[htbp] 68 | \centering 69 | \includegraphics[width=\textwidth]{sjtuthesis-download.png} 70 | \end{figure} 71 | \vfill 72 | \end{column} 73 | \end{columns} 74 | \end{frame} 75 | 76 | \begin{frame}[fragile]{模板选项} 77 | \begin{description} 78 | \item[type] 指定论文类型(本科/硕士/博士) 79 | \begin{lstlisting}[basicstyle=\ttfamily] 80 | \documentclass[type=bachelor]{sjtuthesis} 81 | \end{lstlisting} 82 | \item[review] 开启盲审模式 83 | \begin{lstlisting}[basicstyle=\ttfamily] 84 | \documentclass[type=master,review]{sjtuthesis} 85 | \end{lstlisting} 86 | \item[fontset] 指定字体(推荐使用 \verb|windows|) 87 | \begin{lstlisting}[basicstyle=\ttfamily] 88 | \documentclass[type=doctor,fontset=windows]{sjtuthesis} 89 | \end{lstlisting} 90 | \end{description} 91 | \end{frame} 92 | 93 | \begin{frame}[fragile]{模板设置} 94 | 使用 \verb|\sjtusetup| 命令指定论文各类设置: 95 | \begin{lstlisting} 96 | \sjtusetup{ 97 | info = { 98 | zh/title = {上海交通大学学位论文 \LaTeX{} 模板示例文档}, 99 | en/title = {A Sample for \LaTeX-based SJTU Thesis Template}, 100 | zh/author = {某\quad{}某}, 101 | en/author = {Mo Mo}, 102 | }, 103 | style = { 104 | title-logo-color = red, 105 | }, 106 | name = { 107 | achv = {攻读学位期间完成的论文}, 108 | }, 109 | } 110 | \end{lstlisting} 111 | \end{frame} 112 | 113 | \begin{frame}[fragile]{信息录入} 114 | \verb|info| 域完成论文基本信息录入 115 | \begin{table}[h] 116 | \centering 117 | \footnotesize 118 | \begin{tabular}{lll} \toprule 119 | 命令作用 & 中文对应选项 & 英文对应选项 \\ \midrule 120 | 论文标题 & \texttt{zh/title} & \texttt{en/title} \\ 121 | 关键字列表 & \texttt{zh/keywords} & \texttt{en/keywords} \\ 122 | 作者姓名 & \texttt{zh/author} & \texttt{en/author} \\ 123 | 申请学位名称 & \texttt{zh/degree} & \texttt{en/degree} \\ 124 | 院系名称 & \texttt{zh/department} & \texttt{en/department} \\ 125 | 专业名称 & \texttt{zh/major} & \texttt{en/major} \\ 126 | 导师 & \texttt{zh/supervisor} & \texttt{en/supervisor} \\ 127 | 副导师 & \texttt{zh/assoc-supervisor} & \texttt{en/assoc-supervisor} \\ 128 | 联培导师 & \texttt{zh/co-supervisor} & \texttt{en/co-supervisor} \\ 129 | 日期 & \multicolumn{2}{c}{\texttt{date}} \\ 130 | 学号 & \multicolumn{2}{c}{\texttt{id}} \\ \bottomrule 131 | \end{tabular} 132 | \end{table} 133 | \end{frame} 134 | 135 | \begin{frame}[fragile]{数学} 136 | \begin{itemize} 137 | \item 公式示例:\verb|contents/math_and_citations.tex| 138 | \link{https://github.com/sjtug/SJTUThesis/blob/master/contents/math_and_citations.tex} 139 | \item \SJTUThesis{} 定义了常用的数学环境(需要手工引入 \verb|amsthm| 宏包): 140 | \begin{table}[h] 141 | \centering 142 | \footnotesize 143 | \begin{tabular}{*{7}{l}}\toprule 144 | assumption & axiom & conjecture & corollary & definition & 145 | example & exercise 146 | \\ 147 | 假设 & 公理 & 猜想 & 推论 & 定义 & 例 & 练习 148 | \\\midrule 149 | lemma & problem & proof & proposition & remark & 150 | solution & theorem 151 | \\ 152 | 引理 & 问题 & 证明 & 命题 & 注 & 解 & 153 | 定理 154 | \\\bottomrule 155 | \end{tabular} 156 | \end{table} 157 | \end{itemize} 158 | \end{frame} 159 | 160 | \begin{frame}[fragile]{参考文献} 161 | \begin{itemize} 162 | \item 建议自动生成 163 | \begin{itemize} 164 | \item \LaTeX 引擎自身不能处理参考文献,需要借助外部程序! 165 | \end{itemize} 166 | \item 传统方法:\BibTeX 后端 167 | \begin{itemize} 168 | \item 控制文献、引用样式:\pkg{natbib} 宏包 169 | \item 国标样式:\pkg{gbt7714} 宏包 170 | \link{https://mirrors.sjtug.sjtu.edu.cn/ctan/biblio/bibtex/contrib/gbt7714/gbt7714.pdf} 171 | \end{itemize} 172 | \item 现代方法:\verb|biber| 后端 + \pkg{biblatex} 宏包 173 | \begin{itemize} 174 | \item 国标样式:\pkg{biblatex-gbt7714-2015} 宏包 175 | \link{https://mirrors.sjtug.sjtu.edu.cn/ctan/macros/latex/contrib/biblatex-contrib/biblatex-gb7714-2015/biblatex-gb7714-2015.pdf} 176 | \end{itemize} 177 | \item 需要多轮编译——再次推荐 latexmk 178 | \end{itemize} 179 | \end{frame} 180 | 181 | \begin{frame}[fragile]{参考文献(续)} 182 | \begin{itemize} 183 | \item 生成 \verb|.bib| 数据库 184 | \begin{itemize} 185 | \item Google Scholar 可直接复制或者批量导出 186 | \item 用 Zotero、Jabref 等文献管理软件生成 187 | \end{itemize} 188 | \item 两种引用模式: 189 | \begin{itemize} 190 | \item 上标模式:如“在许多文献\textsuperscript{[12-13]}中……” 191 | \begin{lstlisting}[basicstyle=\ttfamily] 192 | \cite{key12, key13} 193 | \end{lstlisting} 194 | \item 正文模式:如“文献~[14] 证明了……” 195 | \begin{lstlisting}[basicstyle=\ttfamily,morekeywords={parencite}] 196 | \parencite{key14} 197 | \end{lstlisting} 198 | \end{itemize} 199 | \end{itemize} 200 | \end{frame} 201 | 202 | \begin{frame}[fragile]{\SJTUThesis 问题} 203 | \begin{itemize} 204 | \item 常见问题 205 | \begin{itemize} 206 | \item 参考文献列表出错、缺少字体、无法编译、格式不对…… 207 | \item 阅读模板文档 \verb|sjtutex.pdf| \link{https://github.com/sjtug/SJTUTeX/releases} 208 | 和 SJTUThesis 示例文档代码 209 | \item 查看 Wiki \link{https://github.com/sjtug/SJTUThesis/wiki} 210 | \end{itemize} 211 | 212 | \item 主动提问 213 | \begin{itemize} 214 | \item GitHub Discussions 提问:\link{https://github.com/sjtug/SJTUThesis/discussions} 215 | \item GitHub Issues 报告 BUG:\link{https://github.com/sjtug/SJTUThesis/issues} 216 | \end{itemize} 217 | 218 | \end{itemize} 219 | \end{frame} 220 | -------------------------------------------------------------------------------- /sjtuvi.sty: -------------------------------------------------------------------------------- 1 | %% 2 | %% This is file `sjtuvi.sty', 3 | %% generated with the docstrip utility. 4 | %% 5 | %% The original source files were: 6 | %% 7 | %% sjtuvi.dtx (with options: `package') 8 | %% ------------------------------------------------------------------------ 9 | %% Copyright (C) Shanghai Jiao Tong University 10 | %% The definition in this file is referred to the Visual Identity System 11 | %% from Shanghai Jiao Tong University (SJTU). 12 | %% See https://vi.sjtu.edu.cn for more information. 13 | %% 14 | %% SJTUG implements the design but doesn't hold the copyright. 15 | %% Any commercial usage in this file should be acknowledged by 16 | %% the administration of SJTU. 17 | %% More infomation about the license, 18 | %% see https://vi.sjtu.edu.cn/index.php/articles/bulletin/16. 19 | %% ------------------------------------------------------------------------ 20 | \NeedsTeXFormat{LaTeX2e} 21 | \ProvidesPackage{sjtuvi}[2024/12/21 v3.1.1 Visual Identity System library for sjtubeamer] 22 | \newif\ifsjtubeamer@tempif% 23 | \newbox\sjtubeamer@tempbox% 24 | \newskip\sjtubeamer@h% 25 | \def\DefineOption#1#2#3{% 26 | % #1: package 27 | % #2: key 28 | % #3: value 29 | \DeclareOptionBeamer{#3}{\expandafter\def\csname sjtubeamer@#1@#2\endcsname{#3}}% 30 | } 31 | \def\EqualOption{TT\fi\ifEqualOption} 32 | \def\ifEqualOption#1#2#3{% 33 | % #1: package 34 | % #2: key 35 | % #3: value 36 | \edef\tempvar{\csname sjtubeamer@#1@#2\endcsname}% 37 | \def\tempvalue{#3}% 38 | \ifx\tempvar\tempvalue\sjtubeamer@tempiftrue\else\sjtubeamer@tempiffalse\fi% 39 | \ifsjtubeamer@tempif% 40 | } 41 | \def\IsEmpty{TT\fi\ifIsEmpty} 42 | \def\ifIsEmpty#1{% 43 | \setbox\sjtubeamer@tempbox=\hbox\bgroup\def\\{}#1\unskip\egroup% 44 | \ifdim\wd\sjtubeamer@tempbox=0pt \sjtubeamer@tempiftrue% 45 | \else\sjtubeamer@tempiffalse\fi% 46 | \ifsjtubeamer@tempif% 47 | } 48 | \providecommand{\getcontribdir}[1]{contrib/#1} 49 | \providecommand{\getcontribpath}[2]{\getcontribdir{#1}/#2} 50 | \RequirePackage{tikz} 51 | \usetikzlibrary{fadings} 52 | \usetikzlibrary{decorations.pathmorphing} 53 | \usetikzlibrary{external} 54 | \usetikzlibrary{backgrounds} 55 | \definecolor{sjtuRedPrimary}{RGB}{167,32,56} % engred 56 | \definecolor{sjtuRedSecondary}{RGB}{240,131,0} % orange 57 | \definecolor{sjtuRedTertiary}{RGB}{253,208,0} % yellow 58 | \definecolor{sjtuBluePrimary}{RGB}{0,64,152} % problue 59 | \definecolor{sjtuBlueSecondary}{RGB}{51,141,39} % lightgreen 60 | \definecolor{sjtuBlueTertiary}{RGB}{0,81,78} % lightgray 61 | \RequirePackage{array} 62 | \newcommand{\definelogo}[4]{ 63 | % #1: csname 64 | % #2: path 65 | % #3: horizontal clip (0~1) 66 | % #4: vertical clip (0~1) 67 | \pgfmathparse{notgreater(#3,#4)} 68 | \ifnum\pgfmathresult=1 69 | \begin{tikzfadingfrompicture}[name=#1] 70 | \fill[black] (-1,-1) rectangle (1,1); 71 | \node {\includegraphics[width=1.5cm]{#2}}; 72 | \end{tikzfadingfrompicture} 73 | \else 74 | \begin{tikzfadingfrompicture}[name=#1] 75 | \fill[black] (-1,-1) rectangle (1,1); 76 | \node {\includegraphics[height=1.5cm]{#2}}; 77 | \end{tikzfadingfrompicture} 78 | \fi 79 | \expandafter\providecommand\csname #1\endcsname[1][]{% 80 | % ##1: override color, or opacity=... (optional) 81 | \tikzexternaldisable% 82 | \begin{tikzpicture} 83 | \begin{scope} 84 | \clip ({-1.0+#3},{-1.0+#4}) rectangle ({1.0-#3},{1.0-#4}); 85 | \fill [##1, path fading=#1] (-1,-1) rectangle (1,1); 86 | \end{scope} 87 | \end{tikzpicture}% 88 | } 89 | } 90 | \definelogo{sjtubadge}{vi/sjtu-vi-sjtubadge.pdf}{0}{0} 91 | \definelogo{zhlogo}{vi/sjtu-vi-zhlogo.pdf}{0.13}{0.75} 92 | \definelogo{enlogo}{vi/sjtu-vi-enlogo.pdf}{0.13}{0.75} 93 | \definelogo{dlogo}{vi/sjtu-vi-dlogo.pdf}{0}{0} 94 | \definelogo{vlogo}{vi/sjtu-vi-vlogo.pdf}{0.8}{0.13} 95 | \definelogo{sjtubg}{vi/sjtu-vi-sjtubg.png}{0.3}{0.5} 96 | \definelogo{sjtugate}{vi/sjtu-vi-sjtugate.png}{0.25}{0.8} 97 | \newcommand{\secondaryinstlogo}[3][]{% 98 | % #1: shortinst (optional) 99 | % #2: longinst 100 | % #3: logo 101 | \hbox{% 102 | \raggedright% 103 | \resizebox{!}{1cm}{\vphantom{-}#3}% 104 | \if\IsEmpty{#2}% 105 | \else% 106 | \if\IsEmpty{#1}% 107 | \if\IsEmpty{#3}\else% 108 | {\hskip0.31cm\vrule width0.5pt}\hskip0.31cm% 109 | \fi% 110 | \vbox to 1cm{% 111 | \vfill% 112 | \hbox{% 113 | \noindent% 114 | \fontsize{7pt}{0pt}\selectfont\mdseries\scshape% 115 | \begin{tabular}{@{}l<{\vphantom{\vrule depth2pt}}@{}} 116 | #2 117 | \end{tabular}% 118 | }% 119 | \vskip-2pt% 120 | \vfill% 121 | }% 122 | \else% 123 | \if\IsEmpty{#3}\else% 124 | {\hskip0.23cm\vrule width0.5pt}\hskip0.23cm% 125 | \fi% 126 | \vbox to 1cm{% 127 | \def\\{}% 128 | \vfill 129 | \offinterlineskip 130 | \hbox{% 131 | \fontsize{13pt}{0pt}\selectfont% 132 | \mdseries\sffamily #2% 133 | } 134 | \vskip0.08cm% 135 | \hbox{% 136 | \fontsize{5pt}{0pt}\selectfont% 137 | \mdseries\scshape #1% 138 | } 139 | \vskip-\prevdepth\vskip0.14cm% 140 | }% 141 | \fi% 142 | \fi% 143 | }% 144 | } 145 | \providecommand{\stamptext}[2][structure]{ 146 | { 147 | \providecolor{#1}{named}{sjtuRedPrimary} 148 | \tikzset{external/export=false} 149 | \begin{tikzpicture}[baseline=(nodetext.base)] 150 | \node [white] (nodetext) at (0,0) {#2}; 151 | \pgfextracty{\sjtubeamer@h}{\pgfpointanchor{nodetext}{north}}% 152 | \pgfextracty{\pgf@ya}{\pgfpointanchor{nodetext}{south}}% 153 | \addtolength{\sjtubeamer@h}{-\pgf@ya} 154 | \scoped[on background layer] 155 | \fill [#1] 156 | (-1.25*\sjtubeamer@h,0) 157 | -- (-0.85*\sjtubeamer@h,0.3*\sjtubeamer@h) 158 | -- (-0.85*\sjtubeamer@h,0.5*\sjtubeamer@h) 159 | -- (0.85*\sjtubeamer@h,0.5*\sjtubeamer@h) 160 | -- (0.85*\sjtubeamer@h,0.3*\sjtubeamer@h) 161 | -- (1.25*\sjtubeamer@h,0) 162 | -- (0.85*\sjtubeamer@h,-0.3*\sjtubeamer@h) 163 | -- (0.85*\sjtubeamer@h,-0.5*\sjtubeamer@h) 164 | -- (-0.85*\sjtubeamer@h,-0.5*\sjtubeamer@h) 165 | -- (-0.85*\sjtubeamer@h,-0.3*\sjtubeamer@h) -- cycle; 166 | \end{tikzpicture} 167 | } 168 | } 169 | \def\sjtubeamer@compatible@false{false} 170 | \ifx\sjtubeamer@compatible\sjtubeamer@compatible@false 171 | \else 172 | \usetikzlibrary{patterns.meta} 173 | \tikzdeclarepattern{ 174 | name=stamp, 175 | parameters={ 176 | \pgfkeysvalueof{/pgf/pattern keys/size}, 177 | \pgfkeysvalueof{/pgf/pattern keys/xshift}, 178 | \pgfkeysvalueof{/pgf/pattern keys/yshift}, 179 | }, 180 | defaults={ 181 | size/.initial = 5pt, 182 | xshift/.initial = 0pt, 183 | yshift/.initial = 0pt, 184 | }, 185 | bottom left={( 186 | -0.5*\pgfkeysvalueof{/pgf/pattern keys/size} 187 | +\pgfkeysvalueof{/pgf/pattern keys/xshift}, 188 | -0.4*\pgfkeysvalueof{/pgf/pattern keys/size} 189 | +\pgfkeysvalueof{/pgf/pattern keys/yshift} 190 | )}, 191 | top right={( 192 | 0.5*\pgfkeysvalueof{/pgf/pattern keys/size} 193 | +\pgfkeysvalueof{/pgf/pattern keys/xshift}, 194 | 0.4*\pgfkeysvalueof{/pgf/pattern keys/size} 195 | +\pgfkeysvalueof{/pgf/pattern keys/yshift} 196 | )}, 197 | tile size={( 198 | \pgfkeysvalueof{/pgf/pattern keys/size}, 199 | 0.8*\pgfkeysvalueof{/pgf/pattern keys/size} 200 | )}, 201 | code={ 202 | \def\sjtubeamer@s{\pgfkeysvalueof{/pgf/pattern keys/size}}% 203 | \tikzset{x=0.5*\sjtubeamer@s,y=0.2*\sjtubeamer@s} 204 | \fill[xshift=\pgfkeysvalueof{/pgf/pattern keys/xshift}, 205 | yshift=\pgfkeysvalueof{/pgf/pattern keys/yshift}] 206 | (-0.25*\sjtubeamer@s,0) 207 | -- (-0.17*\sjtubeamer@s,0.06*\sjtubeamer@s) 208 | -- (-0.17*\sjtubeamer@s,0.1*\sjtubeamer@s) 209 | -- (0.17*\sjtubeamer@s,0.1*\sjtubeamer@s) 210 | -- (0.17*\sjtubeamer@s,0.06*\sjtubeamer@s) 211 | -- (0.25*\sjtubeamer@s,0) 212 | -- (0.17*\sjtubeamer@s,-0.06*\sjtubeamer@s) 213 | -- (0.17*\sjtubeamer@s,-0.1*\sjtubeamer@s) 214 | -- (-0.17*\sjtubeamer@s,-0.1*\sjtubeamer@s) 215 | -- (-0.17*\sjtubeamer@s,-0.06*\sjtubeamer@s) -- cycle; 216 | } 217 | } 218 | \fi 219 | \ifx\sjtubeamer@compatible\sjtubeamer@compatible@false 220 | \providecommand{\stamparray}[3]{} 221 | \else 222 | \providecommand{\stamparray}[3]{ 223 | % #1: pattern size 224 | % #2: starting point 225 | % #3: ending point 226 | \usebeamercolor{palette primary} 227 | \fill [pattern={stamp[size=#1]}, 228 | pattern color=bg!50!fg] #2 rectangle #3; 229 | \def\sjtubeamer@s{#1}% 230 | \pgfmathparse{0.5*\sjtubeamer@s}\let\xs=\pgfmathresult% 231 | \pgfmathparse{-0.4*\sjtubeamer@s}\let\ys=\pgfmathresult% 232 | \fill [pattern={stamp[size=#1,xshift=\xs, yshift=\ys]}, 233 | pattern color=bg!50!fg] #2 rectangle #3; 234 | } 235 | \fi 236 | \pgfdeclaredecoration{stampline}{initial} 237 | { 238 | \state{initial}[ 239 | width=\pgfdecorationsegmentlength, 240 | auto corner on length=\pgfdecorationsegmentlength] 241 | { 242 | \def\sjtubeamer@l{\pgfdecorationsegmentlength}% 243 | \pgfpathlineto{\pgfpoint{0.25*\sjtubeamer@l}{0pt}} 244 | \pgfpathlineto{\pgfpoint{0.33*\sjtubeamer@l}{0.06*\sjtubeamer@l}} 245 | \pgfpathlineto{\pgfpoint{0.33*\sjtubeamer@l}{0.1*\sjtubeamer@l}} 246 | \pgfpathlineto{\pgfpoint{0.67*\sjtubeamer@l}{0.1*\sjtubeamer@l}} 247 | \pgfpathlineto{\pgfpoint{0.67*\sjtubeamer@l}{0.06*\sjtubeamer@l}} 248 | \pgfpathlineto{\pgfpoint{0.75*\sjtubeamer@l}{0pt}} 249 | \pgfpathlineto{\pgfpoint{\sjtubeamer@l}{0pt}} 250 | } 251 | \state{final} 252 | { 253 | \pgfpathlineto{\pgfpointdecoratedpathlast} 254 | } 255 | } 256 | \endinput 257 | %% 258 | %% End of file `sjtuvi.sty'. 259 | -------------------------------------------------------------------------------- /src/source/beamerthemesjtubeamer.dtx: -------------------------------------------------------------------------------- 1 | % \iffalse meta-comment -------------------------------------------------- 2 | % Copyright (C) 2021-2024 SJTUG 3 | % 4 | % Licensed under the Apache License, Version 2.0 (the "License"); 5 | % you may not use this file except in compliance with the License. 6 | % You may obtain a copy of the License at 7 | % 8 | % http://www.apache.org/licenses/LICENSE-2.0 9 | % 10 | % Unless required by applicable law or agreed to in writing, software 11 | % distributed under the License is distributed on an "AS IS" BASIS, 12 | % WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | % See the License for the specific language governing permissions and 14 | % limitations under the License. 15 | % 16 | % ------------------------------------------------------------------------ \fi 17 | % \CheckSum{0} 18 | % \StopEventually{} 19 | % \iffalse 20 | % 21 | % Target Structure: 22 | % +------------------------------------------------+ 23 | % + main.tex + 24 | % +------------------------------------------------+ 25 | % + sjtubeamer + 26 | % +------------------------------------------------+ 27 | % + color + inner + outer + font + 28 | % + +-----------+ + + 29 | % + + cover + + + 30 | % +------------------------------------+-----------+ 31 | % + sjtuvi + 32 | % +------------------------------------+ 33 | % + logo + 34 | % +------------------------------------+ 35 | % 36 | %<*package> 37 | % ------------------------------------------------------------------- \fi 38 | % \iffalse 39 | \NeedsTeXFormat{LaTeX2e} 40 | \ProvidesPackage{beamerthemesjtubeamer}[2024/12/21 v3.1.1 sjtubeamer parent theme] 41 | % \fi 42 | % 43 | % \subsection{Parent Theme} 44 | % 45 | % The primary job of this package is to load the component sub-packages of the 46 | % \themename theme and route the theme options accordingly. It also 47 | % provides some custom commands and environments for the user. 48 | % 49 | % $\rightarrow$ The following will demostrates how to pass options between files. 50 | % 51 | % $\rightarrow$ To set up an option, use \verb"\DeclareOptionBeamer" to let beamer 52 | % theme receive such an option and store the value into a variable. 53 | % 54 | % $\rightarrow$ To make the variable easy to follow and avoid duplicates, 55 | % the naming system is as follows: 56 | % \begin{itemize} 57 | % \item Start with the project name \verb"sjtubeamer". 58 | % \item Split by \verb"@" symbol and move to the next level. 59 | % \item The final level should be the variable name itself. 60 | % \end{itemize} 61 | % 62 | % \begin{macro}{\sjtubeamer@cover} 63 | % This macro selects the cover theme. 64 | % \verb"maxplus" 65 | % The titlegraphic will be a photo. 66 | % \verb"max" 67 | % The background will be the photo. 68 | % \verb"min" 69 | % The design will be minimalistic. 70 | % \verb"my" 71 | % Reserved interface for developers for 72 | % customized title page and bottom page. 73 | % \begin{macrocode} 74 | %<*maxplus> 75 | \DeclareOptionBeamer{maxplus}{ 76 | \def\sjtubeamer@cover{maxplus}\def\sjtubeamer@logopos{topright}} 77 | % 78 | %<*max> 79 | \DeclareOptionBeamer{max}{ 80 | \def\sjtubeamer@cover{max}\def\sjtubeamer@logopos{bottomright}} 81 | % 82 | %<*min> 83 | \DeclareOptionBeamer{min}{ 84 | \def\sjtubeamer@cover{min}\def\sjtubeamer@logopos{topright}} 85 | % 86 | %<*my> 87 | \DeclareOptionBeamer{my}{ 88 | \def\sjtubeamer@cover{my}\def\sjtubeamer@logopos{bottomright}} 89 | % reserved for customization 90 | % 91 | % \end{macrocode} 92 | % $\rightarrow$ Next, declare the initial configuration. 93 | % \begin{macrocode} 94 | \ExecuteOptionsBeamer{ 95 | %<*maxplus> 96 | maxplus, 97 | % 98 | %<*min> 99 | min, 100 | % 101 | %<*my> 102 | my, 103 | % 104 | %<*max> 105 | max, 106 | % 107 | } 108 | % \end{macrocode} 109 | % \end{macro} 110 | % 111 | % \begin{macro}{\sjtubeamer@color} 112 | % Choose the main color palette. 113 | % 114 | % \verb"red". \verb"sjtuRed*" 115 | % \verb"blue" \verb"sjtuBlue*" 116 | % \begin{macrocode} 117 | \DeclareOptionBeamer{red}{\def\sjtubeamer@color{red}} 118 | \DeclareOptionBeamer{blue}{\def\sjtubeamer@color{blue}} 119 | \ExecuteOptionsBeamer{red} 120 | % \end{macrocode} 121 | % \end{macro} 122 | % 123 | % \begin{macro}{\sjtubeamer@lum} 124 | % Decide whether it is in light mode or 125 | % dark mode. Switch the lumination. 126 | % \begin{macrocode} 127 | \DeclareOptionBeamer{light}{\def\sjtubeamer@lum{light}} 128 | \DeclareOptionBeamer{dark}{\def\sjtubeamer@lum{dark}} 129 | \ExecuteOptionsBeamer{dark} 130 | % \end{macrocode} 131 | % \end{macro} 132 | % 133 | % \begin{macro}{\sjtubeamer@lang} 134 | % Set the main language of this beamer. 135 | % 136 | % If the user is using \verb"ctexbeamer" 137 | % class, the default option will be 138 | % Chinese. 139 | % 140 | % If the user use \verb"ctex" package after 141 | % using this theme, such an advanced user 142 | % should specify the language to Chinese 143 | % manually. 144 | % 145 | % TODO: 146 | % may be a built in support for Chinese 147 | % will be used in the future. Just taken 148 | % \verb"\RequirePackage[scheme=plain]{ctex}" 149 | % for basic Chinese character support. 150 | % \begin{macrocode} 151 | \DeclareOptionBeamer{zh}{\def\sjtubeamer@lang{zh}} 152 | \DeclareOptionBeamer{en}{\def\sjtubeamer@lang{en}} 153 | \@ifclassloaded{ctexbeamer}{\ExecuteOptionsBeamer{zh}}{ 154 | \ExecuteOptionsBeamer{en}} 155 | % \end{macrocode} 156 | % \end{macro} 157 | % 158 | % \begin{macro}{\sjtubeamer@nav} 159 | % Choose the outer theme for this template. 160 | % \begin{macrocode} 161 | \DeclareOptionBeamer{miniframes}{\def\sjtubeamer@nav{miniframes}} 162 | \DeclareOptionBeamer{infolines}{\def\sjtubeamer@nav{infolines}} 163 | \DeclareOptionBeamer{sidebar}{\def\sjtubeamer@nav{sidebar}} 164 | \DeclareOptionBeamer{default}{\def\sjtubeamer@nav{default}} 165 | \DeclareOptionBeamer{smoothbars}{\def\sjtubeamer@nav{smoothbars}} 166 | \DeclareOptionBeamer{split}{\def\sjtubeamer@nav{split}} 167 | \DeclareOptionBeamer{shadow}{\def\sjtubeamer@nav{shadow}} 168 | \DeclareOptionBeamer{tree}{\def\sjtubeamer@nav{tree}} 169 | \DeclareOptionBeamer{smoothtree}{\def\sjtubeamer@nav{smoothtree}} 170 | \ExecuteOptionsBeamer{miniframes} 171 | % \end{macrocode} 172 | % \end{macro} 173 | % 174 | % \begin{macro}{\sjtubeamer@logopos} 175 | % Choose the override outer logo position. 176 | % 177 | % No default option will get executed 178 | % since it has already been executed by 179 | % the selection of \verb"\sjtubeamer@cover". 180 | % \begin{macrocode} 181 | \DeclareOptionBeamer{topright}{\def\sjtubeamer@logopos{topright}} 182 | \DeclareOptionBeamer{bottomright}{\def\sjtubeamer@logopos{bottomright}} 183 | % \end{macrocode} 184 | % \end{macro} 185 | % 186 | % $\rightarrow$ Then, the user's option will be processed after this 187 | % (at the end of this subsection). 188 | % \begin{macrocode} 189 | \ProcessOptionsBeamer 190 | % \end{macrocode} 191 | % $\rightarrow$ Finally, the option can only be one of above and pass it to the 192 | % target package. 193 | % \begin{macrocode} 194 | \PassOptionsToPackage{\sjtubeamer@cover}{beamerinnerthemesjtubeamer} 195 | \PassOptionsToPackage{\sjtubeamer@color}{beamercolorthemesjtubeamer} 196 | \PassOptionsToPackage{\sjtubeamer@color}{beamerinnerthemesjtubeamer} 197 | \PassOptionsToPackage{\sjtubeamer@lum}{beamercolorthemesjtubeamer} 198 | \PassOptionsToPackage{\sjtubeamer@lang}{beamerinnerthemesjtubeamer} 199 | \PassOptionsToPackage{\sjtubeamer@nav}{beamerouterthemesjtubeamer} 200 | \PassOptionsToPackage{\sjtubeamer@logopos}{beamerouterthemesjtubeamer} 201 | % \end{macrocode} 202 | % 203 | % The following code is executed when it is in mode. 204 | % \begin{macrocode} 205 | \mode 206 | % \end{macrocode} 207 | % Load sub-themes. 208 | % \begin{macrocode} 209 | \usecolortheme{sjtubeamer} 210 | \usefonttheme{sjtubeamer} 211 | \useinnertheme{sjtubeamer} 212 | \useoutertheme{sjtubeamer} 213 | % \end{macrocode} 214 | % 215 | % \begin{macro}{\usesjtutheme} 216 | % You could load other contrib plugin by 217 | % this command. 218 | % Use comma-seperated list to load 219 | % multiple sub-themes in one line. 220 | % The \verb"\getcontribpath" is defined in 221 | % \verb"sjtuvi" package loaded in inner 222 | % theme. 223 | % 224 | % You could pass options to all the 225 | % sub-themes by writing in the square 226 | % brackets. 227 | % Then, in your sub-theme, you could use 228 | % \verb"\if\EqualOption{}{