texlive[72372] Master/texmf-dist: easybook (24sep24)
commits+karl at tug.org
commits+karl at tug.org
Tue Sep 24 22:30:44 CEST 2024
Revision: 72372
https://tug.org/svn/texlive?view=revision&revision=72372
Author: karl
Date: 2024-09-24 22:30:44 +0200 (Tue, 24 Sep 2024)
Log Message:
-----------
easybook (24sep24)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/easybook/README.md
trunk/Master/texmf-dist/doc/latex/easybook/easybook.pdf
trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex
trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx
trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty
trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls
trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg
Modified: trunk/Master/texmf-dist/doc/latex/easybook/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/easybook/README.md 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/doc/latex/easybook/README.md 2024-09-24 20:30:44 UTC (rev 72372)
@@ -1,5 +1,5 @@
# The `easybook` document class
-Easily typesetting Chinese theses or books (v2024dt)
+Easily typesetting Chinese theses or books (v2024dx)
## Abstract
`easybook` is a pure academic template created based on the `ctexbook` book document class. It also has the functions of `book` and `article` document class. Combined with the general framework design of the theses of many universities in China, providing multiple commands and interfaces allows users to easily customize the theses templates. Its basic macro package `easybase` can also be used with `ctex` and standard document classes.
Modified: trunk/Master/texmf-dist/doc/latex/easybook/easybook.pdf
===================================================================
(Binary files differ)
Modified: trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/doc/latex/easybook/easybook.tex 2024-09-24 20:30:44 UTC (rev 72372)
@@ -23,8 +23,8 @@
name = easybook,
color-scheme = blue,
title = EASYBOOK使用手册,
- version = v2024dt,
- date = 2024/09/22,
+ version = v2024dx,
+ date = 2024/09/24,
authors = 瞿毅,
info = 简便地排版中文学位论文或书籍,
email = toquyi at 163.com,
@@ -458,7 +458,7 @@
脚注内容整体的行距因子。可以使用 \module*{hdr} 模块 \option{fnpara-format} 选项的代码单独覆盖每个脚注的行距,从而使脚注间和内容文本自身的行距不同。
\begin{ctexexam}
\ebspaceset{fntspread = 1.3}
- \ebhdrset{fnpara-format = \linespread{1.2}\selectfont}
+ \ebhdrset{fnpara-format = \usestretch{1.2}}
\end{ctexexam}
\keyval{everyspread}{数值}
统一设置上述所有的行距因子。
@@ -468,11 +468,12 @@
行间公式与下面正文间的额外距离。
\begin{cnltxlist}
\command{usestretch}[\marg{数值}]\newtagv{2024dt}%
- 设置之后文本的行距。可在任意地方使用,在局部范围生效。
+ 设置之后文本的行距。可在任意地方使用,作用范围为局部。
\environment{usespace}[\marg{数值}]\newtagv{2024dt}%
设置环境内文本的行距。可包含行间公式和表格等环境。
\begin{ctexexam}
\begin{usespace}{1.5}\nointerlineskip
+ \ebspaceset{belowdisplayskip = 6pt}
\begin{align}
\cos 2x &= \cos^2 x - \sin^2 x \\
&= 2\cos^2 x - 1
@@ -501,7 +502,7 @@
\command{ebaddtofont}[\marg{字体类型}\marg{字体命令}]
用于在上述各种字体原有的格式上附加代码。其中 \meta{字体命令} 也可以包括行距命令且相对于 \module*{space} 模块具有优先性,不同题注的 \meta{字体类型} 则为相应选项的后缀名。
\begin{ctexexam}
- \ebaddtofont{every}{\linespread{1.5}\selectfont}
+ \ebaddtofont{every}{\usestretch{1.5}}
\ebaddtofont{footnote}{\sffamily}
\end{ctexexam}
\end{cnltxlist}
@@ -631,7 +632,7 @@
\subsection[页面尺寸]{页面尺寸\smodule{geo}}
\label{subsec:page margins}
-页面尺寸模块 \module*{geo} 用于设置纸张大小和各种页面边距,它将选项交给页面尺寸宏包 \pkg*{geometry} 处理,并且支持它的键值列表,预置的页面尺寸与 \textsf{Word} 的默认值接近。下面列举几种 \pkg*{geometry} 不同键值输入方式的选项,前面有\hface 符号的选项为额外附加,其它选项可查阅宏包帮助文档。当用此模块设置纸张规格时,会覆盖全局选项 \option{paper} 的设置。
+页面尺寸模块 \module*{geo} 用于设置纸张大小和各种页面边距,它将选项交给页面尺寸宏包 \pkg*{geometry} 处理,支持通用接口 \cs{geometry} 的键值列表,预置的页面尺寸与 \textsf{Word} 的默认值接近。下面列举几种 \pkg*{geometry} 不同键值输入方式的选项,前面有\hface 符号的选项为额外附加,其它选项可查阅宏包帮助文档。当用此模块设置纸张规格时,会覆盖全局选项 \option{paper} 的设置。模块 \module*{geo} 的通用接口命令只能在导言区中使用。
\begin{cnltxlist}[itemsep = 0ex]
\keyval{headruleskip}{页眉线间距}\dtag\Default*{0pt}
\keyval{footruleskip}{页脚线间距}\dtag\Default*{3.5pt}
@@ -648,6 +649,29 @@
vcentering
}
\end{ctexexam}
+
+ \pkg*{geometry} 宏包支持在文档中部改变页面尺寸,提供了新建和保存页面布局的命令。需要注意的是,\pkg*{fancyhdr} 宏包配置页面标记是以文档开始的页面尺寸为参考,若中途更改页面布局后需用标记偏移命令 \cs{fancyhfoffset} 重置参考的尺寸,以确保标记位置正确。
+ \command{newgeometry}[\marg{键值列表}]
+ 在正文中更改页面布局,\meta{键值列表} 为 \pkg*{geometry} 宏包通用接口的各种页面尺寸选项。
+ \command{restoregeometry}
+ 恢复正文开始时的页面布局。
+ \command{savegeometry}[\marg{布局名}]
+ 保存当前页面布局名为 \meta{布局名}。
+ \command{loadgeometry}[\marg{布局名}]
+ 载入保存的名为 \meta{布局名} 的页面布局。
+ \begin{ctexexam}
+ L1
+ \newgeometry{left = 3cm,right = 1cm,bottom = 0.1cm}
+ \savegeometry{L2}
+ L2 (new, saved)
+ \restoregeometry
+ L1 (restored)
+ \newgeometry{margin = 1cm,includefoot}
+ L3 (new)
+ \loadgeometry{L2}
+ \fancyhfoffset{0pt}
+ L2 (loaded)
+ \end{ctexexam}
\end{cnltxlist}
\subsection[图表题注]{图表题注\smodule{cap}}
@@ -720,6 +744,8 @@
\ebhdrset{headrule = {}}
}
\end{ctexexam}
+ \command{pagestyle}[\marg{风格名}]\Default{fancy}
+ 设置 \meta{风格名} 为当前及之后页的页面风格。
\command{fancyhead}[\oarg{位置}\marg{内容}]\default{}
\command{fancyfoot}[\oarg{位置}\marg{内容}]
为了确保页面显示正确,使用 \cs{fancyhead} 和 \cs{fancyfoot} 等命令设置页眉页脚时需要在页边距的命令之后。默认设置的是一个名为 \code{fancy} 的页面风格。\pkg*{fancyhdr} 将页眉页脚分成了左中右和奇数页(odd)、偶数页(even)共12个部分,可选参数中 \code{E} 和 \code{O} 代表偶数和奇数,\code{L}、\code{C} 和 \code{R} 代表左、中和右部分。单面打印时,含有偶数位置的命令无效。
@@ -986,7 +1012,7 @@
\command{DeclareInstance}[\Marg{easybook}\marg{位置}\Marg{cover}\marg{键值列表}]
封面模板可用 \pkg*{xtemplate} 提供的实例声明命令进行自由定制,\ref{exam:cover instance} 举例说明了定制页面中部的内容。模板由页面上、中和下三个位置的实例组成,它们的 \meta{位置} 名字分别为 \code{top}、\code{middle} 和 \code{bottom}。每个实例的属性可用 \meta{键值列表} 修改,包含的选项如下:
\keyval{content}{实例内容}
- 设置实例内容,可以包含任何记号列表。通常为格式和排版内容的命令,在局部生效。
+ 设置实例内容,可以包含任何记号列表。通常为格式和排版内容的命令,作用范围为局部。
\keyval{beforecode}{实例前代码}
设置实例内容前的代码,可以包含任何记号列表。通常为换页和垂直距离的命令。
\keyval{aftercode}{实例后代码}
Modified: trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/source/latex/easybook/easybook.dtx 2024-09-24 20:30:44 UTC (rev 72372)
@@ -14,7 +14,7 @@
% This work has the LPPL maintenance status `maintained'.
%<class|package>\NeedsTeXFormat{LaTeX2e}[2021/11/15]
%<*class>
-\ProvidesExplClass{easybook}{2024/09/22}{2024dt}
+\ProvidesExplClass{easybook}{2024/09/24}{2024dx}
{Easily typesetting Chinese theses or books}
\bool_new:N \l__eb_compile_draft_bool
@@ -301,7 +301,7 @@
%</class>
%<*package>
\RequirePackage{etoolbox}
-\ProvidesExplPackage{easybase}{2024/09/22}{2024dt}
+\ProvidesExplPackage{easybase}{2024/09/24}{2024dx}
{Easily typesetting Chinese theses or books}
\cs_generate_variant:Nn \dim_set:Nn { NV }
@@ -416,7 +416,7 @@
\eb_put_geometry:n { twoside = false }
\boolfalse{@titlepage}
},
- class .initial:n = book,
+ class .initial:x = \ifbool{@titlepage}{book}{article},
book .meta:n = { class = book },
article .meta:n = { class = article },
unknown .code:n = \clist_gput_right:NV \g__eb_ctex_options_clist \CurrentOption
@@ -2071,6 +2071,7 @@
\edef\baselinestretch{#1}
\@currsize
}
+\cs_set_eq:NN \setspread \usestretch
\cs_new_protected:Npn \restore at usespace
{
\par
@@ -2834,7 +2835,7 @@
}
%</package>
%<*tcolorbox>
-\ProvidesExplFile{eb-tcolorbox.cfg}{2024/09/22}{2024dt}
+\ProvidesExplFile{eb-tcolorbox.cfg}{2024/09/24}{2024dx}
{Customization of tcolorbox for easybook}
\cs_set_protected:Npn \addtotcbstyle #1#2
Modified: trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/tex/latex/easybook/easybase.sty 2024-09-24 20:30:44 UTC (rev 72372)
@@ -20,7 +20,7 @@
%% This work has the LPPL maintenance status `maintained'.
\NeedsTeXFormat{LaTeX2e}[2021/11/15]
\RequirePackage{etoolbox}
-\ProvidesExplPackage{easybase}{2024/09/22}{2024dt}
+\ProvidesExplPackage{easybase}{2024/09/24}{2024dx}
{Easily typesetting Chinese theses or books}
\cs_generate_variant:Nn \dim_set:Nn { NV }
@@ -135,7 +135,7 @@
\eb_put_geometry:n { twoside = false }
\boolfalse{@titlepage}
},
- class .initial:n = book,
+ class .initial:x = \ifbool{@titlepage}{book}{article},
book .meta:n = { class = book },
article .meta:n = { class = article },
unknown .code:n = \clist_gput_right:NV \g__eb_ctex_options_clist \CurrentOption
@@ -1790,6 +1790,7 @@
\edef\baselinestretch{#1}
\@currsize
}
+\cs_set_eq:NN \setspread \usestretch
\cs_new_protected:Npn \restore at usespace
{
\par
Modified: trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/tex/latex/easybook/easybook.cls 2024-09-24 20:30:44 UTC (rev 72372)
@@ -19,7 +19,7 @@
%%
%% This work has the LPPL maintenance status `maintained'.
\NeedsTeXFormat{LaTeX2e}[2021/11/15]
-\ProvidesExplClass{easybook}{2024/09/22}{2024dt}
+\ProvidesExplClass{easybook}{2024/09/24}{2024dx}
{Easily typesetting Chinese theses or books}
\bool_new:N \l__eb_compile_draft_bool
Modified: trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg
===================================================================
--- trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg 2024-09-24 17:27:30 UTC (rev 72371)
+++ trunk/Master/texmf-dist/tex/latex/easybook/eb-tcolorbox.cfg 2024-09-24 20:30:44 UTC (rev 72372)
@@ -18,7 +18,7 @@
%% LaTeX version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status `maintained'.
-\ProvidesExplFile{eb-tcolorbox.cfg}{2024/09/22}{2024dt}
+\ProvidesExplFile{eb-tcolorbox.cfg}{2024/09/24}{2024dx}
{Customization of tcolorbox for easybook}
\cs_set_protected:Npn \addtotcbstyle #1#2
More information about the tex-live-commits
mailing list.