texlive[59958] Master/texmf-dist: cjk-ko (17jul21)

commits+karl at tug.org commits+karl at tug.org
Sat Jul 17 22:41:45 CEST 2021


Revision: 59958
          http://tug.org/svn/texlive?view=revision&revision=59958
Author:   karl
Date:     2021-07-17 22:41:45 +0200 (Sat, 17 Jul 2021)
Log Message:
-----------
cjk-ko (17jul21)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/cjk-ko/ChangeLog
    trunk/Master/texmf-dist/doc/latex/cjk-ko/README
    trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.pdf
    trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.tex
    trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-josa.sty
    trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-ko.sty
    trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-nanummjhanja.sty

Modified: trunk/Master/texmf-dist/doc/latex/cjk-ko/ChangeLog
===================================================================
--- trunk/Master/texmf-dist/doc/latex/cjk-ko/ChangeLog	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/doc/latex/cjk-ko/ChangeLog	2021-07-17 20:41:45 UTC (rev 59958)
@@ -1,3 +1,13 @@
+2021-07-17      Dohyun Kim <nomos at ktug org>
+
+	Version 2.0
+
+	* cjkutf8-ko.sty: use latex's cmd hooks;
+	allow non-ascii characters in LaTeX labels;
+	redefine MakeUppercase/Lowercase for Latin-1 supplement block;
+	care about fancyvrb's VerbatimOut environment;
+	load konames-utf.sty immediately.
+
 2021-03-01      Dohyun Kim <nomos at ktug org>
 
 	Version 1.9

Modified: trunk/Master/texmf-dist/doc/latex/cjk-ko/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/cjk-ko/README	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/doc/latex/cjk-ko/README	2021-07-17 20:41:45 UTC (rev 59958)
@@ -1,4 +1,4 @@
-CJK-ko package version 1.9 (2021/03/01)
+CJK-ko package version 2.0 (2021/07/17)
 =======================================
 
 This package supports typesetting of modern Korean documents with the help

Modified: trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.tex
===================================================================
--- trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.tex	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/doc/latex/cjk-ko/cjk-ko-doc.tex	2021-07-17 20:41:45 UTC (rev 59958)
@@ -9,12 +9,12 @@
 \fi
 \usepackage{geometry}
 \usepackage[cjk,hangul,usedotemph]{kotex}
-\usepackage{xcolor,hologo}
-\usepackage[pdfencoding=auto,
+\usepackage{xcolor,hologo,hyperref}
+\hypersetup{
   pdftitle={cjk-ko 간단 매뉴얼},
   pdfauthor={Dohyun Kim},
   pdfkeywords={CJK, LaTeX, Korean, ko.TeX}
-]{hyperref}
+}
 
 \def\cs#1{\texttt{\color{teal}\char92 \chardef\{=123 \chardef\}=125 #1}}
 \def\koTeX{\textsf{k}\kern-.1em\textit{o}.\kern-.1667em\TeX}
@@ -25,7 +25,7 @@
 \title{\cjkko\ 간단 매뉴얼}
 \author{Dohyun Kim \normalsize $<$\texttt{nomos at ktug org}$>$ \and
   \normalsize $<$\url{http://github.com/dohyunkim/cjk-ko}$>$}
-\date{Version 1.9\quad \today}
+\date{Version 2.0\quad \today}
 \begin{document}
 \maketitle
 

Modified: trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-josa.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-josa.sty	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-josa.sty	2021-07-17 20:41:45 UTC (rev 59958)
@@ -17,7 +17,7 @@
 % Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 % MA 02110-1301 USA
 
-\ProvidesPackage{cjkutf8-josa}[2021/03/01 v1.9 Automatic Josa selection for cjk-ko]
+\ProvidesPackage{cjkutf8-josa}[2021/07/17 v2.0 Automatic Josa selection for cjk-ko]
 
 \AtBeginDocument{
   \ifx\use at josa\undefined\else

Modified: trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-ko.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-ko.sty	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-ko.sty	2021-07-17 20:41:45 UTC (rev 59958)
@@ -17,8 +17,8 @@
 % Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston,
 % MA 02110-1301 USA
 
-\NeedsTeXFormat{LaTeX2e}[2020/10/01]
-\ProvidesPackage{cjkutf8-ko}[2021/03/01 v1.9 Hangul typesetting on CJKutf8]
+\NeedsTeXFormat{LaTeX2e}[2021/06/01]
+\ProvidesPackage{cjkutf8-ko}[2021/07/17 v2.0 Hangul typesetting on CJKutf8]
 
 \begingroup\expandafter\expandafter\expandafter\endgroup
 \expandafter\ifx\csname eTeXversion\endcsname\relax
@@ -84,7 +84,6 @@
 % font settings
 \ifx\usecjk@@font\undefined\else
   \PassOptionsToPackage{T1}{CJKutf8}
-  \RequirePackage{textcomp}
   \IfFileExists{t1\CJKKO at mjfont.fd}{\let\rmdefault\CJKKO at mjfont}{}
   \IfFileExists{t1\CJKKO at gtfont.fd}{\let\sfdefault\CJKKO at gtfont}{}
 \fi
@@ -160,21 +159,19 @@
 
 %%%%%%%%%%%%%%%%%%%%%%%%%
 % italic correction after cjk
-\edef\maybe at ic@{%
-  \unexpanded{%
+\AddToHook{cmd/maybe at ic@/before}{%
+  \let\CJKKO at wasCJK\undefined
+  \ifnum\lastkern=\@ne
+    \unkern\unkern
+    \let\CJKKO at wasCJK\empty
+  \fi
+}
+\AddToHook{cmd/maybe at ic@/after}{%
+  \ifx\CJKKO at wasCJK\empty
+    \CJK at CJK
+    \CJKKO at check@next at tok@
     \let\CJKKO at wasCJK\undefined
-    \ifnum\lastkern=\@ne
-      \unkern\unkern
-      \let\CJKKO at wasCJK\empty
-    \fi
-  }%
-  \unexpanded\expandafter{\maybe at ic@
-    \ifx\CJKKO at wasCJK\empty
-      \CJK at CJK
-      \CJKKO at check@next at tok@
-      \let\CJKKO at wasCJK\undefined
-    \fi
-  }%
+  \fi
 }
 
 %%%%%%%%%%%%%%%%%%%%%%%%%
@@ -194,8 +191,7 @@
   \ifx\usecjk@@font\undefined
   \ifx\CJK at scale\undefined\else
     % redefine \CJK at empty
-    \let\CJKKO@@empty\CJK at empty
-    \def\CJK at empty{\afterassignment\CJKKO@@empty at insert\CJKKO@@empty}
+    \AddToHook{cmd/CJK at empty/before}{\afterassignment\CJKKO@@empty at insert}
     \def\CJKKO@@empty at insert{\@tempdimb\CJK at scale\@tempdimb}
     % end of redefinition
     \if at hangul % hangul is main language
@@ -256,11 +252,8 @@
 \sfcode96=998 % `
 \sfcode102=998 % oms {
 \sfcode123=998 % t1 {
-\def\CJK at testLastCJK{%
-  \global\CJK at false
+\AddToHook{cmd/CJK at testLastCJK/after}{%
   \ifnum\lastkern=\@ne
-    \global \CJK at true
-  %%% inserted
   \else
     \ifhmode
     \ifnum\lastkern=\tw@\else
@@ -277,8 +270,8 @@
         \else \CJKglue \fi
       \fi
     \fi\fi\fi\fi\fi
-  %%% end of inserted
-  \fi}
+  \fi
+}
 
 %%%%%%%%%%%%%%%%%%%%%%%%%
 % half-width puncts
@@ -352,13 +345,8 @@
 \AtBeginDocument{
   \ifx\usecjk@@font\undefined
   \ifx\CJK at charlower\undefined\else
-    \expandafter\let
-    \expandafter\CJKKO at orig@CJKsymbol
-    \csname CJKsymbol \endcsname
-    \DeclareRobustCommand{\CJKsymbol}[1]{%
-      \leavevmode\lower\CJK at charlower\hbox\bgroup
-        \CJKKO at orig@CJKsymbol{#1}\egroup
-    }
+    \AddToHook{cmd/CJKsymbol/before}{\leavevmode\lower\CJK at charlower\hbox\bgroup}
+    \AddToHook{cmd/CJKsymbol/after}{\egroup}
   \fi\fi
 }
 
@@ -377,7 +365,7 @@
 % hangul captions, labels, and spacing
 \RequirePackage{kolabels-utf}
 \if at hangul
-  \AtBeginDocument{\RequirePackage{konames-utf}}
+  \RequirePackage{konames-utf}
   \linespread{1.3888}
   \footnotesep=1.3888\footnotesep
   \skip\footins=1.3888\skip\footins plus6pt minus3pt
@@ -395,15 +383,9 @@
   \ifx\pdfgentounicode\undefined\else
     \ifx\use at cjk@cmap@\relax % truetype
       \ifx\pdfnobuiltintounicode\undefined\else
-        \let\origin at l@CJK at addcmap\CJK at addcmap
-        \def\CJK at addcmap#1{\origin at l@CJK at addcmap{#1}%
-          \pdfnobuiltintounicode\font at name }
+        \AddToHook{cmd/CJK at addcmap/after}{\pdfnobuiltintounicode\font at name }
       \fi
     \else % type1
-      \IfFormatAtLeastTF{2021/05/01}{}
-        {\InputIfFileExists{glyphtounicode}
-          {\pdfgentounicode\@ne}{}
-        }
       \let\CJK at addcmap\@gobble
     \fi
   \fi
@@ -410,40 +392,106 @@
 \fi
 
 %%%%%%%%%%%%%%%%%%%%%%%%%
-%%% \makeindex in memoir class clashed with this package.
-%%% cause:  memoir appempts to write index entries to a file
-%%% at the end of document without protecting active characters.
-%%% spotted by Juho Lee. thanks to him.
-%\AtEndDocument{\CJK at makeInactive}
-%%% still conflicts with package verbments.
-%%% so now we make utf8 characters robust.
-\count@"C2 \loop
-  \uccode\count@\count@
-  \lccode\count@\count@
-  \begingroup
-  \lccode`\~\count@
-  \lowercase{\endgroup
-  \protected\edef~{\unexpanded\expandafter{~}}}
-\ifnum\count@<"F4 \advance\count@\@ne \repeat
-% then we have to care about hyperref bookmarks.
+% allow non-cjk characters in labels
+\def\CJK at XX#1#2{%
+  \ifx #2\protect
+    \expandafter\CJK at XXp\expandafter#1%
+  \else
+    \ifincsname \string#1\string#2\else % added
+      \expandafter\ifx\csname u8:\string #1\string #2\endcsname \relax
+        \csname CJK@\number `#1\endcsname{`#2}%
+        \expandafter\expandafter % added wrt allowbreak before (
+        \expandafter\CJK at ignorespaces
+      \else
+        \csname u8:\string #1\string #2\endcsname
+      \fi
+    \fi % added
+  \fi}
+\def\CJK at XXX#1#2#3{%
+  \ifx #2\protect
+    \expandafter\CJK at XXXp\expandafter#1#3%
+  \else
+    \ifincsname \string#1\string#2\string#3\else % added
+      \expandafter\ifx\csname u8:\string #1\string #2\string #3\endcsname \relax
+        \csname CJK@\number `#1\endcsname{`#2}{`#3}%
+        \expandafter\expandafter % added wrt allowbreak before (
+        \expandafter\CJK at ignorespaces
+      \else
+        \csname u8:\string #1\string #2\string #3\endcsname
+      \fi
+    \fi % added
+  \fi}
+\def\CJK at XXXX#1#2#3#4{%
+  \ifx #2\protect
+    \expandafter\CJK at XXXXp\expandafter#1#3%
+  \else
+    \ifincsname \string#1\string#2\string#3\string#4\else % added
+      \csname CJK@\number `#1\endcsname{`#2}{`#3}{`#4}%
+      \expandafter % added wrt allowbreak before (
+      \CJK at ignorespaces
+    \fi % added
+  \fi}
+
+%%%%%%%%%%%%%%%%%%%%%%%%%
+% protect against lowercase
+\count@="80 \loop
+  \lccode\count@=\count@
+  \ifnum\count@<"DF \advance\count@\@ne \repeat
+% redefine MakeUppercase/MakeLowercase
+\DeclareRobustCommand{\MakeUppercase}[1]{{%
+  % begin patch
+  \count@"A0 \loop
+    \ifnum\count@="B7 \else
+      \begingroup
+      \@tempcnta\count@ \advance\@tempcnta-"20
+      \lccode`\~\count@ \lccode`\!\@tempcnta \lccode"C3="C3\relax
+      \lowercase{\endgroup
+        \expandafter\def\csname u8:\string^^c3\string~\endcsname{^^c3!}}%
+    \fi
+  \ifnum\count@<"BE \advance\count@\@ne \repeat
+  % end patch
+  \def\i{I}\def\j{J}%
+  \def\reserved at a##1##2{\let##1##2\reserved at a}%
+  \expandafter\reserved at a\@uclclist\reserved at b{\reserved at b\@gobble}%
+  \let\UTF at two@octets at noexpand\@empty
+  \let\UTF at three@octets at noexpand\@empty
+  \let\UTF at four@octets at noexpand\@empty
+  \protected at edef\reserved at a{\uppercase{#1}}%
+  \reserved at a
+}}
+\DeclareRobustCommand{\MakeLowercase}[1]{{%
+  % begin patch
+  \count@"80 \loop
+    \ifnum\count@="97 \else
+      \begingroup
+      \@tempcnta\count@ \advance\@tempcnta "20
+      \lccode`\~\count@ \lccode`\!\@tempcnta \lccode"C3="C3\relax
+      \lowercase{\endgroup
+        \expandafter\def\csname u8:\string^^c3\string~\endcsname{^^c3!}}%
+    \fi
+  \ifnum\count@<"9E \advance\count@\@ne \repeat
+  % end patch
+  \def\reserved at a##1##2{\let##2##1\reserved at a}%
+  \expandafter\reserved at a\@uclclist\reserved at b{\reserved at b\@gobble}%
+  \let\UTF at two@octets at noexpand\@empty
+  \let\UTF at three@octets at noexpand\@empty
+  \let\UTF at four@octets at noexpand\@empty
+  \protected at edef\reserved at a{\lowercase{#1}}%
+  \reserved at a
+}}
+\protected at edef\MakeUppercase#1{\MakeUppercase{#1}}
+\protected at edef\MakeLowercase#1{\MakeLowercase{#1}}
+
+%%% for fancyvrb/verbments package
+\AddToHook{env/VerbatimOut/begin}{\CJK at makeInactive}
+
+%%% hyperref bookmarks.
 \ifx\pdfstringdefPreHook\undefined
   \let\pdfstringdefPreHook\empty
 \fi
 \g at addto@macro\pdfstringdefPreHook{%
-  \count@"C2 \loop
-  \begingroup
-  \lccode`\~\count@
-  \lowercase{\endgroup
-  \edef~{\unexpanded\expandafter{~}}}%
-  \ifnum\count@<"F4 \advance\count@\@ne \repeat
-  % and dotemph as well
   \let\dotemph\@firstofone
 }
-% protect against lowercase
-\count@"80 \loop
-  \uccode\count@\count@
-  \lccode\count@\count@
-\ifnum\count@<"BF \advance\count@\@ne \repeat
 
 %%% ignore variation selectors for korean hanja
 \DeclareUnicodeCharacter{FE00}{}

Modified: trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-nanummjhanja.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-nanummjhanja.sty	2021-07-17 20:41:26 UTC (rev 59957)
+++ trunk/Master/texmf-dist/tex/latex/cjk-ko/cjkutf8-nanummjhanja.sty	2021-07-17 20:41:45 UTC (rev 59958)
@@ -18,7 +18,7 @@
 % MA 02110-1301 USA
 
 \ProvidesPackage{cjkutf8-nanummjhanja}
-  [2021/03/01 v1.9 UHC hanja for Nanum Myeongjo]
+  [2021/07/17 v2.0 UHC hanja for Nanum Myeongjo]
 
 \def\CJKKO at mjdefault{nanummj}
 \def\CJKKO at mjhanjafamily{\def\CJK at family{uhcmj}}



More information about the tex-live-commits mailing list.