summaryrefslogtreecommitdiff
path: root/macros/unicodetex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2021-07-06 03:00:52 +0000
committerNorbert Preining <norbert@preining.info>2021-07-06 03:00:52 +0000
commit109a435244c29109322bcd46386301f6c62d4061 (patch)
tree13a621b9870dcf81bf4c6e38410f6ee4b0fb54f3 /macros/unicodetex
parent500adb5fa10a924ea571a0d9d7754ed17dab5dbf (diff)
CTAN sync 202107060300
Diffstat (limited to 'macros/unicodetex')
-rw-r--r--macros/unicodetex/generic/inputnormalization/README.md24
-rw-r--r--macros/unicodetex/generic/inputnormalization/inputnormalization.dtx225
-rw-r--r--macros/unicodetex/generic/inputnormalization/inputnormalization.pdfbin0 -> 88932 bytes
-rw-r--r--macros/unicodetex/generic/inputnormalization/plain.pdfbin0 -> 11332 bytes
-rw-r--r--macros/unicodetex/latex/einfart/einfart-doc-cn.pdfbin238692 -> 243292 bytes
-rw-r--r--macros/unicodetex/latex/einfart/einfart-doc-cn.tex12
-rw-r--r--macros/unicodetex/latex/einfart/einfart-doc-en.pdfbin148163 -> 150231 bytes
-rw-r--r--macros/unicodetex/latex/einfart/einfart-doc-en.tex10
-rw-r--r--macros/unicodetex/latex/einfart/einfart.cls16
-rw-r--r--macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdfbin288667 -> 280225 bytes
-rw-r--r--macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex9
-rw-r--r--macros/unicodetex/latex/simplivre/simplivre-doc-en.pdfbin194593 -> 184576 bytes
-rw-r--r--macros/unicodetex/latex/simplivre/simplivre-doc-en.tex14
-rw-r--r--macros/unicodetex/latex/simplivre/simplivre.cls16
14 files changed, 298 insertions, 28 deletions
diff --git a/macros/unicodetex/generic/inputnormalization/README.md b/macros/unicodetex/generic/inputnormalization/README.md
new file mode 100644
index 0000000000..6d78dfb7b1
--- /dev/null
+++ b/macros/unicodetex/generic/inputnormalization/README.md
@@ -0,0 +1,24 @@
+# The `inputnormalization` package
+Unicode normlization for LuaTeX and XeTeX.
+
+Author: Marcel Krüger
+
+License: LPPL v1.3
+
+Provides a cross engine interface to normalizing input before it's read by TeX. Based on XeTeX's `\XeTeXinputnormalization` primitive and `lua-uni-algos` for LuaTeX.
+
+# Usage
+For LaTeX, just load the `inputnormalization` package with
+
+ \usepackage{inputnormalization}
+
+For plain TeX, use `\input` instead:
+
+ \input inputnormalization
+
+See the manual for more details.
+
+## Support
+For bug reports, please open an [issue on GitHub](https://github.com/zauguin/lua-uni-algos/issues).
+
+
diff --git a/macros/unicodetex/generic/inputnormalization/inputnormalization.dtx b/macros/unicodetex/generic/inputnormalization/inputnormalization.dtx
new file mode 100644
index 0000000000..1ca36d3bf1
--- /dev/null
+++ b/macros/unicodetex/generic/inputnormalization/inputnormalization.dtx
@@ -0,0 +1,225 @@
+% \iffalse meta-comment
+%
+%% Copyright (C) 2020--2021 by Marcel Krueger
+%%
+%% This file may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3 of this license or (at your option) any later
+%% version. The latest version of this license is in:
+%%
+%% http://www.latex-project.org/lppl.txt
+%%
+%% and version 1.3 or later is part of all distributions of
+%% LaTeX version 2005/12/01 or later.
+%
+%<*batch>
+%<*gobble>
+\ifx\jobname\relax\let\documentclass\undefined\fi
+\ifx\documentclass\undefined
+\csname fi\endcsname
+%</gobble>
+\input docstrip.tex
+\keepsilent
+\generate{%
+ \file{inputnormalization.sty}{\from{inputnormalization.dtx}{package}}
+ \file{inputnormalization.tex}{\from{inputnormalization.dtx}{tex-package}}}
+\endbatchfile
+%</batch>
+%<*gobble>
+\fi
+\expandafter\ifx\csname @currname\endcsname\empty
+\csname fi\endcsname
+%</gobble>
+%<*driver>
+\RequirePackage{inputnormalization}
+\documentclass{article}
+\usepackage{csquotes,doc,metalogo,hyperref,luacolor,tikzducks,pict2e}
+\RecordChanges
+\MakeShortVerb\|
+\begin{document}
+\DocInput{inputnormalization.dtx}
+\PrintIndex
+\PrintChanges
+\end{document}
+%</driver>
+%<*gobble>
+\fi
+%</gobble>
+% \fi
+%
+% \GetFileInfo{inputnormalization.sty}
+% \title{The inputnormalization package\thanks{This document
+% corresponds to inputnormalization~\fileversion, dated~\filedate.}}
+% \author{Marcel Kr\"uger \\
+% \href{mailto:tex@2krueger.de}{tex@2krueger.de}}
+%
+% \maketitle
+% Add support for normalising input files for LuaTeX and provide a common interface for \LuaTeX\ and \XeTeX.
+%
+% \section{Motivation}
+% Modern \TeX\ engines like \XeTeX\ or \LuaTeX\ natively accept Unicode input.
+% Unicode is a rather special encoding since many characters can be encoded in
+% different ways which are officially considered equivalent. This can sometimes
+% lead to surprising behavior since many parts of \TeX\ are not aware of this
+% equivalences and therefore treats different encodings as different strings.
+% This can show itself during rendering when some the same text might appear
+% in different ways depending on the input, but it might also show itself in
+% macro or option names: When e.g.\ non-English macro names are in use, the
+% different encodings of the same name can name different macros, leading to
+% hard to understand and solve errors.
+%
+% Unicode defines a mechanism to solve such issues: It defines the normalization
+% forms NFC and NFD. When text is normalized to one of these forms, then two
+% equivalent strings are always encoded in the same way, leading to unique names
+% and consistent rendering.
+%
+% This package provides a uniform way to enable input normalization to either
+% of these forms in both \XeTeX\ and \LuaTeX.
+%
+% \section{Usage}
+% Just loading the package is enough to enable NFC normalization. This is the
+% right option for almost all users:
+%
+% \begin{verbatim}
+% \documentclass{article}
+% \usepackage{inputnormalization}
+% \begin{document}
+% Everything here gets normalized before it's processed by \TeX.
+% \end{document}
+% \end{verbatim}
+%
+% If you are a plain \LuaTeX/\XeTeX\ user, you can use
+%
+% \begin{verbatim}
+% \input inputnormalization
+% Everything here gets normalized before it's processed by \TeX.
+% \bye
+% \end{verbatim}
+% instead.
+%
+% \section{Advanced usage}
+% In addition to enabling NFC normalization by default, the package makes
+% \verb|\Uinputnormalization| available as a cross engine version of
+% \verb|\XeTeXinputnormalization| to make the normalization controllable.
+% See the \XeTeX\ documentation for detailed usage. E.g.\ you could write
+% \begin{verbatim}
+% \documentclass{article}
+% \usepackage{inputnormalization}
+% \begin{document}
+% Everything here gets normalized to NFC before it's processed by \TeX.
+%
+% \Uinputnormalization=0
+% Now normalization is disabled.
+%
+% \Uinputnormalization=2
+% Here we normalize to NFD instead.
+% \end{document}
+% \end{verbatim}
+%
+% \paragraph{Warning:} It is almost never a good idea to use different kinds
+% of normalization in the same document, therefore you should set one kind of
+% normalization directly after loading the package and not modify it afterwards.
+%
+% Additionally NFC works much better in a \TeX\ context than NFD, so you should
+% not set this at all unless you know exactly what you are doing.
+%
+% \StopEventually{}
+% \section{The implementation}
+% \changes{0.0.1}{2020-05-17}{Initial release}
+% \iffalse
+%<*package|tex-package>
+% \fi
+% \begin{macrocode}
+%<*package>
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage
+ {inputnormalization}
+ [2021/07/05 v0.2 Unicode input normalization]
+%</package>
+% \end{macrocode}
+% Only \LuaTeX\ and \XeTeX\ are supported.
+% For other engines we show an error.
+% \begin{macrocode}
+\ifx\directlua\undefined
+\ifx\XeTeXinputnormalization\undefined
+% \end{macrocode}
+% \iffalse
+%<*gobble>
+\iffalse
+%</gobble>
+% \fi \fi
+% \begin{macrocode}
+%<*tex-package>
+ \begingroup
+ \ifx\PackageError\undefined
+ \def\PackageError#1#2#3{\errhelp{#3}\errmessage{#1: #2}}
+ \fi
+%</tex-package>
+% \end{macrocode}
+% \iffalse \iffalse
+%<*gobble>
+\fi
+%</gobble>
+% \fi
+% \begin{macrocode}
+\PackageError{inputnormalization}{LuaTeX or XeTeX required}%
+ {inputnormalization requires LuaTeX or XeTeX.
+ Maybe you forgot to switch the engine in your editor?}
+% \end{macrocode}
+% \iffalse
+%<*gobble>
+\iffalse
+%</gobble>
+% \fi \fi
+% \begin{macrocode}
+%<*tex-package>
+ \endgroup
+%</tex-package>
+% \end{macrocode}
+% \iffalse \iffalse
+%<*gobble>
+\fi
+%</gobble>
+% \fi
+% \begin{macrocode}
+\else
+% \end{macrocode}
+% First deal with \XeTeX: Define |\Uinputnormalization| as an alias for |\XeTeXinputnormalization|.
+% Make sure that \texttt{ltluatex} is loaded.
+% \begin{macrocode}
+ \let\Uinputnormalization\XeTeXinputnormalization
+\fi
+\else
+% \end{macrocode}
+% In \LuaTeX\ we emulate |\Uinputnormalization| using a |process_input_buffer| callback.
+% First ensure that |ltluatex| is loaded to have proper callback handling:
+% \begin{macrocode}
+ \ifx\newluafunction\@undefined
+ \input ltluatex
+ \fi
+% \end{macrocode}
+% We need a integer register to control the normalization and then the actual implementation of the callback.
+% Nothing particularly interesting is happening here, the actual normalization is handled by \texttt{lua-uni-algos}.
+% \begin{macrocode}
+ \newcount\Uinputnormalization
+ \directlua{
+ local getcount = tex.getcount
+ local function ident(buf) return buf end
+ local uni_normalize = require'lua-uni-normalize'
+ local normalize = {[0] = ident, uni_normalize.NFC, uni_normalize.NFD}
+ luatexbase.add_to_callback('process_input_buffer', function(buf)
+ return normalize[getcount(\the\allocationnumber)](buf)
+ end, 'inputnormalization')
+ }
+\fi
+% \end{macrocode}
+% \changes{0.2}{2021-07-05}{Enable NFC by default}
+% Finally we enable NFC normalization as a reasonable default:
+% \begin{macrocode}
+\Uinputnormalization=1
+\endinput
+% \end{macrocode}
+% \iffalse
+%</package|tex-package>
+% \fi
+% \Finale
diff --git a/macros/unicodetex/generic/inputnormalization/inputnormalization.pdf b/macros/unicodetex/generic/inputnormalization/inputnormalization.pdf
new file mode 100644
index 0000000000..18f41669e5
--- /dev/null
+++ b/macros/unicodetex/generic/inputnormalization/inputnormalization.pdf
Binary files differ
diff --git a/macros/unicodetex/generic/inputnormalization/plain.pdf b/macros/unicodetex/generic/inputnormalization/plain.pdf
new file mode 100644
index 0000000000..117d8e6d93
--- /dev/null
+++ b/macros/unicodetex/generic/inputnormalization/plain.pdf
Binary files differ
diff --git a/macros/unicodetex/latex/einfart/einfart-doc-cn.pdf b/macros/unicodetex/latex/einfart/einfart-doc-cn.pdf
index 735f56dba1..2a9a66a48f 100644
--- a/macros/unicodetex/latex/einfart/einfart-doc-cn.pdf
+++ b/macros/unicodetex/latex/einfart/einfart-doc-cn.pdf
Binary files differ
diff --git a/macros/unicodetex/latex/einfart/einfart-doc-cn.tex b/macros/unicodetex/latex/einfart/einfart-doc-cn.tex
index 4b2c5a6f74..b4cee34583 100644
--- a/macros/unicodetex/latex/einfart/einfart-doc-cn.tex
+++ b/macros/unicodetex/latex/einfart/einfart-doc-cn.tex
@@ -40,7 +40,7 @@
\providecommand{\meta}[1]{$\langle${\normalfont\itshape#1}$\rangle$}
\lstset{moretexcs=%
{linenumbers,nolinenumbers,subsection,subsubsection,href,
- color,NameTheorem,CreateTheorem,proofideanameCN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib
+ color,NameTheorem,CreateTheorem,proofideanameCN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,qedhere
}
}
\lstnewenvironment{code}%
@@ -87,8 +87,8 @@
\title{\einfart{},以极简主义风格排版你的文章}
\author{许锦文}
-\thanks{对应版本. \texttt{\einfart{} 2021/06/30}}
-\date{2021年6月,北京}
+\thanks{对应版本. \texttt{\einfart{} 2021/07/05}}
+\date{2021年7月,北京}
\maketitle
@@ -102,7 +102,8 @@
\tableofcontents
-\bigskip
+% \bigskip
+\vspace{-.3\baselineskip}
\begin{tip}
多语言支持、定理类环境、未完成标记等功能是由 \ProjLib{} 工具箱提供的,这里只给出了将其与本文档类搭配使用的要点。如需获取更详细的信息,可以参阅 \ProjLib{} 的说明文档。
\end{tip}
@@ -419,6 +420,9 @@
\end{itemize}
这是标题使用下划线装饰之后带来的一个缺点。
+\subsection{关于QED符号}
+由于定理类环境中的字体和正文字体是一样的,为了方便看出定理类环境在哪里结束,在其结尾处放置了一个空心的QED符号。然而,如果你的定理是由公式或者列表结尾的,这个符号就无法自动地放在正确的位置。这时,你需要手动在公式或列表最后一个条目的后面加上 \lstinline|\qedhere|,以让QED符号显示到这一行的最后。
+
\section{目前存在的问题}
diff --git a/macros/unicodetex/latex/einfart/einfart-doc-en.pdf b/macros/unicodetex/latex/einfart/einfart-doc-en.pdf
index 26af160f13..bbf036b4a8 100644
--- a/macros/unicodetex/latex/einfart/einfart-doc-en.pdf
+++ b/macros/unicodetex/latex/einfart/einfart-doc-en.pdf
Binary files differ
diff --git a/macros/unicodetex/latex/einfart/einfart-doc-en.tex b/macros/unicodetex/latex/einfart/einfart-doc-en.tex
index e50c77ab28..277de1fade 100644
--- a/macros/unicodetex/latex/einfart/einfart-doc-en.tex
+++ b/macros/unicodetex/latex/einfart/einfart-doc-en.tex
@@ -41,7 +41,7 @@
\providecommand{\meta}[1]{$\langle${\normalfont\itshape#1}$\rangle$}
\lstset{moretexcs=%
{linenumbers,nolinenumbers,subsection,subsubsection,href,
- color,NameTheorem,CreateTheorem,proofideanameEN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib
+ color,NameTheorem,CreateTheorem,proofideanameEN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,qedhere
}
}
\lstnewenvironment{code}%
@@ -88,8 +88,8 @@
\title{\einfart{}, write your articles in a simple and clear way}
\author{Jinwen XU}
-\thanks{Corresponding to: \texttt{\einfart{} 2021/06/30}}
-\date{June 2021, Beijing}
+\thanks{Corresponding to: \texttt{\einfart{} 2021/07/05}}
+\date{July 2021, Beijing}
\maketitle
@@ -114,6 +114,7 @@
\subsection{How to load it}
One only needs to put
+
\begin{code}
\documentclass{einfart}
\end{code}
@@ -411,6 +412,9 @@ In \lstinline|\section| or \lstinline|\subsection| , if you wish to add footnote
\end{itemize}
This is a disadvantage brought about by the underline decoration of the title.
+\subsection{On the QED symbols}
+Since the font in the theorem-like environments is the same as that of the main text, in order to indicate where the environments end, a hollow QED symbol \simpleqedsymbol{} is placed at the end of the theorem-like environments. However, if your theorem ends with an equation or list (itemize, enumerate, description, etc.), this symbol cannot be automatically placed in the correct position. In this case, you need to manually add a \lstinline|\qedhere| at the end of your equation or the last entry of your list to make the QED symbol appear at the end of the line.
+
\section{Known issues}
diff --git a/macros/unicodetex/latex/einfart/einfart.cls b/macros/unicodetex/latex/einfart/einfart.cls
index b0c9ae23c3..70a747e367 100644
--- a/macros/unicodetex/latex/einfart/einfart.cls
+++ b/macros/unicodetex/latex/einfart/einfart.cls
@@ -17,7 +17,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[2020-10-01]
\ProvidesClass{einfart}
- [2021/06/30 A simple and clear article style]
+ [2021/07/05 A simple and clear article style]
\def\minimclass@baseclass{article}
\RequirePackage{kvoptions}
\RequirePackage{etoolbox}
@@ -44,6 +44,7 @@
\DeclareDefaultOption{\PassOptionsToClass{\CurrentOption}{\minimclass@baseclass}}
\ProcessKeyvalOptions*\relax
\LoadClass{\minimclass@baseclass}
+
\if@minimclass@draft
\@minimclass@fasttrue
\fi
@@ -110,14 +111,12 @@
%%================================
%% Fonts
%%================================
-%% Math fonts in fast mode
\if@minimclass@customfont\else
\if@minimclass@fast
\RequirePackage{mathpazo}
\fi
\fi
-%% English fonts
\PassOptionsToPackage{no-math}{fontspec}
\RequirePackage{fontspec}
\IfFontExistsTF{Palatino Linotype}{%
@@ -141,7 +140,6 @@
ItalicFont = cmunst.otf ,
BoldItalicFont = cmuntb.otf ]
-%% Chinese fonts
\PassOptionsToPackage{fontset=none,scheme=plain}{ctex}
\RequirePackage{ctex}
\WarningFilter{everysel}{Everysel is no longer required}
@@ -206,7 +204,6 @@
\def\minimalist@titlefontshape{\CJKfamily{zhhei}}
-%% Math font
\if@minimclass@customfont\else
\if@minimclass@fast
\RequirePackage{amssymb}
@@ -236,6 +233,13 @@
\setmathfont[range={up/num, bfup/num}
]{texgyrepagella-math.otf}
+\AtBeginDocument{
+\let\mid@original\mid
+\renewcommand{\mid}{\hspace{-.2em}\mid@original\hspace{-.2em}}
+\let\nmid@original\nmid
+\renewcommand{\nmid}{\hspace{-.2em}\nmid@original\hspace{-.2em}}
+}
+
\newbox\xratbelow
\newbox\xratabove
\renewcommand{\xrightarrow}[2][]{%
@@ -298,7 +302,6 @@
\renewcommand{\twoheadrightarrow}{%
\mathrel{\tikz [baseline=-.55ex, every node/.style={inner sep=0pt}]
\draw (0,0) edge[commutative diagrams/twoheadrightarrow] (.8em,0) ;}}
-
\renewcommand{\twoheadleftarrow}{%
\mathrel{\tikz [baseline=-.55ex, every node/.style={inner sep=0pt}]
\draw (0,0) edge[commutative diagrams/twoheadleftarrow] (.8em,0) ;}}
@@ -363,7 +366,6 @@
\def\PJL@font@alreadyset{}
-%% Minor improvements
\PassOptionsToPackage{verbose=silent}{microtype}
\RequirePackage{microtype}
\PassOptionsToPackage{all}{nowidow}
diff --git a/macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdf b/macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdf
index 329b435539..26a44b253f 100644
--- a/macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdf
+++ b/macros/unicodetex/latex/simplivre/simplivre-doc-cn.pdf
Binary files differ
diff --git a/macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex b/macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex
index 815bc8737a..5ce2d00a7d 100644
--- a/macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex
+++ b/macros/unicodetex/latex/simplivre/simplivre-doc-cn.tex
@@ -40,7 +40,7 @@
\providecommand{\meta}[1]{$\langle${\normalfont\itshape#1}$\rangle$}
\lstset{moretexcs=%
{linenumbers,nolinenumbers,part,chapter,section,subsection,subsubsection,href,
- color,NameTheorem,CreateTheorem,proofideanameCN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,parttext
+ color,NameTheorem,CreateTheorem,proofideanameCN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,parttext,qedhere
}
}
\lstnewenvironment{code}%
@@ -102,9 +102,9 @@
\fill [cyan!90!black] ($(current page.south west)+(0,7)$) rectangle ($(current page.north west)+(21,-7)$);
\fill [yellow] (current page.south west) rectangle ($(current page.north west)+(3,0)$);
\node[text width=10cm] at ($(current page.north west)+(8.5,-6)$) {\huge\ProjLib};
- \node[text width=6cm,text height=3.5cm,scale=2.5] at ($(current page.north west)+(11,-9)$) {\textcolor{white}{\sffamily\simplivre{}\\[5pt]\footnotesize\hspace*{-.05em}以极简主义风格排版你的图书\\[10pt]\tiny 对应版本. \texttt{\simplivre{} 2021/06/30}}};
+ \node[text width=6cm,text height=3.5cm,scale=2.5] at ($(current page.north west)+(11,-9)$) {\textcolor{white}{\sffamily\simplivre{}\\[5pt]\footnotesize\hspace*{-.05em}以极简主义风格排版你的图书\\[10pt]\tiny 对应版本. \texttt{\simplivre{} 2021/07/05}}};
\node at ($(current page.south)+(1.5,3)$) {\fontsize{16pt}{0pt}\selectfont\textcolor{gray}{许锦文}};
- \node at ($(current page.south)+(1.5,2)$) {\fontsize{12pt}{0pt}\selectfont\textcolor{gray}{2021年6月,北京}};
+ \node at ($(current page.south)+(1.5,2)$) {\fontsize{12pt}{0pt}\selectfont\textcolor{gray}{2021年7月,北京}};
\end{tikzpicture}%
\end{titlepage}%
\cleardoublepage%
@@ -447,6 +447,9 @@
\end{itemize}
这是标题使用下划线装饰之后带来的一个缺点。
+\section{关于QED符号}
+由于定理类环境中的字体和正文字体是一样的,为了方便看出定理类环境在哪里结束,在其结尾处放置了一个空心的QED符号。然而,如果你的定理是由公式或者列表结尾的,这个符号就无法自动地放在正确的位置。这时,你需要手动在公式或列表最后一个条目的后面加上 \lstinline|\qedhere|,以让QED符号显示到这一行的最后。
+
\section{目前存在的问题}
diff --git a/macros/unicodetex/latex/simplivre/simplivre-doc-en.pdf b/macros/unicodetex/latex/simplivre/simplivre-doc-en.pdf
index 3da74b5301..6b4ed825c1 100644
--- a/macros/unicodetex/latex/simplivre/simplivre-doc-en.pdf
+++ b/macros/unicodetex/latex/simplivre/simplivre-doc-en.pdf
Binary files differ
diff --git a/macros/unicodetex/latex/simplivre/simplivre-doc-en.tex b/macros/unicodetex/latex/simplivre/simplivre-doc-en.tex
index 7566f60fd3..1885bfd03c 100644
--- a/macros/unicodetex/latex/simplivre/simplivre-doc-en.tex
+++ b/macros/unicodetex/latex/simplivre/simplivre-doc-en.tex
@@ -38,7 +38,7 @@
\providecommand{\meta}[1]{$\langle${\normalfont\itshape#1}$\rangle$}
\lstset{moretexcs=%
{linenumbers,nolinenumbers,part,chapter,section,subsection,subsubsection,href,
- color,NameTheorem,CreateTheorem,proofideanameEN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,parttext
+ color,NameTheorem,CreateTheorem,proofideanameEN,cref,dnf,needgraph,UseLanguage,UseOtherLanguage,AddLanguageSetting,maketitle,address,curraddr,email,keywords,subjclass,thanks,dedicatory,PLdate,ProjLib,parttext,qedhere
}
}
\lstnewenvironment{code}%
@@ -101,9 +101,9 @@
\fill [cyan!90!black] ($(current page.south west)+(0,7)$) rectangle ($(current page.north west)+(21,-7)$);
\fill [yellow] (current page.south west) rectangle ($(current page.north west)+(3,0)$);
\node[text width=10cm] at ($(current page.north west)+(8.5,-6)$) {\huge\ProjLib};
- \node[text width=6cm,text height=3.5cm,scale=2.5] at ($(current page.north west)+(11,-9)$) {\textcolor{white}{\sffamily\simplivre{}\\[5pt]\footnotesize\textsc{Write your books in \\a simple and clear way}\\[10pt]\tiny Corresponding to: \texttt{\simplivre{} 2021/06/30}}};
+ \node[text width=6cm,text height=3.5cm,scale=2.5] at ($(current page.north west)+(11,-9)$) {\textcolor{white}{\sffamily\simplivre{}\\[5pt]\footnotesize\textsc{Write your books in \\a simple and clear way}\\[10pt]\tiny Corresponding to: \texttt{\simplivre{} 2021/07/05}}};
\node at ($(current page.south)+(1.5,3)$) {\fontsize{16pt}{0pt}\selectfont\textcolor{gray}{\scshape Jinwen XU}};
- \node at ($(current page.south)+(1.5,2)$) {\fontsize{12pt}{0pt}\selectfont\textcolor{gray}{June 2021, Beijing}};
+ \node at ($(current page.south)+(1.5,2)$) {\fontsize{12pt}{0pt}\selectfont\textcolor{gray}{July 2021, Beijing}};
\end{tikzpicture}%
\end{titlepage}%
\cleardoublepage%
@@ -133,9 +133,11 @@ This documentation is typeset using \simplivre{}. You can think of it as a short
\section{How to load it}
One only needs to put
+
\begin{code}
\documentclass{simplivre}
\end{code}
+
as the first line to use the \simplivre{} class.
\begin{tip}[Attention]
@@ -364,7 +366,7 @@ defines an unnumbered environment \lstinline|proofidea*| and a numbered environm
The \lstinline|proofidea| environment.
\end{proofidea}
-\clearpage
+% \clearpage
\section{Draft mark}
You can use \lstinline|\dnf| to mark the unfinished part. For example:
@@ -440,7 +442,11 @@ In \lstinline|\section| or \lstinline|\subsection| , if you wish to add footnote
\end{itemize}
This is a disadvantage brought about by the underline decoration of the title.
+\section{On the QED symbols}
+Since the font in the theorem-like environments is the same as that of the main text, in order to indicate where the environments end, a hollow QED symbol \simpleqedsymbol{} is placed at the end of the theorem-like environments. However, if your theorem ends with an equation or list (itemize, enumerate, description, etc.), this symbol cannot be automatically placed in the correct position. In this case, you need to manually add a \lstinline|\qedhere| at the end of your equation or the last entry of your list to make the QED symbol appear at the end of the line.
+
+\clearpage
\section{Known issues}
\begin{itemize}[itemsep=.6em]
diff --git a/macros/unicodetex/latex/simplivre/simplivre.cls b/macros/unicodetex/latex/simplivre/simplivre.cls
index 5f253fee23..28b2e7d16c 100644
--- a/macros/unicodetex/latex/simplivre/simplivre.cls
+++ b/macros/unicodetex/latex/simplivre/simplivre.cls
@@ -17,7 +17,7 @@
%%
\NeedsTeXFormat{LaTeX2e}[2020-10-01]
\ProvidesClass{simplivre}
- [2021/06/30 A simple and clear book style]
+ [2021/07/05 A simple and clear book style]
\def\minimclass@baseclass{book}
\RequirePackage{kvoptions}
\RequirePackage{etoolbox}
@@ -44,6 +44,7 @@
\DeclareDefaultOption{\PassOptionsToClass{\CurrentOption}{\minimclass@baseclass}}
\ProcessKeyvalOptions*\relax
\LoadClass{\minimclass@baseclass}
+
\if@minimclass@draft
\@minimclass@fasttrue
\fi
@@ -110,14 +111,12 @@
%%================================
%% Fonts
%%================================
-%% Math fonts in fast mode
\if@minimclass@customfont\else
\if@minimclass@fast
\RequirePackage{mathpazo}
\fi
\fi
-%% English fonts
\PassOptionsToPackage{no-math}{fontspec}
\RequirePackage{fontspec}
\IfFontExistsTF{Palatino Linotype}{%
@@ -141,7 +140,6 @@
ItalicFont = cmunst.otf ,
BoldItalicFont = cmuntb.otf ]
-%% Chinese fonts
\PassOptionsToPackage{fontset=none,scheme=plain}{ctex}
\RequirePackage{ctex}
\WarningFilter{everysel}{Everysel is no longer required}
@@ -206,7 +204,6 @@
\def\minimalist@titlefontshape{\CJKfamily{zhhei}}
-%% Math font
\if@minimclass@customfont\else
\if@minimclass@fast
\RequirePackage{amssymb}
@@ -236,6 +233,13 @@
\setmathfont[range={up/num, bfup/num}
]{texgyrepagella-math.otf}
+\AtBeginDocument{
+\let\mid@original\mid
+\renewcommand{\mid}{\hspace{-.2em}\mid@original\hspace{-.2em}}
+\let\nmid@original\nmid
+\renewcommand{\nmid}{\hspace{-.2em}\nmid@original\hspace{-.2em}}
+}
+
\newbox\xratbelow
\newbox\xratabove
\renewcommand{\xrightarrow}[2][]{%
@@ -298,7 +302,6 @@
\renewcommand{\twoheadrightarrow}{%
\mathrel{\tikz [baseline=-.55ex, every node/.style={inner sep=0pt}]
\draw (0,0) edge[commutative diagrams/twoheadrightarrow] (.8em,0) ;}}
-
\renewcommand{\twoheadleftarrow}{%
\mathrel{\tikz [baseline=-.55ex, every node/.style={inner sep=0pt}]
\draw (0,0) edge[commutative diagrams/twoheadleftarrow] (.8em,0) ;}}
@@ -363,7 +366,6 @@
\def\PJL@font@alreadyset{}
-%% Minor improvements
\PassOptionsToPackage{verbose=silent}{microtype}
\RequirePackage{microtype}
\PassOptionsToPackage{all}{nowidow}