mirror of
https://github.com/ElegantLaTeX/ElegantBook.git
synced 2026-01-26 04:14:35 +08:00
Page:
convert
Pages
AboutPullRequest
Acknowledgement
BaseHideOption
Bibliography
ChapterSummary
ColorThemes
CoverLogo
DeviceModeOption
DisplayStyles
Donation
FAQ
Home
Hyphen
Installation
Introduction
Languages
Lists
MathEnvironments
MinimalExample
OnlineUsage
Preface
ProblemSet
RecruitSupportMembers
SetupInstruction
SideNote
SymbolFont
Updates
UserSelectedWorksPlan
convert
介绍
关于提交
列表环境
协作人员招募
参考文献
在线使用模板
安装
封面徽标
常见问题
捐赠
数学环境简介
旁注
更新说明
最小示例
添加序章
用户作品计划
章后习题
章标题显示风格
章节摘要
符号字体
致谢
装饰物
设备选项
设置说明
语言模式
连字符
颜色主题
Clone
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.
如果你使用的 ElegantBook 2.x 版本,推荐将其改为符合 ElegantBook 3.x 版本的格式,下面是在不安装 ElegantBook 模板前提下的转换步骤。
- 从 Github 上下载最新的模板,将 3.x 版本的
elegantbook.cls替换你当前目录下 2.x 的elegantbook.cls。 - 将下载下来的 logo.png 和 cover.jpg 复制到 2.x 版本 ./figure/ 文件夹下,因为 2.x 使用的是 PDF 文件,需要把 2.x 版本的主文件(
main.tex)中的\logo{logo.pdf}替换为\logo{logo.png},\cover{cover.pdf}替换为\cover{cover.jpg}。 - 类文件选项:
mathpazo和mtpro2均不支持了,如果你使用了这两个选项,需要将其删除。示例,如果使用了mathpazo选项,需要把\documentclass[green,mathpazo]{elegantbook}改为\documentclass[green]{elegantbook}。 \zhtitle和\zhend合并为\title,也即\zhtitle{zh-string1}和\zhend{zh-string2}改为\title{zh-string1 zhstring2}。\entitle和\enend合并为\subtitle,合并方法同上。\myquote改为\equote。- 由于未使用
mtpro2宏包,所以需要把\mbf改为\mathbf。 - 在
\mainmatter之后加上\hypersetup{pageanchor=true} - 颜色修改
- main 没有改动,不需要替换;
- thid 改为 third;
- seco 改为 second。
- 抄录环境
\verb|x|改为\lstinline|x|,具体替换为verb\|改为lstinline\|verbatim替换为lstlisting,根据有框无框需求可以给lstlisting环境添加frame=single选项。
\bibliographystyle{ieeetr}删除。- 自定义环境
第一步,名字替换:
newdef改为definitionnewthem改为theoremnewlemma改为lemmanewcorol改为corollarynewprop改为propositionnewproof改为proof
第二步:选项替换:
除去 newproof 环境,其他都需要使用正则表达式替换。
这一步存在两种情况,一种是环境使用了选项,则使用下面的替换规则:
\begin{环境名}[x]改为\begin{环境名}{x}{}。begin{definition}\[(.*?)\]替换为begin{definition}{\1}{}begin{theorem}\[(.*?)\]替换为begin{theorem}{\1}{}begin{lemma}\[(.*?)\]替换为begin{lemma}{\1}{}begin{corollary}\[(.*?)\]替换为begin{corollary}{\1}{}begin{proposition}\[(.*?)\]替换为begin{proposition}{\1}{}
如果定理环境未使用选项,则需要使用下面替换规则:
\begin{环境名}改为\begin{环境名}{}{}begin{definition}$替换为begin{definition}{}{}begin{theorem}$替换为begin{theorem}{}{}begin{lemma}$替换为begin{lemma}{}{}begin{corollary}$替换为begin{corollary}{}{}begin{proposition}$替换为begin{proposition}{}{}