diff options
author | Karl Berry <karl@freefriends.org> | 2024-06-30 20:09:15 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2024-06-30 20:09:15 +0000 |
commit | 0e025c558649daf6147cdf24100bc73cad0cb724 (patch) | |
tree | ddbeb9d44789fc9d46275ddf45053048a6e3918b /Master/texmf-dist/tex/latex/beautybook | |
parent | 1479a6f8e6814cc9789542f4780c208d8cc6a1d3 (diff) |
beautybook (30jun24)
git-svn-id: svn://tug.org/texlive/trunk@71660 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/beautybook')
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/beautybook-CN.cls (renamed from Master/texmf-dist/tex/latex/beautybook/Beautybook-CN.cls) | 231 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/beautybook-EN.cls (renamed from Master/texmf-dist/tex/latex/beautybook/Beautybook-EN.cls) | 117 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/stys/beautybook-bottompage.sty (renamed from Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-bottompage.sty) | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-birkar.sty (renamed from Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-birkar.sty) | 118 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-cn.sty (renamed from Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-cn.sty) | 28 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-en.sty (renamed from Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-en.sty) | 6 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-enfig.sty (renamed from Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-enfig.sty) | 5 |
7 files changed, 333 insertions, 174 deletions
diff --git a/Master/texmf-dist/tex/latex/beautybook/Beautybook-CN.cls b/Master/texmf-dist/tex/latex/beautybook/beautybook-CN.cls index d3ab12a333e..49f94464bf6 100644 --- a/Master/texmf-dist/tex/latex/beautybook/Beautybook-CN.cls +++ b/Master/texmf-dist/tex/latex/beautybook/beautybook-CN.cls @@ -1,14 +1,12 @@ %This Class is based on the default book class and options will be passed \NeedsTeXFormat{LaTeX2e} -\ProvidesClass{Beautybook-CN}[02-10-2023 V8.0 Beautybook Class] +\ProvidesClass{beautybook-CN}[30-06-2024 V10.0 Beautybook Class] \DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexbook}} \ProcessOptions\relax \LoadClass[twoside,a4paper]{ctexbook} \RequirePackage[dvipsnames,svgnames,x11names,table]{xcolor} \RequirePackage{cncolours} -\setmainfont{Times New Roman} -\setsansfont{HONOR Sans} -\setmonofont{Latin Modern Mono} +\usepackage{fontspec} \colorlet{outermarginfgcolor}{DarkCyan} % foregroundcolor 较深 \colorlet{outermarginbgcolor}{DarkCyan!30} % backgroundcolor 较浅 \RequirePackage{bropd} % math 自适应数学括号命令 \br{} !!! @@ -21,64 +19,68 @@ \RequirePackage{pgfplots} %画图 %%页面样式设计核心包 %提供\pgfonlayer命令以及下列图层指令 \pgfplotsset{compat=1.18} % +% /* -------------------------------------------------------------------------- */ +% /* 解决birkar封面不能用于a4paper问题 */ +% /* -------------------------------------------------------------------------- */ +\makeatletter +\ExplSyntaxOn +\cs_new:Npn \ifaivpaper@TF + { + \bool_lazy_and:nnTF + { \dim_compare_p:nNn { 297mm } = { \paperheight } } % 不能是 29.7cm + { \dim_compare_p:nNn { 210mm } = { \paperwidth } } + } +\ExplSyntaxOff +% \ifaivpaper@TF{a4paper内容}{not a4paper内容} % 这个用在想要判断a4paper的地方 +\makeatother +% /* -------------------------------------------------------------------------- */ +% /* 解决birkar封面不能用于a4paper问题 */ +% /* -------------------------------------------------------------------------- */ \ExplSyntaxOn % 封面切换程序 (LaTeX3)! -\keys_define:nn {Beautybook/coverstyle} +\keys_define:nn {beautybook/coverstyle} { cover-choose.choice:, cover-choose.value_required:n = true, - cover-choose/cn.code:n = {\RequirePackage{stys/Beautybook-cover-cn}}, - cover-choose/en.code:n = {\RequirePackage{stys/Beautybook-cover-en}}, - cover-choose/enfig.code:n = {\RequirePackage{stys/Beautybook-cover-enfig}}, - cover-choose/birkar.code:n = {\RequirePackage{stys/Beautybook-cover-birkar}}, + cover-choose/cn.code:n = {\RequirePackage{stys/beautybook-cover-cn}}, + cover-choose/en.code:n = {\RequirePackage{stys/beautybook-cover-en}}, + cover-choose/enfig.code:n = {\RequirePackage{stys/beautybook-cover-enfig}}, + cover-choose/birkar.code:n = {\RequirePackage{stys/beautybook-cover-birkar}}, %cover-choose .initial:n = en , % 设置 en 为初始值 } -\newtoks \l__Beautybook_tmpa_toks +\newtoks \l__beautybook_tmpa_toks \cs_new_protected:Npn \coverstyle { - \tex_afterassignment:D \__Beautybook_set_coverstyle: - \l__Beautybook_tmpa_toks + \tex_afterassignment:D \__beautybook_set_coverstyle: + \l__beautybook_tmpa_toks } -\cs_new:Npn \__Beautybook_set_coverstyle: - { \keys_set:nV { Beautybook / coverstyle } \l__Beautybook_tmpa_toks } +\cs_new:Npn \__beautybook_set_coverstyle: + { \keys_set:nV { beautybook / coverstyle } \l__beautybook_tmpa_toks } % Math fonts -\keys_define:nn {Beautybook/mathstyle} +\keys_define:nn {beautybook/mathstyle} { math-font.choice:, math-font.value_required:n = true, - math-font/plain.code:n={}, - math-font/stix.code:n={ - \RequirePackage{stix} - }, + math-font/plain.code:n={ + \RequirePackage{amssymb,amsfonts,upgreek} + }, math-font/mtpro2.code:n = { + \RequirePackage{amssymb,amsfonts,upgreek} + \let\Bbbk\relex \RequirePackage{mtpro2} \RequirePackage{bm} - \DeclareFontFamily{U}{nxlmi}{} - \DeclareFontSubstitution{U}{nxlmi}{m}{it} - \DeclareFontShape{U}{nxlmi}{m}{it}{ - <-6.3> nxlmi05 - <6.3-8.6> nxlmi07 - <8.6-> nxlmi0 - }{} - - \DeclareFontShape{U}{nxlmi}{b}{it}{ - <-6.3> nxlbmi05 - <6.3-8.6> nxlbmi07 - <8.6-> nxlbmi0 - }{} - \renewcommand{\partial}{{\text{\usefont{U}{nxlmi}{m}{it}\symbol{64}}\mspace{1mu}}} }, %cover-choose .initial:n = plain , % 设置 en 为初始值 } \cs_new_protected:Npn \mathstyle { - \tex_afterassignment:D \__Beautybook_set_mathstyle: - \l__Beautybook_tmpa_toks + \tex_afterassignment:D \__beautybook_set_mathstyle: + \l__beautybook_tmpa_toks } -\cs_new:Npn \__Beautybook_set_mathstyle: - { \keys_set:nV { Beautybook / mathstyle } \l__Beautybook_tmpa_toks } +\cs_new:Npn \__beautybook_set_mathstyle: + { \keys_set:nV { beautybook / mathstyle } \l__beautybook_tmpa_toks } \ExplSyntaxOff -\RequirePackage{stys/Beautybook-bottompage} %封底 +\RequirePackage{stys/beautybook-bottompage} %封底 \RequirePackage{rotating} \tikzset{>=Stealth} \setlist{font=\upshape} % 取消所有列表默认距离 nosep, @@ -110,7 +112,6 @@ \RequirePackage{appendix} % 附录 % \RequirePackage{stys/symbols} % -\RequirePackage{amssymb,amsfonts,upgreek} \RequirePackage{makeidx} \RequirePackage{etoolbox} % 判断函数 \RequirePackage{paracol} @@ -300,38 +301,38 @@ fuzzy shadow={0.4mm}{-0.4mm}{0mm}{0.2mm}{fill=white!40!gray},%下 \makeatletter % titleimage \ExplSyntaxOn -\seq_new:N \g__Beautybook_chapter_oimage_seq % odd -\seq_new:N \g__Beautybook_chapter_eimage_seq % even -\seq_new:N \g__Beautybook_part_oimage_seq % odd -\seq_new:N \g__Beautybook_part_eimage_seq % even +\seq_new:N \g__beautybook_chapter_oimage_seq % odd +\seq_new:N \g__beautybook_chapter_eimage_seq % even +\seq_new:N \g__beautybook_part_oimage_seq % odd +\seq_new:N \g__beautybook_part_eimage_seq % even % -\keys_define:nn { Beautybook/titleimage } +\keys_define:nn { beautybook/titleimage } { chapteroddimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_chapter_oimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_chapter_oimage_seq {#1} , chapterevenimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_chapter_eimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_chapter_eimage_seq {#1} , partoddimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_part_oimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_part_oimage_seq {#1} , partevenimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_part_eimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_part_eimage_seq {#1} , } -\cs_new:Npn \__Beautybook_title_image:Nn #1#2 % image seq, number +\cs_new:Npn \__beautybook_title_image:Nn #1#2 % image seq, number { \seq_item:Nn #1 { \int_mod:nn {#2} { \seq_count:N #1 } + 1 } } %对照表-对录入的字符串进行编号 -\cs_new:Npn \Beautybook@chapterimagename %生成索契表 : 判断奇偶数页并按(章节编号)!!读取相应的列表组中的字符串 +\cs_new:Npn \beautybook@chapterimagename %生成索契表 : 判断奇偶数页并按(章节编号)!!读取相应的列表组中的字符串 { \int_if_odd:nTF { \value{page} } - { \__Beautybook_title_image:Nn \g__Beautybook_chapter_oimage_seq { \value{chapter} } } - { \__Beautybook_title_image:Nn \g__Beautybook_chapter_eimage_seq { \value{chapter} } } + { \__beautybook_title_image:Nn \g__beautybook_chapter_oimage_seq { \value{chapter} } } + { \__beautybook_title_image:Nn \g__beautybook_chapter_eimage_seq { \value{chapter} } } } -\cs_new:Npn \Beautybook@partimagename +\cs_new:Npn \beautybook@partimagename { \int_if_odd:nTF { \value{page} } - { \__Beautybook_title_image:Nn \g__Beautybook_part_oimage_seq { \value{part} } } - { \__Beautybook_title_image:Nn \g__Beautybook_part_eimage_seq { \value{part} } } + { \__beautybook_title_image:Nn \g__beautybook_part_oimage_seq { \value{part} } } + { \__beautybook_title_image:Nn \g__beautybook_part_eimage_seq { \value{part} } } } \cs_new_protected:Npn \titleimage #1 - { \keys_set:nn { Beautybook/titleimage } {#1} } + { \keys_set:nn { beautybook/titleimage } {#1} } \ExplSyntaxOff %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \titleformat{\chapter}{\huge\bfseries\filcenter}{}{1em}{ @@ -398,14 +399,14 @@ fuzzy shadow={0.4mm}{-0.4mm}{0mm}{0.2mm}{fill=white!40!gray},%下 \end{pgfonlayer} \ifodd\value{page} \begin{pgfonlayer}{top} - \node[above left,font=\sc\fontsize{25pt}{25pt}\selectfont,align=center] (contents name) at ([shift={(0cm,-4.45cm)}]current page.north east) {\begin{varwidth}{.7\linewidth}\baselineskip=2ex #1\end{varwidth}}; + \node[above left,font=\sc\fontsize{25pt}{25pt}\selectfont,align=center] (contents name) at ([shift={(0cm,-4.45cm)}]current page.north east) {\begin{varwidth}{.7\linewidth}\baselineskip=25pt #1\end{varwidth}}; \end{pgfonlayer} \begin{pgfonlayer}{bottom} \node[right] (image) at ([shift={(-0.5cm,-2.8cm)}]current page.north west) {\includegraphics[width=7cm]{\@chapimage}}; \end{pgfonlayer} \else \begin{pgfonlayer}{top} - \node[above right,font=\sc\fontsize{25pt}{25pt}\selectfont,align=center] (contents name) at ([shift={(0cm,-4.45cm)}]current page.north west) {\begin{varwidth}{.7\linewidth}\baselineskip=2ex #1\end{varwidth}}; + \node[above right,font=\sc\fontsize{25pt}{25pt}\selectfont,align=center] (contents name) at ([shift={(0cm,-4.45cm)}]current page.north west) {\begin{varwidth}{.7\linewidth}\baselineskip=25pt #1\end{varwidth}}; \end{pgfonlayer} \begin{pgfonlayer}{background} \node[left] (image) at ([shift={(0.5cm,-2.8cm)}]current page.north east) {\includegraphics[width=7cm]{\@chapimage}}; @@ -419,6 +420,15 @@ fuzzy shadow={0.4mm}{-0.4mm}{0mm}{0.2mm}{fill=white!40!gray},%下 \titlespacing{\chapter}{0pt}{0pt}{70pt} \makeatother % -------- Part定制 +%%定义标题文字长度%% +\newlength{\partstarlen} +%%设置临界长度%% +\newlength{\criticstarlen} +\setlength{\criticstarlen}{\textwidth} +% 定义垂直方向的渐变 +\tikzfading[name=fade bottom to top, + bottom color=transparent!0, % 底部完全透明 + top color=transparent!100] % 顶部不透明 \tikzfading[name=middle, top color=transparent!90, bottom color=transparent!90, middle color=transparent!20] \makeatletter @@ -428,7 +438,8 @@ color=transparent!90, middle color=transparent!20] {\normalfont\huge\filcenter} {} {20pt} -{\begin{tikzpicture}[remember picture,overlay] +{\settowidth{\partstarlen}{\sc\huge #1} % 计算\partabstract的长度并写入到\partstarlen中 + \begin{tikzpicture}[remember picture,overlay] \def\barwidth{2cm} \fill[outermarginbgcolor,opacity=0.6] (current page.north west) rectangle (current page.south east); @@ -448,8 +459,10 @@ color=transparent!90, middle color=transparent!20] \fill[outermarginfgcolor,rounded corners=2pt] (current page.south east) --++(-5pt,0.15cm)--++(-\outermarginwidth+10pt,0) --++(-5pt,-0.15cm)--cycle; % 页码横线 \node[] (hbar) at ($(current page.north)!0.33!(current page.south)$) { \begin{tikzpicture} - \fill[white] - (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line --------------------%% + \fill[outermarginbgcolor!70] + (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line -------------------%% \fill[outermarginbgcolor] (0,-.25cm) rectangle ++(\paperwidth,-.5cm); \fill[outermarginfgcolor] @@ -461,10 +474,19 @@ color=transparent!90, middle color=transparent!20] \end{tikzpicture} }; \node[above,font=\sc\huge,shift={(.33\linewidth,.5\barwidth)}] (partname) at (hbar) {Part\ \thepart}; - \node[below,left,font=\sc\huge,shift={(.146\linewidth,-1.5*\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.8\linewidth}\raggedright\baselineskip=2ex #1 \end{varwidth}}; % 标题名称 + \node[below left,font=\sc\huge,shift={(.146\linewidth,-\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.9\linewidth}\raggedright\baselineskip=25pt #1 \end{varwidth}}; % 标题名称 \begin{pgfonlayer}{background} \node[above,shift={(-.4\linewidth,-4*\barwidth)}] at (partname) {\ifdefvoid{\@partimage}{}{\includegraphics[width=1.2\linewidth]{\@partimage}}}; % 图片位置调整 + % % 应用渐变效果 +\fill[path fading=fade bottom to top, fill=nuanbai] (current page.north west) rectangle ([xshift=-\outermarginwidth]current page.south east); \end{pgfonlayer} +%判断标题文字长度与临界长度的关系 +\ifdim\partstarlen<\criticstarlen +%如果标题长度小于临界长度则使用(hbar)定位 +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\else +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (partcontents) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\fi \else \fill [outermarginfgcolor!20]% (current page.north west) rectangle ++(\outermarginwidth,-\paperheight); @@ -481,8 +503,10 @@ color=transparent!90, middle color=transparent!20] \fill[outermarginfgcolor,rounded corners=2pt] (current page.south west) --++(5pt,0.15cm)--++(\outermarginwidth-10pt,0) --++(5pt,-0.15cm)--cycle; % 页码横线 \node[] (hbar) at ($(current page.north)!0.33!(current page.south)$) { \begin{tikzpicture} - \fill[white] - (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line --------------------%% + \fill[outermarginbgcolor!70] + (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line -------------------%% \fill[outermarginbgcolor] (0,-.25cm) rectangle ++(\paperwidth,-.5cm); \fill[outermarginfgcolor] @@ -494,12 +518,20 @@ color=transparent!90, middle color=transparent!20] \end{tikzpicture} }; \node[above,font=\sc\huge,shift={(-.31\linewidth,.5\barwidth)}] (partname) at (hbar) {Part\ \thepart}; - \node[below right,font=\sc\huge,shift={(-.125\linewidth,-1.2*\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.8\linewidth}\raggedright\baselineskip=2ex #1 \end{varwidth}}; % 标题名称 + \node[below right,font=\sc\huge,shift={(-.125\linewidth,-\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.9\linewidth}\raggedright\baselineskip=25pt #1 \end{varwidth}}; % 标题名称 \begin{pgfonlayer}{background} \node[above,shift={(.35\linewidth,-4*\barwidth)}] at (partname) {\ifdefvoid{\@partimage}{}{\includegraphics[width=1.2\linewidth]{\@partimage}}}; % 图片位置调整 + % % 应用渐变效果 + \fill[path fading=fade bottom to top, fill=nuanbai] (current page.north east) rectangle ([xshift=\outermarginwidth]current page.south west); \end{pgfonlayer} +%判断标题文字长度与临界长度的关系 +\ifdim\partstarlen<\criticstarlen +%如果标题长度小于临界长度则使用(hbar)定位 +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\else +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (partcontents) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\fi \fi - \node[below,,font=\itshape\fontsize{13}{13}\selectfont,shift={(0\linewidth,-1.65*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.85\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 \end{tikzpicture}} \makeatother \assignpagestyle{\part}{empty} @@ -535,6 +567,59 @@ color=transparent!90, middle color=transparent!20] \titlespacing*{\section}{0pt}{3.5ex plus 1ex minus .2ex}{2.3ex plus .2ex} +% /* -------------------------------------------------------------------------- */ +% /* Subsection Style */ +% /* -------------------------------------------------------------------------- */ +\usepackage{pifont} +\newcommand{\subsectionnumstyle}[2]{ +\makebox[0pt][l]{\def\rad{5pt}% +\def\inrad{3pt} + \begin{tikzpicture}[remember picture] + \path[fill=#2,drop shadow={opacity=0.3,shadow xshift=0.5mm,shadow yshift=-0.5mm}]node[append after command={ + % 主体 + ([shift={(\rad,\rad)}]sec.north west) arc[start angle=90, end angle=180, radius=\rad] {[rounded corners=\inrad]--(sec.south west)}--([yshift=-3mm]$(sec.south west)!0.5!(sec.south east)$) {[rounded corners=\inrad]--(sec.south east)} -- (sec.north east) arc[start angle=180, end angle=90, radius=\rad]--cycle + }, + text=white,font=\sffamily\large\bfseries,align=center,inner ysep=1.5mm,inner xsep=1mm] (sec) at (0,0) {\thesubsection}; + % 阴影 + \begin{pgfonlayer}{bottom} + \fill[#2!30!black!70,opacity=0.8] ([xshift=\rad,yshift=\rad]sec.north east) to[out=0,in=-81,looseness=1.5] ([xshift=1.8*\rad]sec.north east)--(sec.north east) |-cycle; + \end{pgfonlayer} + \node[text=black,font=\large,below right] (sectitle) at ([shift={(2mm,6.5mm)}]sec.south east) {\begin{varwidth}{.9\linewidth}\setlength\baselineskip{18pt}#1\end{varwidth}}; + \begin{pgfonlayer}{bottom} + \draw[gray,dashed,opacity=0.5] ([xshift=0]sec.north west) --([xshift=4*\rad]sec.north east); + \end{pgfonlayer} + \end{tikzpicture}} +} + +\newcommand{\subsectionnonumstyle}[2]{ +\makebox[0pt][l]{\def\rad{5pt}% +\def\inrad{3pt} + \begin{tikzpicture}[remember picture] + \path[fill=#2,drop shadow={opacity=0.3,shadow xshift=0.5mm,shadow yshift=-0.5mm}]node[append after command={ + % 主体 + ([shift={(\rad,\rad)}]sec.north west) arc[start angle=90, end angle=180, radius=\rad] {[rounded corners=\inrad]--(sec.south west)}--([yshift=-3mm]$(sec.south west)!0.5!(sec.south east)$) {[rounded corners=\inrad]--(sec.south east)} -- (sec.north east) arc[start angle=180, end angle=90, radius=\rad] --cycle + }, + text=white,font=\sffamily\large\bfseries,align=center,inner ysep=0.5mm,inner xsep=1.5mm] (sec) at (0,0) {\Huge\ding{99}}; + % 阴影 + \begin{pgfonlayer}{bottom} + \fill[#2!30!black!70,opacity=0.8] ([xshift=\rad,yshift=\rad]sec.north east) to[out=0,in=-81,looseness=1.5] ([xshift=1.8*\rad]sec.north east)--(sec.north east) |-cycle; + \end{pgfonlayer} + \node[text=black,font=\large,below right] (sectitle) at ([shift={(2mm,6.5mm)}]sec.south east) {\begin{varwidth}{.9\linewidth}\setlength\baselineskip{18pt}#1\end{varwidth}}; + \begin{pgfonlayer}{bottom} + \draw[gray,dashed,opacity=0.5] (sec.north west) --([xshift=4*\rad]sec.north east); + \end{pgfonlayer} + \end{tikzpicture}} +} +%% -- Subsection +\titleformat{\subsection} +{} +{} +{-.5em} %左右移动\thesection标签位置 +{\subsectionnumstyle{#1}{outermarginfgcolor}} + +\titleformat{name=\subsection,numberless}{}{}{-.5em}{\subsectionnonumstyle{#1}{outermarginfgcolor}} + +% \titlespacing*{\subsection}{0pt}{3.5ex plus 1ex minus .2ex}{2.3ex plus .2ex} %%-------------------------------- SCRLAYER-SCRPAGE -------------------------------------%% %% SIDE-BAR \newlength\chapternumbersize @@ -574,7 +659,7 @@ color=transparent!90, middle color=transparent!20] \newcommand*\outermarginchapternumberbox{% \if@mainmatter \tikzoverlay{ - \shade[top color=outermarginfgcolor!90,bottom color=outermarginbgcolor] + \shade[top color=outermarginfgcolor!90,bottom color=outermarginbgcolor] (\outermarginwidth,-.5\outermarginwidth+2mm) rectangle (0,-1.5\outermarginwidth+2mm); \node[anchor=center,text=white,font=\sffamily\bfseries] at (1/2*\outermarginwidth,-\outermarginwidth+2mm) {\usekomafont{chapternumber}{\botmarks\chapternum}};% } @@ -627,12 +712,24 @@ color=transparent!90, middle color=transparent!20] contents={\color{outermarginbgcolor}\rule{\layerwidth}{\layerheight}} %色彩装饰条 ]{scth.outermargin.bg.even}% %%=============% 页边条颜色 %=======================%% +% /* -------------------------------------------------------------------------- */ +% /* 透明度渐变填充设定 */ +% /* -------------------------------------------------------------------------- */ \tikzfading[name=fade south, top color =transparent!0, bottom color=transparent!80] \tikzfading[name=fade north, top color =transparent!100, bottom color=transparent!0] +\tikzfading[name=fade right, + right color =transparent!100, + left color=transparent!0] +\tikzfading[name=fade left, + left color =transparent!100, + right color=transparent!0] +% /* -------------------------------------------------------------------------- */ +% /* 透明度渐变填充设定 */ +% /* -------------------------------------------------------------------------- */ %偶数页边纹理效果设置 \newcommand{\evensidbardeepcolor}{% \tikzoverlay{ diff --git a/Master/texmf-dist/tex/latex/beautybook/Beautybook-EN.cls b/Master/texmf-dist/tex/latex/beautybook/beautybook-EN.cls index 63e3e038dff..1aa67be4a39 100644 --- a/Master/texmf-dist/tex/latex/beautybook/Beautybook-EN.cls +++ b/Master/texmf-dist/tex/latex/beautybook/beautybook-EN.cls @@ -1,6 +1,6 @@ %This Class is based on the default book class and options will be passed \NeedsTeXFormat{LaTeX2e} -\ProvidesClass{Beautybook-EN}[02-10-2023 V8.0 Beautybook Class] +\ProvidesClass{beautybook-EN}[30-06-2024 V10.0 beautybook Class] \DeclareOption*{\PassOptionsToClass{\CurrentOption}{book}} \ProcessOptions\relax \LoadClass[twoside]{book} @@ -24,26 +24,26 @@ % \ExplSyntaxOn % 封面切换程序 (LaTeX3)! -\keys_define:nn {Beautybook/coverstyle} +\keys_define:nn {beautybook/coverstyle} { cover-choose.choice:, cover-choose.value_required:n = true, - cover-choose/cn.code:n = {\RequirePackage{stys/Beautybook-cover-cn}}, - cover-choose/en.code:n = {\RequirePackage{stys/Beautybook-cover-en}}, - cover-choose/enfig.code:n = {\RequirePackage{stys/Beautybook-cover-enfig}}, - cover-choose/birkar.code:n = {\RequirePackage{stys/Beautybook-cover-birkar}}, + cover-choose/cn.code:n = {\RequirePackage{stys/beautybook-cover-cn}}, + cover-choose/en.code:n = {\RequirePackage{stys/beautybook-cover-en}}, + cover-choose/enfig.code:n = {\RequirePackage{stys/beautybook-cover-enfig}}, + cover-choose/birkar.code:n = {\RequirePackage{stys/beautybook-cover-birkar}}, %cover-choose .initial:n = en , % 设置 en 为初始值 } -\newtoks \l__Beautybook_tmpa_toks +\newtoks \l__beautybook_tmpa_toks \cs_new_protected:Npn \coverstyle { - \tex_afterassignment:D \__Beautybook_set_coverstyle: - \l__Beautybook_tmpa_toks + \tex_afterassignment:D \__beautybook_set_coverstyle: + \l__beautybook_tmpa_toks } -\cs_new:Npn \__Beautybook_set_coverstyle: - { \keys_set:nV { Beautybook / coverstyle } \l__Beautybook_tmpa_toks } +\cs_new:Npn \__beautybook_set_coverstyle: + { \keys_set:nV { beautybook / coverstyle } \l__beautybook_tmpa_toks } % Math fonts -\keys_define:nn {Beautybook/mathstyle} +\keys_define:nn {beautybook/mathstyle} { math-font.choice:, math-font.value_required:n = true, @@ -73,13 +73,13 @@ } \cs_new_protected:Npn \mathstyle { - \tex_afterassignment:D \__Beautybook_set_mathstyle: - \l__Beautybook_tmpa_toks + \tex_afterassignment:D \__beautybook_set_mathstyle: + \l__beautybook_tmpa_toks } -\cs_new:Npn \__Beautybook_set_mathstyle: - { \keys_set:nV { Beautybook / mathstyle } \l__Beautybook_tmpa_toks } +\cs_new:Npn \__beautybook_set_mathstyle: + { \keys_set:nV { beautybook / mathstyle } \l__beautybook_tmpa_toks } \ExplSyntaxOff -\RequirePackage{stys/Beautybook-bottompage} %封底 +\RequirePackage{stys/beautybook-bottompage} %封底 \RequirePackage{rotating} \tikzset{>=Stealth} \setlist{font=\upshape} % 取消所有列表默认距离 nosep, @@ -301,38 +301,38 @@ fuzzy shadow={0.4mm}{-0.4mm}{0mm}{0.2mm}{fill=white!40!gray},%下 \makeatletter % titleimage \ExplSyntaxOn -\seq_new:N \g__Beautybook_chapter_oimage_seq % odd -\seq_new:N \g__Beautybook_chapter_eimage_seq % even -\seq_new:N \g__Beautybook_part_oimage_seq % odd -\seq_new:N \g__Beautybook_part_eimage_seq % even +\seq_new:N \g__beautybook_chapter_oimage_seq % odd +\seq_new:N \g__beautybook_chapter_eimage_seq % even +\seq_new:N \g__beautybook_part_oimage_seq % odd +\seq_new:N \g__beautybook_part_eimage_seq % even % -\keys_define:nn { Beautybook/titleimage } +\keys_define:nn { beautybook/titleimage } { chapteroddimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_chapter_oimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_chapter_oimage_seq {#1} , chapterevenimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_chapter_eimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_chapter_eimage_seq {#1} , partoddimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_part_oimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_part_oimage_seq {#1} , partevenimage .code:n = - \seq_gset_from_clist:Nn \g__Beautybook_part_eimage_seq {#1} , + \seq_gset_from_clist:Nn \g__beautybook_part_eimage_seq {#1} , } -\cs_new:Npn \__Beautybook_title_image:Nn #1#2 % image seq, number +\cs_new:Npn \__beautybook_title_image:Nn #1#2 % image seq, number { \seq_item:Nn #1 { \int_mod:nn {#2} { \seq_count:N #1 } + 1 } } %对照表-对录入的字符串进行编号 -\cs_new:Npn \Beautybook@chapterimagename %生成索契表 : 判断奇偶数页并按(章节编号)!!读取相应的列表组中的字符串 +\cs_new:Npn \beautybook@chapterimagename %生成索契表 : 判断奇偶数页并按(章节编号)!!读取相应的列表组中的字符串 { \int_if_odd:nTF { \value{page} } - { \__Beautybook_title_image:Nn \g__Beautybook_chapter_oimage_seq { \value{chapter} } } - { \__Beautybook_title_image:Nn \g__Beautybook_chapter_eimage_seq { \value{chapter} } } + { \__beautybook_title_image:Nn \g__beautybook_chapter_oimage_seq { \value{chapter} } } + { \__beautybook_title_image:Nn \g__beautybook_chapter_eimage_seq { \value{chapter} } } } -\cs_new:Npn \Beautybook@partimagename +\cs_new:Npn \beautybook@partimagename { \int_if_odd:nTF { \value{page} } - { \__Beautybook_title_image:Nn \g__Beautybook_part_oimage_seq { \value{part} } } - { \__Beautybook_title_image:Nn \g__Beautybook_part_eimage_seq { \value{part} } } + { \__beautybook_title_image:Nn \g__beautybook_part_oimage_seq { \value{part} } } + { \__beautybook_title_image:Nn \g__beautybook_part_eimage_seq { \value{part} } } } \cs_new_protected:Npn \titleimage #1 - { \keys_set:nn { Beautybook/titleimage } {#1} } + { \keys_set:nn { beautybook/titleimage } {#1} } \ExplSyntaxOff %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \titleformat{\chapter}{\huge\bfseries\filcenter}{}{1em}{ @@ -420,6 +420,15 @@ fuzzy shadow={0.4mm}{-0.4mm}{0mm}{0.2mm}{fill=white!40!gray},%下 \titlespacing{\chapter}{0pt}{0pt}{80pt} \makeatother % -------- Part定制 +%%定义标题文字长度%% +\newlength{\partstarlen} +%%设置临界长度%% +\newlength{\criticstarlen} +\setlength{\criticstarlen}{\textwidth} +% 定义垂直方向的渐变 +\tikzfading[name=fade bottom to top, + bottom color=transparent!0, % 底部完全透明 + top color=transparent!100] % 顶部不透明 \tikzfading[name=middle, top color=transparent!90, bottom color=transparent!90, middle color=transparent!20] \makeatletter @@ -429,7 +438,8 @@ color=transparent!90, middle color=transparent!20] {\normalfont\huge\filcenter} {} {20pt} -{\begin{tikzpicture}[remember picture,overlay] +{\settowidth{\partstarlen}{\sc\huge #1} % 计算\partabstract的长度并写入到\partstarlen中 + \begin{tikzpicture}[remember picture,overlay] \def\barwidth{2cm} \fill[outermarginbgcolor,opacity=0.6] (current page.north west) rectangle (current page.south east); @@ -449,8 +459,10 @@ color=transparent!90, middle color=transparent!20] \fill[outermarginfgcolor,rounded corners=2pt] (current page.south east) --++(-5pt,0.15cm)--++(-\outermarginwidth+10pt,0) --++(-5pt,-0.15cm)--cycle; % 页码横线 \node[] (hbar) at ($(current page.north)!0.33!(current page.south)$) { \begin{tikzpicture} - \fill[white] - (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line --------------------%% + \fill[outermarginbgcolor!70] + (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line -------------------%% \fill[outermarginbgcolor] (0,-.25cm) rectangle ++(\paperwidth,-.5cm); \fill[outermarginfgcolor] @@ -462,10 +474,19 @@ color=transparent!90, middle color=transparent!20] \end{tikzpicture} }; \node[above,font=\sc\huge,shift={(.33\linewidth,.5\barwidth)}] (partname) at (hbar) {Part\ \thepart}; - \node[below,left,font=\sc\huge,shift={(.146\linewidth,-1.5*\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.8\linewidth}\raggedright\baselineskip=2ex #1 \end{varwidth}}; % 标题名称 + \node[below left,font=\sc\huge,shift={(.146\linewidth,-\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.9\linewidth}\raggedright\baselineskip=25pt #1 \end{varwidth}}; % 标题名称 \begin{pgfonlayer}{background} \node[above,shift={(-.4\linewidth,-4*\barwidth)}] at (partname) {\ifdefvoid{\@partimage}{}{\includegraphics[width=1.2\linewidth]{\@partimage}}}; % 图片位置调整 + % % 应用渐变效果 +\fill[path fading=fade bottom to top, fill=nuanbai] (current page.north west) rectangle ([xshift=-\outermarginwidth]current page.south east); \end{pgfonlayer} +%判断标题文字长度与临界长度的关系 +\ifdim\partstarlen<\criticstarlen +%如果标题长度小于临界长度则使用(hbar)定位 +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\else +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (partcontents) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\fi \else \fill [outermarginfgcolor!20]% (current page.north west) rectangle ++(\outermarginwidth,-\paperheight); @@ -482,8 +503,10 @@ color=transparent!90, middle color=transparent!20] \fill[outermarginfgcolor,rounded corners=2pt] (current page.south west) --++(5pt,0.15cm)--++(\outermarginwidth-10pt,0) --++(5pt,-0.15cm)--cycle; % 页码横线 \node[] (hbar) at ($(current page.north)!0.33!(current page.south)$) { \begin{tikzpicture} - \fill[white] - (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line --------------------%% + \fill[outermarginbgcolor!70] + (0,0) rectangle ++(\paperwidth,-1cm); + %%--------------- Horizontal Line -------------------%% \fill[outermarginbgcolor] (0,-.25cm) rectangle ++(\paperwidth,-.5cm); \fill[outermarginfgcolor] @@ -495,12 +518,20 @@ color=transparent!90, middle color=transparent!20] \end{tikzpicture} }; \node[above,font=\sc\huge,shift={(-.31\linewidth,.5\barwidth)}] (partname) at (hbar) {Part\ \thepart}; - \node[below right,font=\sc\huge,shift={(-.125\linewidth,-1.2*\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.8\linewidth}\raggedright\baselineskip=2ex #1 \end{varwidth}}; % 标题名称 + \node[below right,font=\sc\huge,shift={(-.125\linewidth,-\barwidth)}] (partcontents) at (partname) {\begin{varwidth}{.9\linewidth}\raggedright\baselineskip=25pt #1 \end{varwidth}}; % 标题名称 \begin{pgfonlayer}{background} \node[above,shift={(.35\linewidth,-4*\barwidth)}] at (partname) {\ifdefvoid{\@partimage}{}{\includegraphics[width=1.2\linewidth]{\@partimage}}}; % 图片位置调整 + % % 应用渐变效果 + \fill[path fading=fade bottom to top, fill=nuanbai] (current page.north east) rectangle ([xshift=\outermarginwidth]current page.south west); \end{pgfonlayer} +%判断标题文字长度与临界长度的关系 +\ifdim\partstarlen<\criticstarlen +%如果标题长度小于临界长度则使用(hbar)定位 +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\else +\node[below,font=\itshape\fontsize{13}{13}\selectfont,shift={(0,-1.2*\barwidth)}] at (partcontents) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.9\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 +\fi \fi - \node[below,,font=\itshape\fontsize{13}{13}\selectfont,shift={(0\linewidth,-1.65*\barwidth)}] at (hbar) {\ifdefvoid{\@partabstract}{}{\begin{varwidth}{.85\linewidth}\baselineskip=3ex \@partabstract\end{varwidth}}}; % 简介文字调整 \end{tikzpicture}} \makeatother \assignpagestyle{\part}{empty} @@ -1143,7 +1174,7 @@ anchor=west,rounded corners=3pt,font=\bfseries\normalsize] at ([xshift=0cm,yshif bodyfont=\normalfont, postheadspace=.5em, headpunct={.}, - qed=$\blacksquare$,%\qedsymbol + qed=\color{cyan!40!black}$\blacksquare$,%\qedsymbol ]{Proofstyle} \declaretheorem[style=Proofstyle,numbered=no,name={\itbf{Proof}}]{Proof} \renewenvironment{proof}{\begin{Proof} }{\end{Proof}} diff --git a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-bottompage.sty b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-bottompage.sty index 892cf4fbac0..069dc61f60f 100644 --- a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-bottompage.sty +++ b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-bottompage.sty @@ -1,5 +1,5 @@ \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{stys/Beautybook-bottompage}[2023/01/18,v2.0] +\ProvidesPackage{stys/beautybook-bottompage}[2024/06/30,v2.0] \usepackage[ISBN=978-80-85955-35-4,SC0]{ean13isbn} \makeatletter %%----------------------------------封面信息定义--------------------------------------------------------%% diff --git a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-birkar.sty b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-birkar.sty index 8a2c51aa082..4253b6a3a0e 100644 --- a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-birkar.sty +++ b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-birkar.sty @@ -1,5 +1,5 @@ \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{stys/Beautybook-cover-birkar}[2022/05/21,v1.0] +\ProvidesPackage{stys/beautybook-cover-birkar}[2024/06/30,v2.0] \usepackage{anyfontsize} % 提供\fontsize{}{}\selectfont命令 \usepackage{etoolbox} %提供自定义封面选项接口 \usepackage[dvipsnames,svgnames,x11names,table]{xcolor}%颜色宏包 % Driver-independent color extensions @@ -33,22 +33,33 @@ decorations.pathmorphing, graphs, quotes, angles, calc, through, backgrounds} % bottom color =transparent!100, top color=transparent!50] \makeatletter -\newcommand*\makecover{ - %% Use the Tikz library positioning and clear the page header and footer - \usetikzlibrary{positioning} - \thispagestyle{empty} - \begin{tikzpicture}[remember picture,overlay] - \begin{pgfonlayer}{bottom} - \fill[coverfgcolor] - (current page.north west) rectangle (current page.south east);% 填充封面背景颜色 (coverbgcolor) - \fill[RED] - ([shift={(2.05cm,0)}]current page.north west) rectangle ([shift={(2.35cm,-6cm)}]current page.north west); - \fill[coverfgcolor!80,opacity=0.5] - ([shift={(0,-2cm)}]current page.north west) arc (90:-90:.3\paperheight) --cycle; - \fill[coverfgcolor!80,opacity=0.5] - ([shift={(0,-4cm)}]current page.north east) arc (90:270:.2\paperheight) --cycle; - \fill[coverfgcolor!80] - (current page.north west) rectangle ([shift={(2cm,0)}]current page.south west); +\newcommand{\aivcover}{ + \begin{scope}[opacity=0.8] + \coordinate (triangleA) at ([shift={(1cm,-1.5cm)}]current page.north); + \coordinate (triangleB) at ([shift={(-.75\linewidth,-.44\paperheight)}]triangleA); + \coordinate (triangleC) at ([shift={(.5\linewidth,-.44\paperheight)}]triangleA); + \draw[name path=triangle,very thick,coverfgcolor!70!white] + (triangleA)--(triangleB)--(triangleC)--cycle; + \draw[name path=circle,very thick,coverfgcolor!70!white] + ([shift={(-1.65cm,-7.8cm)}]triangleA) coordinate (O) circle(6cm); + %标注每个交点坐标 + \fill [name intersections={of=triangle and circle, name=i, total=\t}] + [coverbar,opacity=0.5, every node/.style={above left, white, opacity=1}] + \foreach \s in {1,...,\t}{(i-\s) circle (1em) node {}}; + \draw[name path=l,very thick,coverfgcolor!70!white] (i-1) -- (triangleC); + \draw[very thick,coverfgcolor!70!white] (i-6) -- (triangleB); + \draw[name path=l2,very thick,coverfgcolor!70!white] (i-4) -- (triangleA); + \fill[name intersections={of=l and circle,name=j,total=\l}] + [coverbar,opacity=0.5, every node/.style={above left, white, opacity=1}] + \foreach \c in {1,...,\l}{(j-\c) circle (1em) node {}}; + + \fill[name intersections={of=l2 and l,name=jj,total=\ll}] + [coverbar,opacity=0.5, every node/.style={above left, white, opacity=1}] + \foreach \cc in {1,...,\ll}{(jj-\cc) circle (1em) node {}}; + \end{scope} +} + +\newcommand{\lettercover}{ \begin{scope}[opacity=0.8] \coordinate (triangleA) at ([shift={(1cm,-1cm)}]current page.north); \coordinate (triangleB) at ([shift={(-.85\linewidth,-.46\paperheight)}]triangleA); @@ -72,31 +83,54 @@ decorations.pathmorphing, graphs, quotes, angles, calc, through, backgrounds} % [coverbar,opacity=0.5, every node/.style={above left, white, opacity=1}] \foreach \cc in {1,...,\ll}{(jj-\cc) circle (1em) node {}}; \end{scope} - \end{pgfonlayer} - \begin{pgfonlayer}{foreground} - \fill[coverbar,opacity=.5] - ([yshift=2\outermarginwidth]current page.west) rectangle ([xshift=\outermarginwidth,yshift=-.2\outermarginwidth]current page.west); % 最左侧装饰矩形 - \end{pgfonlayer} - \shade[left color=coverfgcolor,right color=coverfgcolor!60,opacity=.3] - ([xshift=\outermarginwidth,yshift=2\outermarginwidth]current page.west) rectangle (current page.south east); % 标题背景大矩形 - \node[anchor=south] at ([xshift=.3\outermarginwidth,yshift=-.4\covershift]current page.north) {% - \parbox{.8\paperwidth}{ - \filright - \color{white}\sffamily\fontsize{20}{23}\selectfont\@bookseries} - }; %系列丛书名称 - \node[ anchor=south] at ([xshift=.3\outermarginwidth,yshift=-.57\paperheight]current page.north) - {\parbox{.8\paperwidth}{% - \raggedright% - {\renewcommand\baselinestretch{1.1}\selectfont \color{white}\sffamily\bfseries\fontsize{40}{40}\selectfont\@title\\[0.5ex] - \color{white}\sffamily\fontsize{30}{30}\selectfont - \ifdefvoid{\@subtitle}{}{\@subtitle}\par} - }};% 封面标题与副标题 - \node[anchor=west,font=\sffamily\fontsize{23}{23}\selectfont,text=white] at ([xshift=1.8\outermarginwidth,yshift=-.6\covershift]current page.west) {\@edition}; - \node[anchor=west,font=\sffamily\Huge,text=white] at ([xshift=1.8\outermarginwidth,yshift=\covershift]current page.west) {\@author}; - \node[left,text=white,font=\rmfamily\Large,] at - ([shift={(-1cm,2cm)}]current page.south east) % - {\raisebox{-1.1cm}{\includegraphics[width=0.2\linewidth]{\@presslogo}}\hspace*{-3.5ex}\begin{varwidth}{.4\textwidth}\tikz\draw[white,line width=1.25pt] (0,0)--++(0,1cm);\,\raisebox{.25cm}{\@pressname} \end{varwidth}};% - \end{tikzpicture}% +} + +\newcommand*\makecover{ + \thispagestyle{empty} + \begin{tikzpicture}[remember picture,overlay] + \begin{pgfonlayer}{bottom} + \fill[coverfgcolor] + (current page.north west) rectangle (current page.south east);% 填充封面背景颜色 (coverbgcolor) + \fill[RED] + ([shift={(2.05cm,0)}]current page.north west) rectangle ([shift={(2.35cm,-6cm)}]current page.north west); + \fill[coverfgcolor!80,opacity=0.5] + ([shift={(0,-2cm)}]current page.north west) arc (90:-90:.3\paperheight) --cycle; + \fill[coverfgcolor!80,opacity=0.5] + ([shift={(0,-4cm)}]current page.north east) arc (90:270:.2\paperheight) --cycle; + \fill[coverfgcolor!80] + (current page.north west) rectangle ([shift={(2cm,0)}]current page.south west); + % /* -------------------------------------------------------------------------- */ + % /* 判断a4paper */ + % /* -------------------------------------------------------------------------- */ + \ifaivpaper@TF{\aivcover}{\lettercover} + % /* -------------------------------------------------------------------------- */ + % /* 判断a4paper */ + % /* -------------------------------------------------------------------------- */ +\end{pgfonlayer} +\begin{pgfonlayer}{foreground} + \fill[coverbar,opacity=.5] +([yshift=2\outermarginwidth]current page.west) rectangle ([xshift=\outermarginwidth,yshift=-.2\outermarginwidth]current page.west); % 最左侧装饰矩形 +\end{pgfonlayer} +\shade[left color=coverfgcolor,right color=coverfgcolor!60,opacity=.3] +([xshift=\outermarginwidth,yshift=2\outermarginwidth]current page.west) rectangle (current page.south east); % 标题背景大矩形 +\node[anchor=south] at ([xshift=.3\outermarginwidth,yshift=-.4\covershift]current page.north) {% +\parbox{.8\paperwidth}{ +\filright +\color{white}\sffamily\fontsize{20}{23}\selectfont\@bookseries} +}; %系列丛书名称 +\node[ anchor=south] at ([xshift=.3\outermarginwidth,yshift=-.57\paperheight]current page.north) +{\parbox{.8\paperwidth}{% + \raggedright% +{\renewcommand\baselinestretch{1.1}\selectfont \color{white}\sffamily\bfseries\fontsize{40}{40}\selectfont\@title\\[0.5ex] + \color{white}\sffamily\fontsize{30}{30}\selectfont + \ifdefvoid{\@subtitle}{}{\@subtitle}\par} +}};% 封面标题与副标题 +\node[anchor=west,font=\sffamily\fontsize{23}{23}\selectfont,text=white] at ([xshift=1.8\outermarginwidth,yshift=-.6\covershift]current page.west) {\@edition}; +\node[anchor=west,font=\sffamily\Huge,text=white] at ([xshift=1.8\outermarginwidth,yshift=\covershift]current page.west) {\@author}; +\node[left,text=white,font=\rmfamily\Large,] at +([shift={(-1cm,2cm)}]current page.south east) % +{\raisebox{-1.1cm}{\includegraphics[width=0.2\linewidth]{\@presslogo}}\hspace*{-3.5ex}\begin{varwidth}{.4\textwidth}\tikz\draw[white,line width=1.25pt] (0,0)--++(0,1cm);\,\raisebox{.25cm}{\@pressname} \end{varwidth}};% +\end{tikzpicture}% {\newpage\thispagestyle{empty}} } \makeatother diff --git a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-cn.sty b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-cn.sty index b151d4e5fc2..176e740f6f3 100644 --- a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-cn.sty +++ b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-cn.sty @@ -1,5 +1,5 @@ \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{stys/Beautybook-cover-cn}[2023/05/10,v1.0] +\ProvidesPackage{stys/beautybook-cover-cn}[2024/06/30,v2.0] \usetikzlibrary{calc,fadings,patterns} \usepackage{adjustbox} %修正minipage顶部对齐问题 %%%%===============================================================%%%%% @@ -13,8 +13,8 @@ left color =transparent!100, right color=transparent!50] \tikzfading[name=fade up, -top color =transparent!100, -bottom color=transparent!50] + top color =transparent!100, + bottom color=transparent!50] \tikzfading[name=fade down, bottom color =transparent!100, top color=transparent!50] @@ -40,7 +40,7 @@ bottom color=transparent!50] \node[right] at ([xshift=\outermarginwidth,yshift=1.5*\covershift]current page.west) {\parbox{.8\paperwidth}{% \filright% - \color{white}\sffamily\bfseries\fontsize{30}{30}\selectfont\@title\\[-1.6ex] + \color{white}\sffamily\bfseries\fontsize{30}{30}\selectfont\@title\\[-1.2ex] \begin{tikzpicture} \draw[white,line width=1pt] (0,0) --++ (\paperwidth-3\outermarginwidth,0); \end{tikzpicture}\\[-.5ex] @@ -64,17 +64,17 @@ bottom color=transparent!50] \end{minipage}} };% 封面作者信息栏 \fill [path picture={ \node at (path picture bounding box.center) - {\includegraphics[height=1.1\linewidth]{\@coverimage}};}] + {\includegraphics[height=1.1\linewidth,keepaspectratio]{\@coverimage}};}] ([xshift=\outermarginwidth]current page.south west) rectangle ++(1.8*\covershift,.575\paperheight); - \fill[pattern color=coverfgcolor!70,pattern=horizontal lines,opacity=0.8] - ([xshift=\outermarginwidth,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); - \fill [coverfgcolor!80,path fading=fade right]% - ([xshift=\outermarginwidth+.5\linewidth+.5cm,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); - \fill [coverfgcolor!80,path fading=fade left]% - ([xshift=\outermarginwidth+.5\linewidth+.5cm,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); - \node[left,text=white,font=\rmfamily\Large,] at - ([shift={(-2cm,2cm)}]current page.south east) % - {\raisebox{-1.1cm}{\includegraphics[width=0.2\linewidth]{\@presslogo}}\hspace*{-3.5ex}\begin{varwidth}{.4\textwidth}\tikz\draw[white,line width=1.25pt] (0,0)--++(0,1cm);\,\raisebox{.25cm}{\@pressname} \end{varwidth}};% + \fill[pattern color=coverfgcolor!70,pattern=horizontal lines,opacity=0.8] + ([xshift=\outermarginwidth,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); + \fill [coverfgcolor!80,path fading=fade right]% + ([xshift=\outermarginwidth+.5\linewidth+.5cm,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); + \fill [coverfgcolor!80,path fading=fade left]% + ([xshift=\outermarginwidth+.5\linewidth+.5cm,yshift=.2\covershift]current page.south west) rectangle ([xshift=-\outermarginwidth,yshift=1.43\covershift]current page.south east); + \node[left,text=white,font=\rmfamily\Large,] at + ([shift={(-2cm,2cm)}]current page.south east) % + {\raisebox{-1.1cm}{\includegraphics[width=0.2\linewidth]{\@presslogo}}\hspace*{-3.5ex}\begin{varwidth}{.4\textwidth}\tikz\draw[white,line width=1.25pt] (0,0)--++(0,1cm);\,\raisebox{.25cm}{\@pressname} \end{varwidth}};% \end{tikzpicture}% {\newpage\thispagestyle{empty}}} \makeatother diff --git a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-en.sty b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-en.sty index 2279661d945..1c868103804 100644 --- a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-en.sty +++ b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-en.sty @@ -1,5 +1,5 @@ \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{stys/Beautybook-cover-en}[2022/05/21,v1.0] +\ProvidesPackage{stys/beautybook-cover-en}[2024/06/30,v2.0] \usepackage{anyfontsize} % 提供\fontsize{}{}\selectfont命令 \usepackage{etoolbox} %提供自定义封面选项接口 \usepackage[dvipsnames,svgnames,x11names,table]{xcolor}%颜色宏包 % Driver-independent color extensions @@ -14,8 +14,8 @@ left color =transparent!100, right color=transparent!50] \tikzfading[name=fade up, - top color =transparent!100, - bottom color=transparent!50] + top color =transparent!100, % 完全透明 + bottom color=transparent!50] % 半透明 \tikzfading[name=fade down, bottom color =transparent!100, top color=transparent!50] diff --git a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-enfig.sty b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-enfig.sty index 005518a6d96..e84129ddea0 100644 --- a/Master/texmf-dist/tex/latex/beautybook/stys/Beautybook-cover-enfig.sty +++ b/Master/texmf-dist/tex/latex/beautybook/stys/beautybook-cover-enfig.sty @@ -1,8 +1,5 @@ \NeedsTeXFormat{LaTeX2e}[1995/12/01] -\ProvidesPackage{stys/Beautybook-cover-enfig}[2023/02/03,v1.0] -\definecolor{coverbgcolor}{HTML}{004183} -\definecolor{coverfgcolor}{HTML}{826e68} -\definecolor{coverbar}{HTML}{7c9092} +\ProvidesPackage{stys/beautybook-cover-enfig}[2024/06/30,v2.0] \tikzfading[name=fade right, right color =transparent!100, left color=transparent!0] |