summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/xelatex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-05-03 00:03:02 +0000
committerKarl Berry <karl@freefriends.org>2016-05-03 00:03:02 +0000
commit037b815f75f28884799427d962edd4e64e294483 (patch)
tree5621924009363bff91f642c48684a784d610db16 /Master/texmf-dist/tex/xelatex
parentaa8cd19f05a7e49e3b95f7d46750a85e80fa6e8b (diff)
ucharclasses
git-svn-id: svn://tug.org/texlive/trunk@40854 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/xelatex')
-rw-r--r--Master/texmf-dist/tex/xelatex/ucharclasses/ucharclasses.sty51
1 files changed, 25 insertions, 26 deletions
diff --git a/Master/texmf-dist/tex/xelatex/ucharclasses/ucharclasses.sty b/Master/texmf-dist/tex/xelatex/ucharclasses/ucharclasses.sty
index 45f4be0414c..a82226cdc4d 100644
--- a/Master/texmf-dist/tex/xelatex/ucharclasses/ucharclasses.sty
+++ b/Master/texmf-dist/tex/xelatex/ucharclasses/ucharclasses.sty
@@ -7,24 +7,22 @@
%
% Current compatibility should be Unicode 8.0.
%
-% Significant updates:
-% v1.0: Unicode block switching using XeTeX intercharclasses.
-% v2.0: Vastly improved performance and Unicode 6.0 support
-% v2.1: Uplift for the intercharclass updates introduced in XeTeX 0.99994
-% v2.2: Unicode 8.0 support and a LaTeX 2e patch
-%
% Credits:
-% v1.0: Mike "Pomax" Kamermans
+% v2.1-2.2: Qing Lee, Werner Lemberg
% v2.0: Enrico Gregorio
-% v2.1: Qing Lee
-% v2.2: Werner Lemberg
+% v1.0: Mike "Pomax" Kamermans
+%
+% Significant updates:
+% v2.2: Unicode 8.0 and LaTeX2e support
+% v2.1: Uplift for the intercharclass updates introduced in XeTeX 0.99994
+% v2.0: Rewritten to Vastly improve performance.
+% v1.0: Unicode block switching using XeTeX intercharclasses.
%
% License: public domain (http://www.tex.ac.uk/CTAN/help/Catalogue/licenses.pd.html)
%
% ----------------------------------------------------------------------------
-\ProvidesPackage{ucharclasses}[2016/04/21 v2.1x Unicode block
- character classes for XeLaTeX]
+\ProvidesPackage{ucharclasses}[2016/04/25 v2.2.1 Unicode block character classes for XeLaTeX]
\newif\if@ucharclassverbose
\DeclareOption{verbose}{\@ucharclassverbosetrue}
@@ -39,14 +37,23 @@
% Starting with XeTeX version 3.14159265-2.6-0.99994, the number of
% \XeTeXcharclass registers was extended from 256 to 4096 entries; some not
% so important blocks are thus provided only for this and newer versions.
+% The boundary of character class was changed from 255 to 4095 correspondingly.
% The primitive \XeTeXinterwordspaceshaping was introduced by XeTeX 0.99994;
% we use it as a flag to identify this version.
%
-% However, LaTeX2e itself currently doesn't provide support for 4096
-% entries; we thus have to override the hard-coded limit.
-\ifdefined\XeTeXinterwordspaceshaping
- \def\newXeTeXintercharclass{%
- \e@alloc\XeTeXcharclass\chardef\xe@alloc@intercharclass\m@ne{4095 }}
+% However, earlier version of LaTeX2e (before 2016/04/22 v2.0q) didn't provide
+% support for 4096 entries; we thus have to override the hard-coded limit.
+\ifdefined\e@alloc@intercharclass@top
+ \chardef\@ucharclass@boundary=\e@alloc@intercharclass@top
+\else
+ \ifdefined\XeTeXinterwordspaceshaping
+ \chardef\@ucharclass@boundary=4095 %
+ \def\newXeTeXintercharclass{%
+ \e@alloc\XeTeXcharclass\chardef
+ \xe@alloc@intercharclass\m@ne\@ucharclass@boundary}
+ \else
+ \chardef\@ucharclass@boundary=\@cclv
+ \fi
\fi
\def\AllClasses{
@@ -739,8 +746,8 @@
% ----------------------------------------------------------------------------
% enable/disable commands
-\newcommand{\disableTransitionRules}{\XeTeXinterchartokenstate = 0}
-\newcommand{\enableTransitionRules}{\XeTeXinterchartokenstate = 1}
+\newcommand{\disableTransitionRules}{\XeTeXinterchartokenstate = \z@}
+\newcommand{\enableTransitionRules}{\XeTeXinterchartokenstate = \@ne}
% shorthand commands
\let\uccoff\disableTransitionRules
@@ -804,14 +811,6 @@
%%% Our assigned classes go from \@classstart (excluded) to \@classend (included)
-% The boundary of character class is changed from 255 to 4095 in XeTeX
-% 0.99994. As above, we use \XeTeXinterwordspaceshaping as a flag.
-\ifdefined\XeTeXinterwordspaceshaping
- \chardef\@ucharclass@boundary=4095 %
-\else
- \chardef\@ucharclass@boundary=\@cclv
-\fi
-
% ----------------------------------------------------------------------------
% Use: \setTransitionsFor{block name}{when entering this block}{when leaving this block}
% ----------------------------------------------------------------------------