summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/gckanbun/LICENSE9
-rw-r--r--Master/texmf-dist/doc/latex/gckanbun/README.md26
-rw-r--r--Master/texmf-dist/doc/latex/gckanbun/gckanbun.pdfbin0 -> 75281 bytes
-rw-r--r--Master/texmf-dist/doc/latex/gckanbun/gckanbun.tex94
-rw-r--r--Master/texmf-dist/doc/latex/gckanbun/test-gckanbun.tex177
-rw-r--r--Master/texmf-dist/tex/latex/gckanbun/gckanbun.sty185
-rw-r--r--Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc1
-rw-r--r--Master/tlpkg/tlpsrc/gckanbun.tlpsrc0
8 files changed, 492 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/gckanbun/LICENSE b/Master/texmf-dist/doc/latex/gckanbun/LICENSE
new file mode 100644
index 00000000000..69ab849d662
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/gckanbun/LICENSE
@@ -0,0 +1,9 @@
+This package is licensed under the terms of the MIT License.
+
+Copyright (c) 2017-2021 Munehiro Yamamoto <munepixyz@gmail.com>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
diff --git a/Master/texmf-dist/doc/latex/gckanbun/README.md b/Master/texmf-dist/doc/latex/gckanbun/README.md
new file mode 100644
index 00000000000..f61de1d5c94
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/gckanbun/README.md
@@ -0,0 +1,26 @@
+# gckanbun Package
+
+KANBUN ("Chinese writing") typesetting for (u)pLaTeX and LuaLaTeX
+
+This package provides a KANBUN (漢文, "Chinese writing") typesetting for (u)pLaTeX and LuaLaTeX.
+
+## Requirements
+
+ * recent [TeX Live](https://www.tug.org/texlive/) environment
+ (TeX Live 2017 or higher release version)
+
+
+## Installation
+
+Copy: `gckanbun.sty` -> `$TEXMF/tex/latex/gckanbun/`
+
+
+## License
+
+This package is licensed under the terms of the MIT License.
+
+
+--------------------
+
+Munehiro Yamamoto
+https://github.com/munepi
diff --git a/Master/texmf-dist/doc/latex/gckanbun/gckanbun.pdf b/Master/texmf-dist/doc/latex/gckanbun/gckanbun.pdf
new file mode 100644
index 00000000000..0ee35e61ab9
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/gckanbun/gckanbun.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/gckanbun/gckanbun.tex b/Master/texmf-dist/doc/latex/gckanbun/gckanbun.tex
new file mode 100644
index 00000000000..ca18693f995
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/gckanbun/gckanbun.tex
@@ -0,0 +1,94 @@
+% #!lualatex
+% #!ptex2pdf -l -u
+%#!ptex2pdf -l
+\documentclass{jlreq}\listfiles
+\usepackage[prefix=]{gckanbun}%%=> <prefix>=(empty)
+\usepackage{shortvrb}\MakeShortVerb{\|}
+
+\newcommand*\pLaTeX{p\kern-.05em\LaTeX}
+\newcommand*\upLaTeX{up\kern-.05em\LaTeX}
+\newcommand*\LuaLaTeX{Lua\LaTeX}
+
+\title{\textsf{gckanbun} Package}
+\author{Munehiro Yamamoto}
+\date{2021/03/27 v1.2}
+\begin{document}
+\maketitle
+
+\begin{abstract}
+This package provides a KANBUN (漢文) typesetting for (u){\pLaTeX} and \LuaLaTeX.
+
+このパッケージは、(u){\pLaTeX}と{\LuaLaTeX}に対して漢文組みを提供します。
+\end{abstract}
+
+\section{\textsf{gckanbun}パッケージの読み込み}
+
+\textsf{gckanbun}パッケージを読み込むだけです。
+
+{\LuaLaTeX}の場合、\textsf{luatexja}パッケージをあらかじめ読み込んでおく必要があります。
+なお、\textsf{jlreq}クラスを利用すると、\textsf{jlreq}クラス内部で\textsf{luatexja}パッケージを読み込みます。
+
+\begin{quote}
+\begin{verbatim}
+%\usepackage{luatexja}%%<= LuaLaTeXの場合
+\usepackage[<オプション>]{gckanbun}
+\end{verbatim}
+\end{quote}
+
+利用可能なオプションは以下のとおりです。
+\begin{itemize}
+\item |prefix=<prefix>|(デフォルト値:|gckanbun|):
+\textsf{gckanbun}パッケージが提供する3つのコマンド|\gckanbunruby|、|\gckanbunokurigana|、|\gckanbunkaeriten|をそれぞれ|\<prefix>ruby|、|\<prefix>okurigana|、|\<prefix>kaeriten|として提供します。
+
+このオプションにより、他のパッケージで提供されるルビ振りコマンド|\ruby|との衝突を避けられます。
+\end{itemize}
+
+\section{例}
+
+以下の{\LaTeX}文章を{\LuaLaTeX}でタイプセットします。
+つまり、|lualatex|コマンドを実行します。
+
+\begin{quote}
+\small
+\begin{verbatim}
+%#!lualatex
+\documentclass[tate]{jlreq}
+\usepackage[prefix=]{gckanbun}%%=> <prefix>を「なし」としました。
+\begin{document}
+自\okurigana{リ}\kaeriten{二}桓公\kaeriten{一}八世\okurigana{ニシテ}
+至\okurigana{ル}\kaeriten{二}景公\okurigana{ニ}\kaeriten{一}。
+有\okurigana{リ}\kaeriten{二}晏子\okurigana{トイフ}者\kaeriten{一}、
+\ruby{事}{つか}\okurigana{フ}\kaeriten{レ}之\okurigana{ニ}。
+名\okurigana{ハ}嬰、\ruby{字}{あざな}\okurigana{ハ}平仲。
+以\okurigana{テ}\kaeriten{二}節倹力行\okurigana{ヲ}\kaeriten{一}
+重\okurigana{ンゼラル}\kaeriten{二}於齊\okurigana{ニ}\kaeriten{一}。
+\ruby{一}{いっ}\ruby{狐}{こ}\ruby{裘}{きゅう}三十年、
+豚肩不\kaeriten{レ}\ruby{掩}{おお}\okurigana{ハ}\kaeriten{レ}豆。
+齊國之士、待\okurigana{チテ}以\okurigana{テ}擧\okurigana{グル}\kaeriten{レ}
+火\okurigana{ヲ}者、七十餘家\okurigana{アリ}。
+\end{document}
+\end{verbatim}
+\end{quote}
+
+このとき、結果は以下のとおりです。
+
+\begin{center}
+\hbox{\tate
+\vbox to \hsize{\vfil
+\begin{minipage}{15\zw}
+自\okurigana{リ}\kaeriten{二}桓公\kaeriten{一}八世\okurigana{ニシテ}
+至\okurigana{ル}\kaeriten{二}景公\okurigana{ニ}\kaeriten{一}。
+有\okurigana{リ}\kaeriten{二}晏子\okurigana{トイフ}者\kaeriten{一}、
+\ruby{事}{つか}\okurigana{フ}\kaeriten{レ}之\okurigana{ニ}。
+名\okurigana{ハ}嬰、\ruby{字}{あざな}\okurigana{ハ}平仲。
+以\okurigana{テ}\kaeriten{二}節倹力行\okurigana{ヲ}\kaeriten{一}
+重\okurigana{ンゼラル}\kaeriten{二}於齊\okurigana{ニ}\kaeriten{一}。
+\ruby{一}{いっ}\ruby{狐}{こ}\ruby{裘}{きゅう}三十年、
+豚肩不\kaeriten{レ}\ruby{掩}{おお}\okurigana{ハ}\kaeriten{レ}豆。
+齊國之士、待\okurigana{チテ}以\okurigana{テ}擧\okurigana{グル}\kaeriten{レ}
+火\okurigana{ヲ}者、七十餘家\okurigana{アリ}。
+\end{minipage}
+\vfil}}%
+\end{center}
+
+\end{document}
diff --git a/Master/texmf-dist/doc/latex/gckanbun/test-gckanbun.tex b/Master/texmf-dist/doc/latex/gckanbun/test-gckanbun.tex
new file mode 100644
index 00000000000..f00ed7eba07
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/gckanbun/test-gckanbun.tex
@@ -0,0 +1,177 @@
+%% https://gist.github.com/munepi/5c9e53936e3540b8374b4ab14e6b7832
+%#!lualatex
+% #!ptex2pdf -l -u
+\documentclass[paper=a5,tate]{jlreq}\listfiles
+%\usepackage{gckanbun}%%=> provides \gckanbunruby, \gckanbunokurigana, \gckanbunkaeriten as default
+\usepackage[prefix=]{gckanbun}%%=> provides \ruby, \okurigana, \kaeriten
+%\usepackage[prefix=kanbun]{gckanbun}%%=> provides \kanbunruby, \kanbunokurigana, \kanbunkaeriten
+
+\newcommand*{\onelineskip}{\par\vspace{\baselineskip}\par}
+\begin{document}
+【訓点(返り点・訓点送り仮名)】
+
+% Tateten(縦点)
+% Unicode 表示 名称 備考
+U+3190 ㆐ %IDEOGRAPHIC ANNOTATION LINKING MARK
+
+% Kaeriten(返り点)
+% Unicode 表示 名称 備考
+U+3191 ㆑ %IDEOGRAPHIC ANNOTATION REVERSE MARK
+U+3192 ㆒ %IDEOGRAPHIC ANNOTATION ONE MARK
+U+3193 ㆓ %IDEOGRAPHIC ANNOTATION TWO MARK
+U+3194 ㆔ %IDEOGRAPHIC ANNOTATION THREE MARK
+U+3195 ㆕ %IDEOGRAPHIC ANNOTATION FOUR MARK
+U+3196 ㆖ %IDEOGRAPHIC ANNOTATION TOP MARK
+U+3197 ㆗ %IDEOGRAPHIC ANNOTATION MIDDLE MARK
+U+3198 ㆘ %IDEOGRAPHIC ANNOTATION BOTTOM MARK
+U+3199 ㆙ %IDEOGRAPHIC ANNOTATION FIRST MARK
+U+319A ㆚ %IDEOGRAPHIC ANNOTATION SECOND MARK
+U+319B ㆛ %IDEOGRAPHIC ANNOTATION THIRD MARK
+U+319C ㆜ %IDEOGRAPHIC ANNOTATION FOURTH MARK
+U+319D ㆝ %IDEOGRAPHIC ANNOTATION HEAVEN MARK
+U+319E ㆞ %IDEOGRAPHIC ANNOTATION EARTH MARK
+U+319F ㆟ %IDEOGRAPHIC ANNOTATION MAN MARK
+
+%% 以下のサンプルは、青空文庫の訓点 https://www.aozora.gr.jp/annotation/kunten.html を元にしています。
+[返り点]
+% 自[#二]女王國[#一]東度[#レ]海千餘里。
+
+①
+自\kaeriten{㆓}女王國\kaeriten{㆒}東度\kaeriten{㆑}海千餘里。
+
+②レ点とその他の返り点が組み合わさっている場合
+% 見[#二]大人所[#一レ]敬。
+
+見\kaeriten{㆓}大人所\kaeriten{㆒㆑}敬。
+
+③竪点と返り点の記載順
+% 而敬‐[#二]祭天神地祇[#一]。
+
+而敬\kaeriten-{㆓}祭天神地祇\kaeriten{㆒}。
+而敬\kaeriten‐{㆓}祭天神地祇\kaeriten{㆒}。
+
+[訓点送り仮名]
+% 山城[#(ノ)]國久世[#(ノ)]郡水主[#(ニ)]坐[#(ス)]山背[#(ノ)]大國魂命[#(ノ)]神、
+
+①
+山城\okurigana{ノ}國久世\okurigana{ノ}郡水主\okurigana{ニ}坐\okurigana{ス}山背\okurigana{ノ}大國魂命\okurigana{ノ}神、
+
+②訓点送り仮名として、漢字(万葉仮名)が用いられている場合
+% 爾時倭姫命見悦給[#(弖)]、其處[#(爾)]魚見社定賜[#(支)]とあり。
+
+爾時倭姫命見悦給\okurigana{弖}、其處\okurigana{爾}魚見社定賜\okurigana{支}とあり。
+
+[返り点と訓点送り仮名の混在]
+% 噛[#(テ)][#二]古人貧交行[#(ノ)]之詩[#(ヲ)][#一]吐[#(テ)]而戯序[#(ス)]
+
+噛\okurigana{テ}\kaeriten{㆓}古人貧交行\okurigana{ノ}之詩\okurigana{ヲ}\kaeriten{㆒}吐\okurigana{テ}而戯序\okurigana{ス}
+
+[例]
+\ruby{一}{いっ}\ruby{狐}{こ}\ruby{裘}{きゅう}三十年
+
+自\okurigana{リ}\kaeriten{二}
+桓公\kaeriten{一}
+八世\okurigana{ニシテ}
+至\okurigana{ル}\kaeriten{二}
+景公\okurigana{ニ}\kaeriten{一}。
+有\okurigana{リ}\kaeriten{二}
+晏
+子\okurigana{トイフ}
+者\kaeriten{一}、
+\ruby{事}{つか}\okurigana{フ}\kaeriten{レ}
+之\okurigana{ニ}。
+名\okurigana{ハ}
+嬰、
+\ruby{字}{あざな}\okurigana{ハ}平仲。
+以\okurigana{テ}\kaeriten{二}
+節倹力
+行\okurigana{ヲ}\kaeriten{一}
+重\okurigana{ンゼラル}\kaeriten{二}
+於
+齊\okurigana{ニ}\kaeriten{一}。
+\ruby{一}{いっ}
+\ruby{狐}{こ}
+\ruby{裘}{きゅう}
+三十年、豚肩
+不\kaeriten{レ}
+\ruby{掩}{おお}\okurigana{ハ}\kaeriten{レ}
+豆。齊國之士、
+待\okurigana{チテ}
+以\okurigana{テ}
+擧\okurigana{グル}\kaeriten{レ}
+火\okurigana{ヲ}
+者、七十餘家\okurigana{アリ}。
+
+晏子
+出\okurigana{ヅ}。
+其\okurigana{ノ}御之妻、
+従\okurigana{リ}\kaeriten{二}
+門間\kaeriten{一}
+窺\okurigana{ヘバ}、
+其\okurigana{ノ}夫
+擁\okurigana{シ}\kaeriten{二}
+大蓋\okurigana{ヲ}\kaeriten{一}、
+\ruby{策}{むちう}\okurigana{チ}\kaeriten{二}
+駟馬\okurigana{ヲ}\kaeriten{一}、
+意気揚揚\okurigana{トシテ}
+自得\okurigana{ス}。
+既\okurigana{ニシテ}而
+帰\okurigana{ル}。
+妻請\okurigana{ヒテ}\kaeriten{レ}
+去\okurigana{ランコトヲ}
+曰\okurigana{ハク}、
+「晏子\okurigana{ハ}
+身相\okurigana{トシテ}\kaeriten{二}
+齊國\okurigana{ニ}\kaeriten{一}、
+名顯\okurigana{ハル}\kaeriten{二}
+諸侯\okurigana{ニ}\kaeriten{一}。
+観\okurigana{ルニ}\kaeriten{二}
+其\okurigana{ノ}
+志\okurigana{ヲ}\kaeriten{一}、
+\ruby{嘗}{つね}\okurigana{ニ}
+有\okurigana{リ}\kaeriten{二}
+以\okurigana{テ}
+自\okurigana{ラ}
+下\okurigana{ルコト}\kaeriten{一}。
+子\okurigana{ハ}
+為\okurigana{リテ}\kaeriten{二}
+人\okurigana{ノ}
+僕御\okurigana{ト}\kaeriten{一}、
+自\okurigana{ラ}
+以\okurigana{テ}
+為\okurigana{ス}\kaeriten{レ}
+足\okurigana{レリト}。
+妾是\okurigana{ヲ}
+以\okurigana{テ}
+求\okurigana{ムル}\kaeriten{レ}
+去\okurigana{ランコトヲ}
+也\okurigana{ト}。」
+御者\ruby{乃}{すなわ}\okurigana{チ}
+自\okurigana{ラ}
+抑損\okurigana{ス}。
+晏子
+怪\okurigana{ミテ}
+而問\okurigana{フ}\kaeriten{レ}
+之\okurigana{ヲ}。
+以\okurigana{テ}\kaeriten{レ}
+實\okurigana{ヲ}
+\ruby{対}{こた}\okurigana{フ}。
+薦\okurigana{メテ}
+為\okurigana{セリ}\kaeriten{二}
+大夫\okurigana{ト}\kaeriten{一}。
+
+\onelineskip
+
+漢文に対するふりがなは、モノルビ仕様です。
+例えば、「\ruby{母}{ぼ}\ruby{字}{じ}\okurigana{ト}」。
+漢文に対するふりがなをグループルビとすると、
+「\ruby{母字}{ぼじ}\okurigana{ト}」となり、正しく組版されません。
+
+\ruby{□}{ふ}\okurigana{オクリガナ}\kaeriten{一レ}
+\ruby{□}{ふり}\okurigana{オクリガナ}\kaeriten{一レ}
+□\okurigana{オクリ}\kaeriten{一レ}。
+□\okurigana{ランコトヲ}\kaeriten{一}□□□□□
+□\okurigana{ト}\kaeriten{二}、□□□□□
+□\okurigana{ト}\kaeriten{三}。
+
+\end{document}
diff --git a/Master/texmf-dist/tex/latex/gckanbun/gckanbun.sty b/Master/texmf-dist/tex/latex/gckanbun/gckanbun.sty
new file mode 100644
index 00000000000..c2763d60e98
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/gckanbun/gckanbun.sty
@@ -0,0 +1,185 @@
+%#!lualatex test-gckanbun
+% #!ptex2pdf -l -u test-gckanbun
+% #!ptex2pdf -l test-gckanbun
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{gckanbun}
+ [2021/03/27 v1.2 KANBUN typesetting package (Green Cherry Ltd.)]
+
+%% declare package errors
+\def\gcknbn@error{\PackageError{gckanbun}}
+\def\gcknbn@warning{\PackageWarning{gckanbun}}
+\def\gcknbn@warningnoline{\PackageWarningNoLine{gckanbun}}
+\def\gcknbn@info{\PackageInfo{gckanbun}}
+
+\RequirePackage{keyval}
+\DeclareOption*{\gcknbn@setkey}
+\def\gcknbn@setkey{\expandafter\@gcknbn@setkey\expandafter{\CurrentOption}}
+\def\@gcknbn@setkey{\setkeys{gcknbn}}
+\def\gcknbn@prefix{gckanbun}%%given <prefix> for each commands
+\define@key{gcknbn}{prefix}{\gdef\gcknbn@prefix{#1}}
+
+\ExecuteOptions{prefix}
+\ProcessOptions\relax
+
+%% auto-detect engine
+\RequirePackage{ifuptex}
+\RequirePackage{ifluatex}
+\ifluatex
+ \@ifpackageloaded{luatexja}{}{%
+ \gcknbn@error{Please load package 'luatexja' when loading this package.}}
+\else\ifuptex
+ \def\zw{zw}\def\zh{zh}
+\else\ifptex
+ \def\zw{zw}\def\zh{zh}
+\else
+ \gcknbn@error{Package 'gckanbun' currently supports (u)pLaTeX and LuaLaTeX.}
+\fi\fi\fi
+
+\newcommand*\gcknbn@kanjiskip@fill{%
+ \ifluatex
+ \ltjsetparameter{kanjiskip=\fill}%
+ \else
+ \kanjiskip=\fill\relax
+ \fi
+}
+
+%% ルビ
+%% * グループルビ
+%% * 漢文訓点に対するふりがな(モノルビ)
+\let\gcknbn@rubybox@text\relax
+\newdimen\gcknbn@rubybox@width
+\newdimen\gcknbn@furigana@width \gcknbn@furigana@width\z@
+\newdimen\gcknbn@dima
+\DeclareRobustCommand*\gcknbn@ruby[2]{%
+ \leavevmode% \setbox0=\hbox{#1}\setbox1=\hbox{\tiny#2}%
+ \begingroup
+ \gcknbn@dima\f@size\p@\relax \divide\gcknbn@dima by \tw@
+ \def\tiny{\@setfontsize\tiny{\gcknbn@dima}{\z@}}%
+ \setbox\z@=\hbox{#1}\setbox\@ne=\hbox{\tiny#2}%
+ \gdef\gcknbn@rubybox@text{#2}%
+ \global\gcknbn@rubybox@width=\wd\z@\relax
+ \gcknbn@furigana@okurigana}
+
+\def\gcknbn@furigana@okurigana{%
+ \futurelet\@let@token\gcknbn@@furigana@okurigana}
+\def\gcknbn@@furigana@okurigana{%
+ \ifx\@let@token\gcknbn@okurigana
+ \global\gcknbn@furigana@width=\wd\@ne\relax
+ \dimen\z@=\wd\z@
+ \smash{\hbox{%
+ \vbox{\hbox to \dimen\z@{\box\@ne\hss}%
+ \nointerlineskip\hbox to \dimen\z@{\hfil\box\z@\hfil}}}}%
+ \else
+ \ifdim\wd\z@>\wd\@ne\dimen\z@=\wd\z@\else\dimen\z@=\wd\@ne\fi
+ \penalty\@lowpenalty
+ \smash{\hbox{\gcknbn@kanjiskip@fill
+ \vbox{\hbox to \dimen\z@{\tiny\hfil\gcknbn@rubybox@text\hfil}%
+ \nointerlineskip\hbox to \dimen\z@{\hfil\box\z@\hfil}}}}%
+ \fi
+ \endgroup}
+
+%% 訓点
+\newdimen\gcknbn@okurigana@width \gcknbn@okurigana@width\z@
+\newdimen\gcknbn@kaeriten@width \gcknbn@kaeriten@width\z@
+%%訓点送り仮名
+\newcommand*\gcknbn@okurigana[1]{%
+ \nobreak\leavevmode
+ \begingroup
+ \gcknbn@dima\f@size\p@\relax \divide\gcknbn@dima by \tw@
+ \def\tiny{\@setfontsize\tiny{\gcknbn@dima}{\z@}}%
+ \setbox\z@=\hbox{\tiny #1}%
+ \ifdim\gcknbn@furigana@width>0.9999\zw\relax
+ \global\gcknbn@okurigana@width=\dimexpr\gcknbn@furigana@width + \wd\z@ - 1\zw\relax
+ \else
+ \global\gcknbn@okurigana@width=\dimexpr\wd\z@ - .5\zw\relax
+ \fi
+ \smash{\hbox{%
+ \vbox{\hbox to \gcknbn@okurigana@width{%
+ \ifdim\gcknbn@furigana@width>0.9999\zw\relax
+ \hspace*{\dimexpr\gcknbn@furigana@width - 1\zw\relax}%
+ \else
+ \hspace*{-.5\zw}%
+ \fi
+ \box\z@}%
+ \nointerlineskip
+ \hbox to \gcknbn@okurigana@width{\hfil\vphantom{\char\euc"A1A1%"
+ }\hfil}}}}%
+ \global\gcknbn@furigana@width=\z@\relax
+ \gcknbn@okurigana@kaeriten}
+
+\def\gcknbn@okurigana@kaeriten{%
+ \futurelet\@let@token\gcknbn@@okurigana@kaeriten}
+\def\gcknbn@@okurigana@kaeriten{%
+ \ifx\@let@token、
+ \gcknbn@okurigana@kutoten@skip
+ \global\gcknbn@okurigana@width=\z@
+ \else\ifx\@let@token。
+ \gcknbn@okurigana@kutoten@skip
+ \global\gcknbn@okurigana@width=\z@
+ \else\ifx\@let@token\gcknbn@kaeriten
+ \gcknbn@okurigana@kaeriten@skip
+ \fi\fi\fi
+ \endgroup}
+\def\gcknbn@okurigana@kutoten@skip{%
+ \hspace*{-\gcknbn@okurigana@width}}
+\def\gcknbn@okurigana@kaeriten@skip{%
+ \hspace*{-\gcknbn@okurigana@width}}
+
+%%訓点返り点
+\newcommand*\gcknbn@kaeriten{%
+ \@ifnextchar-{\gcknbn@tateten@kaeriten@hh}{%
+ \@ifnextchar‐{\gcknbn@tateten@kaeriten@zh}{%
+ \gcknbn@@kaeriten}}}
+
+\newcommand*\gcknbn@@kaeriten[1]{%
+ \nobreak\leavevmode
+ \begingroup
+ \gcknbn@dima\f@size\p@\relax \divide\gcknbn@dima by \tw@
+ \def\tiny{\@setfontsize\tiny{\gcknbn@dima}{\z@}}%
+ \setbox\z@=\hbox{\tiny #1}%
+ \global\gcknbn@kaeriten@width=\wd\z@\relax
+ \smash{\lower.25\zw\hbox{\box\z@\hss}}%
+ \endgroup\gcknbn@kaeriten@kutoten}
+
+\def\gcknbn@kaeriten@kutoten{\futurelet\@let@token\gcknbn@@kaeriten@kutoten}
+\def\gcknbn@@kaeriten@kutoten{%
+ \ifx\@let@token、
+ \gcknbn@kaeriten@kutoten@skip
+ \global\gcknbn@kaeriten@width=\z@
+ \else\ifx\@let@token。
+ \gcknbn@kaeriten@kutoten@skip
+ \global\gcknbn@kaeriten@width=\z@
+ \else
+ \gcknbn@kaeriten@okurigana@skip
+ \fi\fi
+}
+\def\gcknbn@kaeriten@kutoten@skip{%
+ \hspace*{-\gcknbn@kaeriten@width}%
+}
+\def\gcknbn@kaeriten@okurigana@skip{%
+ \ifdim\gcknbn@okurigana@width>\gcknbn@kaeriten@width
+ \hspace*{\dimexpr\gcknbn@okurigana@width - \gcknbn@kaeriten@width}%
+ \fi
+}
+
+\def\gcknbn@tateten@kaeriten@hh-{\gcknbn@@tateten@kaeriten}
+\def\gcknbn@tateten@kaeriten@zh‐{\gcknbn@@tateten@kaeriten}
+\newcommand*\gcknbn@@tateten@kaeriten[1]{%
+ \nobreak\leavevmode
+ \begingroup
+ \gcknbn@dima\f@size\p@\relax \divide\gcknbn@dima by \tw@
+ \def\tiny{\@setfontsize\tiny{\gcknbn@dima}{\z@}}%
+ \setbox\z@=\hbox{\tiny\char"3190}%"
+ \global\gcknbn@kaeriten@width=\wd\z@\relax
+ \smash{\lower.35\zw\hbox{%
+ \vbox{\hbox to \gcknbn@kaeriten@width{\hfil\box\z@\hfil}%
+ \vspace*{-.1\zw}%
+ \nointerlineskip\hbox to \gcknbn@kaeriten@width{\tiny\hfil#1\hfil}}}}%
+ \endgroup}
+
+%% Finaly, provide \<prefix>ruby, \<prefix>okurigana, \<prefix>kaeriten
+\expandafter\let\csname\gcknbn@prefix ruby\endcsname\gcknbn@ruby
+\expandafter\let\csname\gcknbn@prefix okurigana\endcsname\gcknbn@okurigana
+\expandafter\let\csname\gcknbn@prefix kaeriten\endcsname\gcknbn@kaeriten
+
+\endinput
diff --git a/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc b/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc
index 5d7dfe49472..e5a5ed6b426 100644
--- a/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc
+++ b/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc
@@ -18,6 +18,7 @@ depend bxorigcapt
depend bxwareki
depend convbkmk
depend endnotesj
+depend gckanbun
depend gentombow
depend haranoaji
depend haranoaji-extra
diff --git a/Master/tlpkg/tlpsrc/gckanbun.tlpsrc b/Master/tlpkg/tlpsrc/gckanbun.tlpsrc
new file mode 100644
index 00000000000..e69de29bb2d
--- /dev/null
+++ b/Master/tlpkg/tlpsrc/gckanbun.tlpsrc