Skip to content

Commit

Permalink
ctex 1.02d: 处理 Issue 155 和 Issue 124。
Browse files Browse the repository at this point in the history
  • Loading branch information
qinglee committed Jun 9, 2014
1 parent 7ac4c80 commit 8636eb3
Show file tree
Hide file tree
Showing 14 changed files with 29 additions and 19 deletions.
2 changes: 1 addition & 1 deletion back/ctexartutf8.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexartutf8}
[2011/03/11 v1.02c ctexartutf8
[2014/06/09 v1.02d ctexartutf8
document class]

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexart}}
Expand Down
2 changes: 1 addition & 1 deletion back/ctexbookutf8.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexbookutf8}
[2011/03/11 v1.02c ctexbookutf8
[2014/06/09 v1.02d ctexbookutf8
document class]

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexbook}}
Expand Down
2 changes: 1 addition & 1 deletion back/ctexcaputf8.sty
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexcaputf8}
[2011/03/11 v1.02c ctexcaputf8
[2014/06/09 v1.02d ctexcaputf8
macros package]

\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{ctexcap}}
Expand Down
2 changes: 1 addition & 1 deletion back/ctexreputf8.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexreputf8}
[2011/03/11 v1.02c ctexreputf8
[2014/06/09 v1.02d ctexreputf8
document class]

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexrep}}
Expand Down
2 changes: 1 addition & 1 deletion back/ctexutf8.sty
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexutf8}
[2011/03/11 v1.02c ctexutf8
[2014/06/09 v1.02d ctexutf8
macros package]

\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{ctex}}
Expand Down
2 changes: 1 addition & 1 deletion ctex.sty
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctex}
[2011/03/11 v1.02c ctex
[2014/06/09 v1.02d ctex
macros package]

\input{ctex-common-opts.def}
Expand Down
2 changes: 1 addition & 1 deletion ctexart.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexart}
[2011/03/11 v1.02c ctexart
[2014/06/09 v1.02d ctexart
document class]

\def\CTEX@classtoload{article}
Expand Down
2 changes: 1 addition & 1 deletion ctexbook.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexbook}
[2011/03/11 v1.02c ctexbook
[2014/06/09 v1.02d ctexbook
document class]

\def\CTEX@classtoload{book}
Expand Down
2 changes: 1 addition & 1 deletion ctexcap.sty
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexcap}
[2011/03/11 v1.02c ctexcap
[2014/06/09 v1.02d ctexcap
macros package]

\input{ctex-common-opts.def}
Expand Down
2 changes: 1 addition & 1 deletion ctexrep.cls
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexrep}
[2011/03/11 v1.02c ctexrep
[2014/06/09 v1.02d ctexrep
document class]

\def\CTEX@classtoload{report}
Expand Down
2 changes: 0 additions & 2 deletions def/ctex-common.def
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,6 @@
\ifCTEX@indent
\AtBeginDocument{\CTEXindent}
\fi
\def\CTEX@spaceChar{\hskip \f@size \p@}
\def\baselinestretch{1.3}

% About font sizing
Expand Down Expand Up @@ -422,4 +421,3 @@
\fi

\endinput

Binary file modified doc/ctex.pdf
Binary file not shown.
9 changes: 7 additions & 2 deletions doc/ctex.tex
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
%# -*- coding: utf-8 -*-
% ctex.tex: manual of ctex package

\documentclass{ltxdoc}
\documentclass[a4paper]{ltxdoc}
\usepackage[fntef,hyperref,UTF8]{ctexcap}
\hypersetup{pdfstartview=FitH,bookmarksnumbered}
\usepackage{texnames}
Expand Down Expand Up @@ -38,7 +38,7 @@

\title{\bf \ctex{} 宏包说明}
\author{\it \ctexorg\thanks{\url{http://www.ctex.org}}}
\date{\small 版本号:v1.02c \hskip 2\ccwd 修改日期:2011/03/11}
\date{\small 版本号:v1.02d \hskip 2\ccwd 修改日期:2014/06/09}
\maketitle


Expand Down Expand Up @@ -819,6 +819,11 @@ \section{版本更新}

\begin{description}

\item[v1.02d 2014/06/09]
处理修改 |\set@fontsize| 造成的一个 BUG。

处理与 |fontspec| v2.4 的兼容问题。

\item[v1.02c 2011/03/11]
修改 \texttt{hyperref} 选项的行为,使 \texttt{hyperref} 宏包可以在用户指定的位
置被调用,以解决个别兼容性问题。修正 XeTeX 编译书签中百分号出错的 BUG。
Expand Down
17 changes: 12 additions & 5 deletions engine/ctex-cjk-common.def
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,20 @@
\CTEX@save@set@fontsize{#1}{#2}{#3}%
\CTEXsetfont}
\newcommand*\ziju[1]{% 字距
\settowidth\@tempdima{\CTEX@spaceChar}%
\renewcommand{\CJKglue}{\hskip #1\@tempdima\@plus.08\baselineskip\relax}%
\CTEXsetfont} % is it a good definition?
\begingroup
\settowidth\@tempdima{\CTEX@spaceChar}%
\expandafter\endgroup%
\expandafter\renewcommand%
\expandafter\CJKglue%
\expandafter{\expandafter\hskip\the\dimexpr#1\@tempdima\relax\@plus.08\baselineskip\relax}%
\CTEXsetfont} % is it a good definition?
\newdimen\ccwd % 字宽
\newcommand*\CTEXsetfont{%
\settowidth\ccwd{\CTEX@spaceChar\CJKglue}%
\ifdim\parindent=0pt\else\parindent2\ccwd\fi}
\begingroup
\settowidth\ccwd{\CTEX@spaceChar\CJKglue}%
\expandafter\endgroup\expandafter\ccwd\the\ccwd\relax
\unless\ifdim\parindent=\z@\parindent2\ccwd\fi}
\def\CTEX@spaceChar{\hskip \f@size \p@\relax}
\ifCTEX@fntef
\def\CTEXunderdot{\CJKunderdot}
\def\CTEXunderline{\CJKunderline}
Expand Down

0 comments on commit 8636eb3

Please sign in to comment.