Files
ouc_latex_template/幻灯片/README.md
T
laoyang f87d763602 重写全部 README,只保留使用说明
17 个 README 统一改成使用说明书,去掉来源、踩坑、需求过程等内容。

只保留:
- 怎么编译、跑几遍
- 文件结构
- 要改哪些参数(逐项列出宏名与含义)
- 用到的命令(表格)
- 版式参数

删除:
- 原文件来源、抽取过程
- 踩坑记录、最小复现、实测数据
- 用户需求、工单号、历史沿革
- 改造前后对比

行数 4185 → 2261。

全库 16/16 编译通过。
2026-11-01 08:52:54 +08:00

167 lines
3.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 幻灯片
Beamer 演示文稿,16:9,中国海洋大学配色主题。
## 编译
```bash
cd 幻灯片
xelatex slides.tex
xelatex slides.tex % 跑两遍,目录与总页数才正确
```
或仓库根:`bash build.sh 幻灯片`(自动跑两遍)
## 文件
```
幻灯片/
├── slides.tex 主文件
├── oucslide.sty 版式包
├── theme/ 主题的五个组成部分
│ ├── beamerthemeOUCSlide.sty
│ ├── beamercolorthemeOUCSlide.sty
│ ├── beamerfontthemeOUCSlide.sty
│ ├── beamerinnerusthemeOUCSlide.sty
│ └── beamerouterthemeOUCSlide.sty
├── figs/ 插图
└── logos/ 校徽等标识
```
## 基本信息
```latex
\documentclass[aspectratio=169,UTF8,t]{beamer}
\title{中国海洋大学幻灯片LaTex模板}
\subtitle{助力你的科研梦想}
\author{张远航}
\date{\today}
\institute{计算机科学与技术学院}
\newcommand{\last}{敬请批评指正!} % 结束语
```
| 命令 | 说明 |
|---|---|
| `\title{}` | 主标题 |
| `\subtitle{}` | 副标题 |
| `\author{}` | 作者 |
| `\date{}` | 日期 |
| `\institute{}` | 单位 |
| `\last` | 结束页文字 |
`aspectratio=169` 是 16:9。要 4:3 改成 `aspectratio=43`。
## 文档骨架
```latex
\begin{document}
\maketitle % 标题页
\makeoutline % 目录页
\section{简介}
\subsection{模板简介}
\begin{frame}
\frametitle{简介}
正文内容。
\end{frame}
\makeoutline % 每节前重复目录(可选)
\section{下一节}
\begin{frame}
\frametitle{页面标题}
...
\end{frame}
\makelast % 结束页
\end{document}
```
| 命令 | 说明 |
|---|---|
| `\maketitle` | 标题页 |
| `\makeoutline` | 目录页,可在每节前反复调用 |
| `\makelast` | 结束页,显示 `\last` 的内容 |
## 单页写法
```latex
\begin{frame}
\frametitle{页面标题}
\begin{itemize}
\item 第一点
\item 第二点
\end{itemize}
\end{frame}
```
分栏:
```latex
\begin{frame}
\frametitle{两栏}
\begin{columns}
\begin{column}{0.48\textwidth}
左栏内容
\end{column}
\begin{column}{0.48\textwidth}
右栏内容
\end{column}
\end{columns}
\end{frame}
```
## 主题与配色
主题在 `theme/` 下,分五块:整体、配色、字体、内部元素、外部元素。
改配色看 `beamercolorthemeOUCSlide.sty`,改字体看
`beamerfontthemeOUCSlide.sty`。
已加载的宏包:
| 宏包 | 用途 |
|---|---|
| `tcolorbox` | 彩色盒子 |
| `fontawesome` | 图标 |
| `caption` / `subcaption` | 图注 |
| `verbatim` | 代码原样输出 |
## 插图
图片放 `figs/`:
```latex
\begin{figure}
\centering
\includegraphics[width=0.6\textwidth]{figs/fig01.png}
\caption{图标题}
\end{figure}
```
## 版式
```
16:9(aspectratio=169)
顶部对齐(t 选项)
海大蓝配色
标题页 + 目录页 + 内容页 + 结束页
页脚含校徽、页码、作者
```
## 自定义命令
| 命令 | 用途 |
|---|---|
| `\maketitle` | 标题页 |
| `\makeoutline` | 目录页 |
| `\makelast` | 结束页 |
| `\banner{}` | 横幅标题 |
| `\oucurl{url}` | 排网址链接 |
| `\bottomslider` / `\topslider` | 底部/顶部进度条 |
| `\footerlogo` | 页脚校徽 |
## 注意
示例内容为虚构数据,使用时全部替换。