summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/latex/ctex/ctex.pdfbin356315 -> 362130 bytes
-rw-r--r--Master/texmf-dist/doc/latex/ctex/ctex.tex30
-rw-r--r--Master/texmf-dist/doc/latex/ctex/script/update-version.py39
-rw-r--r--Master/texmf-dist/doc/latex/ctex/test/test-cjk.tex17
-rw-r--r--Master/texmf-dist/tex/latex/ctex/back/ctexartutf8.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/back/ctexbookutf8.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/back/ctexcaputf8.sty2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/back/ctexreputf8.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/back/ctexutf8.sty2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/ctex.sty2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/ctexart.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/ctexbook.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/ctexcap.sty2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/ctexrep.cls2
-rw-r--r--Master/texmf-dist/tex/latex/ctex/def/ctex-common.def47
-rw-r--r--Master/texmf-dist/tex/latex/ctex/fontset/ctex-cjk-winfonts.def4
-rw-r--r--Master/texmf-dist/tex/latex/ctex/fontset/ctex-xecjk-winfonts.def4
-rw-r--r--Master/texmf-dist/tex/latex/ctex/opt/ctex-common-opts.def4
18 files changed, 65 insertions, 100 deletions
diff --git a/Master/texmf-dist/doc/latex/ctex/ctex.pdf b/Master/texmf-dist/doc/latex/ctex/ctex.pdf
index 882ae06e73a..660c58ca2ce 100644
--- a/Master/texmf-dist/doc/latex/ctex/ctex.pdf
+++ b/Master/texmf-dist/doc/latex/ctex/ctex.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/ctex/ctex.tex b/Master/texmf-dist/doc/latex/ctex/ctex.tex
index 0c81f160d8a..5458cbf52d0 100644
--- a/Master/texmf-dist/doc/latex/ctex/ctex.tex
+++ b/Master/texmf-dist/doc/latex/ctex/ctex.tex
@@ -2,7 +2,7 @@
% ctex.tex: manual of ctex package
\documentclass{ltxdoc}
-\usepackage[fntef,hyperref,adobefonts]{ctexcap}
+\usepackage[fntef,hyperref,UTF8]{ctexcap}
\usepackage{texnames}
\topmargin 0.5 true cm
\oddsidemargin 1 true cm
@@ -37,7 +37,7 @@
\title{\bf \ctex{} 宏包说明}
\author{\it \ctexorg\thanks{\url{http://www.ctex.org}}}
-\date{\small 版本号:v0.95 \hskip 2\ccwd 修改日期:2009/10/20}
+\date{\small 版本号:v0.96 \hskip 2\ccwd 修改日期:2009/11/24}
\maketitle
@@ -60,7 +60,7 @@
这个宏包的部分原始代码来自于由王磊编写 \texttt{cjkbook.cls} 文档类,
还有一小部分原始代码来自于吴凌云编写的 \texttt{GB.cap} 文件。
原来的这些工作都是零零碎碎编写的,没有认真、系统的设计,
-也没有用户文档,非常不利于维护和改进。2003 年,吴凌云用 \texttt{doc}
+也没有用户文档,非常不利于维护和改进。2003 年,吴凌云用 \texttt{doc}
和 \texttt{docstrip} 工具重新编写了整个文档,并增加了许多新的功能。
2007 年,oseen 和王越在 \ctex{} 宏包基础上增加了对 UTF-8 编码的支持,
开发出了 \texttt{ctexutf8} 宏包。
@@ -210,11 +210,17 @@
\item[adobefonts] 在 xeCJK 模式中使用 Adobe 的四套字体:宋体、仿宋、黑体、楷体。
在 CJK 模式(即不使用 Xe\TeX{} 时)下,该选项将使用 winfonts 选项的设置。
+
+\item[zhmap] 仅在 winfonts 模式下有效。使用 zhmetrics 宏包提供的字体文件映射,
+将中文字库映射到相应的 ttf 字库文件。\ctexdefault
+
+\item[nozhmap] 仅在 winfonts 模式下有效。使用系统提供的字体文件映射方式。
+如果需要使用自定义的字体映射或者使用 Type1 字库,请使用该选项。
\end{description}
\subsubsection{CCT 引擎选项}
-下面的选项用于选择底层的中文系统。缺省情况下,宏包会根据编译方式自动选择 CJK
+下面的选项用于选择底层的中文系统。缺省情况下,宏包会根据编译方式自动选择 CJK
或者 xeCJK 引擎。
\begin{description}
\item[CCT] 使用 CCT 代替 CJK 做为底层的中文支持系统。
@@ -267,8 +273,8 @@
\subsubsection{缺省选项}
-总结一下:\ctex{} 宏包的缺省选项是 GBK nospace cap punct indent,\ctex{} 文档类
-的缺省选项是 GBK nospace cap punct indent c5size。
+总结一下:\ctex{} 宏包的缺省选项是 GBK zhmap nospace cap punct indent,\ctex{} 文档类
+的缺省选项是 GBK zhmap nospace cap punct indent c5size。
\subsection{基本命令}
@@ -423,7 +429,7 @@
\parg{val1}, \parg{val2} 则是对应选项的设置内容。
同一个目标类型的多个选项可以在一个语句中完成设置。
-{\kaishu
+{\kaishu
在 v0.7 版本之前,如果以上命令的参数中包含中文字符,则命令必须放在
|\begin{document}| 之后才能正常工作。从 v0.7 版本开始支持在导言区使用中文。
}
@@ -678,7 +684,7 @@ subparagraph & 同右 & \{\cs{parindent}\} \\
\subsubsection{附录标题设置}
附录(appendix)的标题也使用 |\CTEXsetup| 命令进行设置,
-第二个参数设为 |appendix|。但是只能使用 |name| 和 |number|
+第二个参数设为 |appendix|。但是只能使用 |name| 和 |number|
两个设置选项。在使用了 |\appendix| 命令之后,附录
的名字和编号会被自动使用。{\bf 附录的名字和前面的章节不同,
它只有一个部分,放在编号之前。}在 article 类文档中,
@@ -780,7 +786,7 @@ number & 同右 & \{\cs{Alph}\marg{chapter}\} \\
设置 \ref{fontset} 一节中的几个选项之一为缺省选项。
该文件会在处理宏包选项之前装入。
-\texttt{ctexcap.cfg} 是缺省中文标题格式的定义,当你使用 \texttt{cap}
+\texttt{ctexcap.cfg} 是缺省中文标题格式的定义,当你使用 \texttt{cap}
选项时就会使用这里的定义。你可以把它改为你经常使用的格式,这样就不用
每次都在正文中修改了。 \texttt{ctexcap.cfg} 中的设置都可以通过宏包提供
的设置命令在正文中进行修改。与中文编码有关的定义分别在
@@ -798,6 +804,12 @@ number & 同右 & \{\cs{Alph}\marg{chapter}\} \\
\begin{description}
+\item[v0.97 2010/01/22]
+修正 pdf\LaTeX{} 与 Xe\LaTeX{} 中生成 PDF 书签的问题。
+
+\item[v0.96 2009/11/24]
+添加 zhmap 与 nozhmap 选项控制 zhwinfonts 的载入。
+
\item[v0.95 2009/10/20]
移除对 CJKnumb 宏包的依赖。去除无用的 cjkfonts 选项,以 winfonts
作为默认值。
diff --git a/Master/texmf-dist/doc/latex/ctex/script/update-version.py b/Master/texmf-dist/doc/latex/ctex/script/update-version.py
deleted file mode 100644
index 5353ab650f4..00000000000
--- a/Master/texmf-dist/doc/latex/ctex/script/update-version.py
+++ /dev/null
@@ -1,39 +0,0 @@
-#!/usr/bin/env python
-
-import sys, os, re
-
-def update_version(file, date, version):
- f = open(file)
- update_next = False
- line_re = re.compile("^(\s*)\[(\d+/\d+/\d+) ([^\s]+) (.*)$")
- lines = ""
-
- for line in f:
- if update_next:
- update_next = False
- m = line_re.match(line)
- if m:
- line = "%s[%s %s %s\n" % (m.group(1), date, version, m.group(4))
-
- elif "ProvidesPackage" in line or "ProvidesClass" in line or "ProvidesFile" in line:
- update_next = True
-
- lines += line
-
- f.close()
- f = open(file, "w")
- f.write(lines)
- f.close()
-
-if len(sys.argv) != 3:
- print("%s %s" % (sys.argv[0], "<date> <version>"))
- print("like: %s %s" % (sys.argv[0], "2009/05/20 v0.91"))
- sys.exit(1)
-
-file_list = [ "../ctex.sty", "../ctexcap.sty", "../ctexart.cls", "../ctexbook.cls", "../ctexrep.cls",
- "../back/ctexutf8.sty", "../back/ctexcaputf8.sty", "../back/ctexartutf8.cls",
- "../back/ctexbookutf8.cls", "../back/ctexreputf8.cls",]
-
-for file in file_list:
- update_version(file, sys.argv[1], sys.argv[2])
-
diff --git a/Master/texmf-dist/doc/latex/ctex/test/test-cjk.tex b/Master/texmf-dist/doc/latex/ctex/test/test-cjk.tex
index 0c02b5b1465..739eff35cac 100644
--- a/Master/texmf-dist/doc/latex/ctex/test/test-cjk.tex
+++ b/Master/texmf-dist/doc/latex/ctex/test/test-cjk.tex
@@ -1,21 +1,6 @@
%# -*- coding: gbk -*-
% $Id$
-\documentclass[cs4size,a4paper,fancyhdr,fntef,winfonts]{ctexbook}
-\usepackage{ifpdf}
-\usepackage{ifxetex}
-\ifxetex
- \XeTeXinputencoding "GBK"
- \usepackage[xetex]{hyperref}
-\else
- \ifpdf
- % pdflatex ʱҪʹ gbk2uni ܵõȷǩ
- \usepackage[pdftex,CJKbookmarks]{hyperref}
- \else% Assuming dvipdfm(x)
- \AtBeginDvi{\special{pdf:tounicode GBK-EUC-UCS2}}
- \usepackage[dvipdfm,CJKbookmarks]{hyperref}
- \fi
-\fi
-
+\documentclass[cs4size,a4paper,fancyhdr,fntef,winfonts,hyperref]{ctexbook}
\usepackage{shortvrb, makeidx}
\makeindex
diff --git a/Master/texmf-dist/tex/latex/ctex/back/ctexartutf8.cls b/Master/texmf-dist/tex/latex/ctex/back/ctexartutf8.cls
index 25c6045e0f7..bf6eb50a46c 100644
--- a/Master/texmf-dist/tex/latex/ctex/back/ctexartutf8.cls
+++ b/Master/texmf-dist/tex/latex/ctex/back/ctexartutf8.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexartutf8}
- [2009/10/20 v0.95 ctexartutf8
+ [2010/01/22 v0.97 ctexartutf8
document class]
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexart}}
diff --git a/Master/texmf-dist/tex/latex/ctex/back/ctexbookutf8.cls b/Master/texmf-dist/tex/latex/ctex/back/ctexbookutf8.cls
index 383fb5b9623..8dbaaf91f7d 100644
--- a/Master/texmf-dist/tex/latex/ctex/back/ctexbookutf8.cls
+++ b/Master/texmf-dist/tex/latex/ctex/back/ctexbookutf8.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexbookutf8}
- [2009/10/20 v0.95 ctexbookutf8
+ [2010/01/22 v0.97 ctexbookutf8
document class]
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexbook}}
diff --git a/Master/texmf-dist/tex/latex/ctex/back/ctexcaputf8.sty b/Master/texmf-dist/tex/latex/ctex/back/ctexcaputf8.sty
index 1c60f1018ca..4b1da35e782 100644
--- a/Master/texmf-dist/tex/latex/ctex/back/ctexcaputf8.sty
+++ b/Master/texmf-dist/tex/latex/ctex/back/ctexcaputf8.sty
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexcaputf8}
- [2009/10/20 v0.95 ctexcaputf8
+ [2010/01/22 v0.97 ctexcaputf8
macros package]
\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{ctexcap}}
diff --git a/Master/texmf-dist/tex/latex/ctex/back/ctexreputf8.cls b/Master/texmf-dist/tex/latex/ctex/back/ctexreputf8.cls
index dd4391d2fa1..ccb79252161 100644
--- a/Master/texmf-dist/tex/latex/ctex/back/ctexreputf8.cls
+++ b/Master/texmf-dist/tex/latex/ctex/back/ctexreputf8.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexreputf8}
- [2009/10/20 v0.95 ctexreputf8
+ [2010/01/22 v0.97 ctexreputf8
document class]
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{ctexrep}}
diff --git a/Master/texmf-dist/tex/latex/ctex/back/ctexutf8.sty b/Master/texmf-dist/tex/latex/ctex/back/ctexutf8.sty
index 8252e2050b6..ca99a6cdab1 100644
--- a/Master/texmf-dist/tex/latex/ctex/back/ctexutf8.sty
+++ b/Master/texmf-dist/tex/latex/ctex/back/ctexutf8.sty
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexutf8}
- [2009/10/20 v0.95 ctexutf8
+ [2010/01/22 v0.97 ctexutf8
macros package]
\DeclareOption*{\PassOptionsToPackage{\CurrentOption}{ctex}}
diff --git a/Master/texmf-dist/tex/latex/ctex/ctex.sty b/Master/texmf-dist/tex/latex/ctex/ctex.sty
index 12e848b2b03..de88408e311 100644
--- a/Master/texmf-dist/tex/latex/ctex/ctex.sty
+++ b/Master/texmf-dist/tex/latex/ctex/ctex.sty
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctex}
- [2009/10/20 v0.95 ctex
+ [2010/01/22 v0.97 ctex
macros package]
\input{ctex-common-opts.def}
diff --git a/Master/texmf-dist/tex/latex/ctex/ctexart.cls b/Master/texmf-dist/tex/latex/ctex/ctexart.cls
index a4bdcf734c3..ab653ce7352 100644
--- a/Master/texmf-dist/tex/latex/ctex/ctexart.cls
+++ b/Master/texmf-dist/tex/latex/ctex/ctexart.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexart}
- [2009/10/20 v0.95 ctexart
+ [2010/01/22 v0.97 ctexart
document class]
\def\CTEX@classtoload{article}
diff --git a/Master/texmf-dist/tex/latex/ctex/ctexbook.cls b/Master/texmf-dist/tex/latex/ctex/ctexbook.cls
index 6d387dbcaf6..cf0cc439685 100644
--- a/Master/texmf-dist/tex/latex/ctex/ctexbook.cls
+++ b/Master/texmf-dist/tex/latex/ctex/ctexbook.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexbook}
- [2009/10/20 v0.95 ctexbook
+ [2010/01/22 v0.97 ctexbook
document class]
\def\CTEX@classtoload{book}
diff --git a/Master/texmf-dist/tex/latex/ctex/ctexcap.sty b/Master/texmf-dist/tex/latex/ctex/ctexcap.sty
index 79d21b10b69..89356aa8784 100644
--- a/Master/texmf-dist/tex/latex/ctex/ctexcap.sty
+++ b/Master/texmf-dist/tex/latex/ctex/ctexcap.sty
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesPackage{ctexcap}
- [2009/10/20 v0.95 ctexcap
+ [2010/01/22 v0.97 ctexcap
macros package]
\input{ctex-common-opts.def}
diff --git a/Master/texmf-dist/tex/latex/ctex/ctexrep.cls b/Master/texmf-dist/tex/latex/ctex/ctexrep.cls
index 731c6f55309..a759416b6c1 100644
--- a/Master/texmf-dist/tex/latex/ctex/ctexrep.cls
+++ b/Master/texmf-dist/tex/latex/ctex/ctexrep.cls
@@ -2,7 +2,7 @@
\NeedsTeXFormat{LaTeX2e}[1995/12/01]
\ProvidesClass{ctexrep}
- [2009/10/20 v0.95 ctexrep
+ [2010/01/22 v0.97 ctexrep
document class]
\def\CTEX@classtoload{report}
diff --git a/Master/texmf-dist/tex/latex/ctex/def/ctex-common.def b/Master/texmf-dist/tex/latex/ctex/def/ctex-common.def
index cbb98c21269..9d230ed038d 100644
--- a/Master/texmf-dist/tex/latex/ctex/def/ctex-common.def
+++ b/Master/texmf-dist/tex/latex/ctex/def/ctex-common.def
@@ -11,7 +11,7 @@
\RequirePackage{ifxetex}
\ifxetex
-\CTEX@GBKfalse % XeTeX always use UTF-8 as default encoding
+ \CTEX@GBKfalse % XeTeX always use UTF-8 as default encoding
\fi
\RequirePackage{keyval}[1999/03/16]
@@ -22,26 +22,6 @@
\ifCTEX@fancyhdr
\RequirePackage{fancyhdr}
\fi
-\ifCTEX@hyperref
- \ifxetex
- \RequirePackage[xetex]{hyperref}
- \else
- \ifpdf % pdftex
- \RequirePackage[pdftex]{hyperref}
- \else % dvipdfmx
- \ifCTEX@GBK
- \AtBeginDvi{\special{pdf:tounicode GBK-EUC-UCS2}}
- \fi
- \RequirePackage[dvipdfmx]{hyperref}
- \fi
- \ifCTEX@GBK
- \hypersetup{CJKbookmarks=true}
- \else
- \hypersetup{unicode=true}
- \fi
- \fi
- \hypersetup{colorlinks=true}
-\fi
% Useful definitions
@@ -384,7 +364,7 @@
\ifCTEX@caption
\let\CTEX@save@refstepcounter\refstepcounter
- \def\refstepcounter#1{\stepcounter{#1}%
+ \def\refstepcounter#1{\CTEX@save@refstepcounter{#1}%
\protected@edef\@currentlabel
{\csname p@#1\endcsname%
\@ifundefined{CTEX@the#1}%
@@ -407,5 +387,28 @@
Available today format are "old", "small", and "big".}}
{\renewcommand*\today{\csname CTEX@today#1\endcsname}}}
+% Put hyperref as bottom as possible, otherwise there may be page
+% count issues
+\ifCTEX@hyperref
+ \ifxetex
+ \RequirePackage{hyperref}
+ \else
+ \ifpdf % pdftex
+ \RequirePackage[pdftex]{hyperref}
+ \else % dvipdfmx
+ \ifCTEX@GBK
+ \AtBeginDvi{\special{pdf:tounicode GBK-EUC-UCS2}}
+ \fi
+ \RequirePackage[dvipdfmx]{hyperref}
+ \fi
+ \ifCTEX@GBK
+ \hypersetup{CJKbookmarks=true}
+ \else
+ \hypersetup{unicode=true}
+ \fi
+ \fi
+ \hypersetup{colorlinks=true}
+\fi
+
\endinput
diff --git a/Master/texmf-dist/tex/latex/ctex/fontset/ctex-cjk-winfonts.def b/Master/texmf-dist/tex/latex/ctex/fontset/ctex-cjk-winfonts.def
index 1a53956c9b4..3cb76fdf1c6 100644
--- a/Master/texmf-dist/tex/latex/ctex/fontset/ctex-cjk-winfonts.def
+++ b/Master/texmf-dist/tex/latex/ctex/fontset/ctex-cjk-winfonts.def
@@ -1,7 +1,9 @@
% ctex-cjk-winfonts.def: Windows 的 CJK 字体设置,默认为 CTeX 套装的六种字体
% vim:ft=tex
-\input zhwinfonts
+\ifCTEX@zhmap
+ \input zhwinfonts
+\fi
\renewcommand*\CTEX@rm@family{rm}
\renewcommand*\CTEX@sf@family{sf}
diff --git a/Master/texmf-dist/tex/latex/ctex/fontset/ctex-xecjk-winfonts.def b/Master/texmf-dist/tex/latex/ctex/fontset/ctex-xecjk-winfonts.def
index 6f479854736..13f50f3a075 100644
--- a/Master/texmf-dist/tex/latex/ctex/fontset/ctex-xecjk-winfonts.def
+++ b/Master/texmf-dist/tex/latex/ctex/fontset/ctex-xecjk-winfonts.def
@@ -3,15 +3,13 @@
\setCJKmainfont[BoldFont={SimHei},ItalicFont={[simkai.ttf]}]
{SimSun}
-\setCJKsansfont{YouYuan}
+\setCJKsansfont{SimHei}
\setCJKmonofont{[simfang.ttf]}
\setCJKfamilyfont{zhsong}{SimSun}
\setCJKfamilyfont{zhhei}{SimHei}
\setCJKfamilyfont{zhkai}{[simkai.ttf]}
\setCJKfamilyfont{zhfs}{[simfang.ttf]}
-\setCJKfamilyfont{zhli}{LiSu}
-\setCJKfamilyfont{zhyou}{YouYuan}
\newcommand*{\songti}{\CJKfamily{zhsong}} % 宋体
\newcommand*{\heiti}{\CJKfamily{zhhei}} % 黑体
diff --git a/Master/texmf-dist/tex/latex/ctex/opt/ctex-common-opts.def b/Master/texmf-dist/tex/latex/ctex/opt/ctex-common-opts.def
index f9c52572bfd..612935da8b6 100644
--- a/Master/texmf-dist/tex/latex/ctex/opt/ctex-common-opts.def
+++ b/Master/texmf-dist/tex/latex/ctex/opt/ctex-common-opts.def
@@ -20,6 +20,10 @@
\CTEX@nofontsfalse
\CTEX@winfontsfalse}
+\newif\ifCTEX@zhmap \CTEX@zhmaptrue
+\DeclareOption{zhmap}{\CTEX@zhmaptrue}
+\DeclareOption{nozhmap}{\CTEX@zhmapfalse}
+
\newif\ifCTEX@cct \CTEX@cctfalse
\DeclareOption{CCT}{\CTEX@ccttrue}