From 842f71390eec867321cb3cbb30107a5a12e962c3 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sat, 10 Jun 2017 21:42:08 +0000 Subject: bxjaprnind (10jun17) git-svn-id: svn://tug.org/texlive/trunk@44554 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/latex/bxjaprnind/LICENSE | 21 ++ .../texmf-dist/doc/latex/bxjaprnind/README-ja.md | 45 +++ Master/texmf-dist/doc/latex/bxjaprnind/README.md | 61 ++++ .../texmf-dist/doc/latex/bxjaprnind/bxjaprnind.pdf | Bin 0 -> 365765 bytes .../texmf-dist/doc/latex/bxjaprnind/bxjaprnind.tex | 118 +++++++ .../doc/latex/bxjaprnind/sample-bxjaprnind.pdf | Bin 0 -> 67452 bytes .../doc/latex/bxjaprnind/sample-bxjaprnind.tex | 131 ++++++++ .../texmf-dist/tex/latex/bxjaprnind/bxjaprnind.sty | 359 +++++++++++++++++++++ Master/tlpkg/bin/tlpkg-ctan-check | 2 +- Master/tlpkg/tlpsrc/bxjaprnind.tlpsrc | 0 Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc | 1 + 11 files changed, 737 insertions(+), 1 deletion(-) create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/LICENSE create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/README-ja.md create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/README.md create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.pdf create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.tex create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.pdf create mode 100644 Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.tex create mode 100644 Master/texmf-dist/tex/latex/bxjaprnind/bxjaprnind.sty create mode 100644 Master/tlpkg/tlpsrc/bxjaprnind.tlpsrc (limited to 'Master') diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/LICENSE b/Master/texmf-dist/doc/latex/bxjaprnind/LICENSE new file mode 100644 index 00000000000..61a74fd2d15 --- /dev/null +++ b/Master/texmf-dist/doc/latex/bxjaprnind/LICENSE @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2013 Takayuki YATO (aka. "ZR") + +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/bxjaprnind/README-ja.md b/Master/texmf-dist/doc/latex/bxjaprnind/README-ja.md new file mode 100644 index 00000000000..41f194c849b --- /dev/null +++ b/Master/texmf-dist/doc/latex/bxjaprnind/README-ja.md @@ -0,0 +1,45 @@ +BXjaprnind パッケージ +===================== + +LaTeX: 段落頭の開き括弧類の位置の自動調整 + +段落冒頭および強制改行後の行頭における開き括弧の位置をユーザが予め +設定した値に自動的に調整する。 + +### 対応環境 + + - TeX フォーマット: LaTeX + - TeX エンジン: pTeX/upTeX/LuaTeX(+LuaTeX-ja) + - 依存パッケージ: bxtoolbox([BXbase] バンドル) + +[BXbase]: https://www.ctan.org/pkg/bxbase + +### インストール + +TDS 1.1 に準拠するシステムの場合、以下のようにファイルを移動する: + + - *.sty → $TEXMF/tex/latex/BXjaprnind + +この後必要に応じて mktexlsr を実行する。 + +### ライセンス + +本パッケージは MIT ライセンスの下で配布される。 + +bxjaprnind パッケージ ― 本体 +----------------------------- + +詳細は解説文書 bxjaprnind.pdf を参照。 + +更新履歴 +-------- + + * Version 0.3a 〈2013/05/05〉 + - 会話用の特別な鉤括弧の処理を追加した。 + * Version 0.3 〈2013/04/29〉 + - everyhook パッケージへの依存を無くした。 + * Version 0.2 〈2012/05/14〉 + +---------------------------------------- +Takayuki YATO (aka. "ZR") +http://zrbabbler.sp.land.to/ diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/README.md b/Master/texmf-dist/doc/latex/bxjaprnind/README.md new file mode 100644 index 00000000000..a57432112ea --- /dev/null +++ b/Master/texmf-dist/doc/latex/bxjaprnind/README.md @@ -0,0 +1,61 @@ +BXjaprnind Package +================== + +LaTeX: To adjust the position of parentheses at paragraph head + +In Japanese typesetting, opening parentheses placed at the beginning +of paragraphs or lines are treated specially; for example, while the +paragraph indent before normal kanji characters is 1em, the indent +before parentheses can be 0.5em, 1em or 1.5em deoending on the local +rule in effect. + +This package allows users to specify the amount of indent just before +Japanese parentheses placed at paragraph/line head. + +### System requirement + + * TeX format: LaTeX. + * TeX engine: pTeX / upTeX / LuaTeX (+ LuaTeX-ja). + (The support for XeTeX is currently broken.) + * Dependent packages: + - bxtoolbox (from [BXbase] bundle) + +[BXbase]: https://www.ctan.org/pkg/bxbase + +### Package content + + * `bxjaprnind.sty`: the package + * `bxjaprnind.pdf`: the user manual (in Japanese) + * `bxjaprnind.tex`: the source file of `bxjaprnind.pdf` + * `sample-bxjaprnind.pdf`: a sample document (in Japanese) + * `sample-bxjaprnind.tex`: the source file of `sample-bxjaprnind.pdf` + +### Installation + +In a system compliant to TDS 1.1, move the files as follows: + + - `*.sty` → $TEXMF/tex/latex/BXjaprnind + +And rehash your TEXMF trees if necessary. + +### License + +This package is distributed under the MIT License. + + +bxjaprnind package ― main +-------------------------- + +See the manual bxjaprnind.pdf (in Japanese) for detail. + + +Revision History +---------------- + + * Version 0.3a 〈2013/05/05〉 + * Version 0.3 〈2013/04/29〉 + * Version 0.2 〈2012/05/14〉 + +-------------------- +Takayuki YATO (aka. "ZR") +https://github.com/zr-tex8r diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.pdf b/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.pdf new file mode 100644 index 00000000000..294d7045f7d Binary files /dev/null and b/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.pdf differ diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.tex b/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.tex new file mode 100644 index 00000000000..79a0792e93a --- /dev/null +++ b/Master/texmf-dist/doc/latex/bxjaprnind/bxjaprnind.tex @@ -0,0 +1,118 @@ +% 文字コードは UTF-8 +% lualatex で組版する(LuaTeX-ja 使用) +\documentclass[a4paper]{ltjsarticle} +\usepackage[ipaex]{luatexja-preset} +\usepackage{metalogo} +\usepackage{shortvrb} +\MakeShortVerb{\|} +\newcommand{\PkgVersion}{0.3a} +\newcommand{\Pkg}[1]{\textsf{#1}} +\newcommand{\Meta}[1]{$\langle$\mbox{}#1\mbox{}$\rangle$} +\newcommand{\Note}{\par\noindent ※} +\newcommand{\Means}{~:\quad} +\providecommand{\pTeX}{p\TeX} +\providecommand{\upTeX}{u\pTeX} +%----------------------------------------------------------- +\begin{document} +\title{\Pkg{bxjaprnind} パッケージ(v\PkgVersion)} +\author{八登崇之\ (Takayuki YATO; aka.~``ZR'')} +\date{2013/05/05} +\maketitle + +%=========================================================== +\section{概要} + +以下の機能を提供する。 +\begin{itemize} +\item 段落冒頭および強制改行後の行頭における開き括弧の前に + (環境により)挿入されるグルーを除去する。 + このようなグルーが行分割の都合で伸縮すると、 + ソース上で同じ条件にある括弧の位置が揃わないという + 不都合が生じる。 +\item さらに、そのような開き括弧の前の字下げを、 + 著者が予め設定した量に自動的に調整する。 +\item 強制改行命令(|\\|)のオプションとして + 改行後に予め設定した量の字下げを行えるようにする。 +\end{itemize} + +\paragraph{対応フォーマット} \LaTeX。 + +\paragraph{対応エンジン} 次の何れか。 +\begin{itemize} +\item {\pTeX}またはその拡張。 +\item {\XeTeX}(\Pkg{ZXjatype}パッケージ使用時) +\item {\LuaTeX}(\Pkg{LuaTeX-ja}パッケージ使用時) +\end{itemize} + +\paragraph{依存パッケージ} 次の通り。 +\begin{itemize} +\item \Pkg{bxtoolbox} パッケージ(\Pkg{BXbase}バンドルに含まれる) +\item 0.3版以降は\Pkg{everyhook}パッケージに依存しなくなった。 +しかし、\Pkg{everyhook}パッケージが利用可能である場合はそれを利用する。 +\item \Pkg{everyhook}パッケージは\Pkg{svn-proc} パッケージに依存する。 +\end{itemize} + +%=========================================================== +\section{パッケージの読込} + +|\usepackage| で読み込む。 +オプションはない。 +\begin{verbatim} +\usepackage{bxjaprnind} +\end{verbatim} + +%=========================================================== +\section{機能} + +以下の命令が提供される。 + +\begin{itemize} +\item |\useparheadparenindent|/|\nouseparheadparenindent|\Means + 段落頭での開き括弧調整を有効/無効にする。 +\item |\uselineheadparenindent|/|\nouselineheadparenindent|\Means + 強制改行後の行頭での開き括弧調整を有効/無効にする。 + \Note 折り返しの行頭の調整には対応しない + (これにはJFMの修正が必須)。 + 現在(u){\pTeX}で標準的に用いられるJFMの場合、 + 折り返し行頭の開き括弧の前には空きは入らない。 +\item |\prnind[|\Meta{実数$r$}|]|\Means + 段落頭で用いて、当該の箇所での調整を + (|\nouseparheadparenindent| の状態でも)有効にする。 + オプションの引数が存在する場合は、 + 開き括弧の前の空きを$r$全角幅とする。 +\item |\\[|\Meta{引数}|]|/|\\*[|\Meta{引数}|]|\Means + 強制改行命令のオプション引数が次のように拡張される。 + \begin{itemize} + \item |\\[>]|\Means + 行頭に |\lineheadforceindentamount| で指定した幅の + 字下げを挿入する。 + \item |\\[!]|\Means + 開き括弧調整の有効・無効を逆転する。 + 元々の引数(改行調整の値)と併用する場合は、 + |!| や |>| を長さの値の前に記述する + (例えば |\\[>!2mm]|)。 + \end{itemize} +\item |\parheadparenindentamount{|\Meta{実数$r$}|}|\Means + 段落頭での開き括弧の前の追加の空きを$r$全角幅とする。 + 段落下げの空き(|\parindent|)はこれとは独立に入ることに注意。 +\item |\lineheadparenindentamount{|\Meta{実数$r$}|}|\Means + 強制改行後の行頭での開き括弧の前の追加の空きを$r$全角幅とする。 + (強制字下げ(|\\[>]|)の空きとは独立。) +\item |\lineheadforceindentamount{|\Meta{実数$r$}|}|\Means + 強制字下げ(|\\[>]|)の空きを$r$全角幅とする。 +\item |\usedialogueparenindent|/|\nousedialogueparenindent|\Means + 会話用の特別な開き括弧調整を有効/無効にする。 + 有効にすると鉤括弧「」『』について以下のように調整方法が変わる。 + \begin{itemize} + \item 空きの量を |\dialogueparenindentamount| で指定された値にする。 + \item 段落頭の場合は段落下げの空き(|\parindent|)を無効にする。 + \end{itemize} + \Note + 臨時に鉤括弧の扱いを通常の括弧と同じにしたい場合は、 + 当該の鉤括弧の前に |\prnind| を置けばよい。 +\item |\dialogueparenindentamount{|\Meta{実数$r$}|}|\Means + 段落頭・強制改行行頭での会話用の開き鉤括弧の前の追加の + 空きを$r$全角幅とする。 +\end{itemize} + +\end{document} diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.pdf b/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.pdf new file mode 100644 index 00000000000..57bf934eaca Binary files /dev/null and b/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.pdf differ diff --git a/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.tex b/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.tex new file mode 100644 index 00000000000..676ea2fd542 --- /dev/null +++ b/Master/texmf-dist/doc/latex/bxjaprnind/sample-bxjaprnind.tex @@ -0,0 +1,131 @@ +% upLaTeX文書; 文字コードはUTF-8 +\documentclass[a4paper,uplatex]{jsarticle} +\usepackage{bxjaprnind} +\newcommand{\Pkg}[1]{\textsf{#1}} +\begin{document} +\title{\Pkg{bxjaprnind}パッケージサンプル出力} +\author{八登崇之\ (Takayuki YATO; aka.~``ZR'')} +\date{2013/04/29} +\maketitle + +%------------------- +\section{段落頭の括弧類の空き自動補正} +\newcommand\SampleTextA{% +「□□□□?」\par +「□□□□□□□□、□□□□□□□□」\par +「□□□□□□□□!」\par +} + +\begin{itemize} +\item 左は自動補正を無効化(\verb|\nouseparheadparenindent|)。 +\item 右は自動補正を有効化(\verb|\useparheadparenindent|)。 +\end{itemize} +\begin{center} +% 既定は有効だが敢えて無効にする +\nouseparheadparenindent % 段落頭での補正を無効に +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextA +\end{minipage}}% +\hspace{4zw} +\useparheadparenindent % 段落頭での補正を有効に +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextA +\end{minipage}}% +\end{center} + +%------------------- +\section{段落頭の括弧類の空きの補正値の変更} +\newcommand\SampleTextB{% +「□□□□□□□、□□□□□□□□□□□□□□□」 +} + +\begin{itemize} +\item 左は既定(\verb|\parheadparenindentamount{0}|)。 +\item 右は半角下げに変更(\verb|\parheadparenindentamount{-0.5}|)。 +\item 段落下げ(\verb|\parindent|)が入った位置を基準にしている。 +\item 強制改行後の空白の調整は可能(\verb|\lineheadparenindentamount|) +だが折り返し行頭の空白の調整は{\pTeX}の仕様上困難である。 +\end{itemize} +\begin{center} +\parheadparenindentamount{0} % 全角下げ(既定値) +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextB +\end{minipage}}% +\hspace{4zw} +\parheadparenindentamount{-0.5} % 二分下げ +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextB +\end{minipage}}% +\end{center} + +%------------------- +\section{強制改行後の括弧類の空きの補正値の変更} +\newcommand\SampleTextC{% +「□□□□?」\\ +「□□□。□□!」\\ +「□□□□□□。□□□□□□□□□□□□□□」\\ +「□□□□□□□!」 +} + +\begin{itemize} +\item ソースでは各台詞の間に強制改行が入れられている。 +\item 左は既定の設定。 +\item 右は % +\verb|\parheadparenindentamount{-0.5}\lineheadparenindentamount{0.5}|。 +\item 鉤括弧以外の括弧にも効くのでグローバル設定には不適切であるが、 +この設定にする環境を作る等の方法が考えられる。 +\item やっぱり不便なので次節の機能を作った。 +\end{itemize} +\begin{center} +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextC +\end{minipage}}% +\hspace{4zw} +\parheadparenindentamount{-0.5}\lineheadparenindentamount{0.5} +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextC +\end{minipage}}% +\end{center} + +%------------------- +\section{会話の鉤括弧のための特別な処理} +\newcommand\SampleTextD{% +□□□、□□□□□□□□□。\par +「□□□□?」\\ +「□□□。□□!」\\ +「□□□□□□。□□□□□□□□□□□□□□」\\ +「□□□□□□□!」\par +(□□□)□□□□、□□□□□□。\par +} + +\begin{itemize} +\item ソースでは各台詞の間に強制改行が入れられている。 +(その前後は改段落している。) +\item 左は既定の設定。 +\item 右は \verb|\usedialogueparenindent|。 +\item 鉤括弧だけ \verb|\dialogueparenindentamount| で指定した字下げ量 +(既定は半角)になり、さらに段落下げが無効になる。 +鉤括弧以外の括弧の処理は通常通り。 +\item 鉤括弧を通常の括弧として扱いたい場合は、直前に \verb|\prnind| +を置けばよい。 +\end{itemize} +\begin{center} +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextD +\end{minipage}}% +\hspace{4zw} +\usedialogueparenindent +\fbox{\begin{minipage}{10zw} + \setlength{\parindent}{1zw} + \SampleTextD +\end{minipage}}% +\end{center} + +\end{document} diff --git a/Master/texmf-dist/tex/latex/bxjaprnind/bxjaprnind.sty b/Master/texmf-dist/tex/latex/bxjaprnind/bxjaprnind.sty new file mode 100644 index 00000000000..ac2b9028950 --- /dev/null +++ b/Master/texmf-dist/tex/latex/bxjaprnind/bxjaprnind.sty @@ -0,0 +1,359 @@ +% +% bxjaprnind.sty +% + +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{bxjaprnind}[2013/05/05 v0.3a] + +\def\bxpi@pkgname{bxjaprnind} +\def\bxpi@error{\PackageError\bxpi@pkgname} + +%% definitions +\newdimen\bxpi@dima + +%% code guards +\edef\bxpi@restore@codes{% +\catcode33=\the\catcode33% +\catcode34=\the\catcode34%<"> +\catcode62=\the\catcode62%<>> +\endlinechar=\the\endlinechar% +\relax}% +\catcode33=12 % +\catcode34=12 % +\catcode62=12 % +\AtEndOfPackage{% +\bxpi@restore@codes +\undef\bxpi@restore@codes} + +%------------------- setting the everypar hook + +\RequirePackage{bxtoolbox} + +%% Checks if everyhook package is available +\@tempswafalse +\ifbxineTeX + \IfFileExists{everyhook.sty}{% + \@tempswatrue + }{} +\fi + +\if@tempswa + % if everyhook is available... + \RequirePackage{everyhook}[2011/02/04] + + % register the hook + \PushPostHook{par}{\bxpi@par@hook} + +\else + % otherwise... + % makes a hook to \everypar for myself + \let\bxpi@everypar\everypar + \newtoks\everypar + \everypar\bxpi@everypar + \bxpi@everypar{\the\expandafter\everypar\bxpi@par@hook}% + +\fi +\endlinechar=-1 % +%------------------- setting the newline hook + +%% adds hooks to (subcommands of) \\ +\preto\@xnewline{\bxpi@init@param} +\let\bxpi@org@@newline\@newline +\def\@newline[#1]{ + \bxpi@parse@arg{#1} + \expandafter\bxpi@org@@newline\expandafter[\bxpi@res] +} +\begingroup + \toks@\expandafter{\@gnewline{#1}} + \edef\bxpi@next{ + \gdef\noexpand\@gnewline##1{ + \the\toks@ + \noexpand\bxpi@paren@indent + } + } + \bxpi@next +\endgroup + +%------------------- helpers + +%% \bxpi@inhibitglue +\ifdef\inhibitglue{ + \let\bxpi@inhibitglue\inhibitglue +}{%else + \let\bxpi@inhibitglue\relax + \bxpi@warn{ + \string\inhibitglue\space unavailable in current settings; + \MessageBreak the package may not work properly + } +} + +%------------------- main + +%% \def\bxpi@parhead +\def\bxpi@parhead{0} +%% \def\bxpi@linehead +\def\bxpi@linehead{0} +%% \def\bxpi@dialogue +\def\bxpi@dialogue{0.5} +%% \def\bxpi@lineheadforce +\def\bxpi@lineheadforce{1} +%% \ifbxpi@d@parprnind +\newbool{bxpi@d@parprnind}\bxpi@d@parprnindtrue +%% \ifbxpi@d@lineprnind +\newbool{bxpi@d@lineprnind}\bxpi@d@lineprnindtrue +%% \ifbxpi@diaprnind +\newbool{bxpi@diaprnind}\bxpi@diaprnindfalse +%% \ifbxpi@prnind +\newbool{bxpi@prnind} +%% \ifbxpi@forceind +\newbool{bxpi@forceind} +%% \bxpi@choice +\let\bxpi@choice\relax + +%%<*> \useparheadparenindent +\bxNewrobustcmd*{\useparheadparenindent}{ + \bxpi@d@parprnindtrue +} + +%%<*> \nouseparheadparenindent +\bxNewrobustcmd*{\nouseparheadparenindent}{ + \bxpi@d@parprnindfalse +} + +%%<*> \uselineheadparenindent +\bxNewrobustcmd*{\uselineheadparenindent}{ + \bxpi@d@lineprnindtrue +} + +%%<*> \nouselineheadparenindent +\bxNewrobustcmd*{\nouselineheadparenindent}{ + \bxpi@d@lineprnindfalse +} + +%%<*> \usedialogueparenindent +\bxNewrobustcmd*{\usedialogueparenindent}{ + \bxpi@diaprnindtrue +} + +%%<*> \nousedialogueparenindent +\bxNewrobustcmd*{\nousedialogueparenindent}{ + \bxpi@diaprnindfalse +} + +%%<*> \parheadparenindentamount +% Sets the value of \bxpi@parhead. +\bxNewrobustcmd*{\parheadparenindentamount}[1]{ + \edef\bxpi@parhead{#1} +} + +%<*> \lineheadparenindentamount +% Sets the value of \bxpi@linehead. +\bxNewrobustcmd*{\lineheadparenindentamount}[1]{ + \edef\bxpi@linehead{#1} +} + +%<*> \lineheadforceindentamount +% Sets the value of \bxpi@lineheadforce. +\bxNewrobustcmd*{\lineheadforceindentamount}[1]{ + \edef\bxpi@lineheadforce{#1} +} + +%%<*> \prnind +% +\bxNewrobustcmd*{\prnind}{ + \leavevmode\relax + \bxpi@prnindtrue + \bxpi@forceindfalse + \let\bxpi@choice=m + \kernel@ifnextchar[{ + \bxpi@prnind@a + }{%else + \let\bxpi@value\bxpi@parhead + \bxpi@paren@indent + } +} +\def\bxpi@prnind@a[#1]{ + \def\bxpi@value{#1} + \bxpi@paren@indent +} + +%% \bxpi@init@param +% Initializes the parameters. +% (Invoked at every \\.) +\def\bxpi@init@param{ + \bxpi@prnind@linedflt + \bxpi@forceindfalse + \let\bxpi@choice=l + \let\bxpi@value\bxpi@linehead +} + +%% \bxpi@parse@arg{} +% Parses the option argument of \\. It reads the prefix > and ! +% and sets the switches bxpi@forceind and bxpi@prnind, then +% sets the remaining string to \bxpi@res, which is passed to +% the original argument parser (\@newline). +\def\bxpi@parse@arg#1{% + \bxpi@parse@arg@a#1\bxpi@end +} +\def\bxpi@parse@arg@a{ + \futurelet\bxpi@tok\bxpi@parse@arg@b +} +\def\bxpi@parse@arg@b{ + \bxIfx{\bxpi@tok\bgroup}{ + \bxpi@parse@arg@c + }{%else + \bxpi@parse@arg@d + } +} +\def\bxpi@parse@arg@c#1\bxpi@end{ + \ifstrempty{#1}{ + \def\bxpi@res{\z@} + }{%else + \def\bxpi@res{#1} + } +} +\def\bxpi@parse@arg@d#1{% + \bxIfx{,#1}{ + \bxpi@parse@arg@a + }{\bxIfx{!#1}{ + \ifbxpi@prnind \bxpi@prnindfalse + \else \bxpi@prnindtrue + \fi + \bxpi@parse@arg@a + }{\bxIfx{>#1}{ + \bxpi@forceindtrue + \bxpi@parse@arg@a + }{ + \bxpi@parse@arg@c#1 + }}} +} + +%% \bxpi@par@hook +\def\bxpi@par@hook{ + \bxpi@prnind@pardflt + \bxpi@forceindfalse + \let\bxpi@choice=p + \let\bxpi@value\bxpi@parhead + \bxpi@paren@indent +} + +%% \bxpi@paren@indent +\def\bxpi@paren@indent{ + \bxpi@dima=-\maxdimen + \ifbxpi@forceind + \bxGetZenkakuWidth + \bxpi@dima=\bxResDim + % empty boxes never warn undefhull + \hb@xt@\bxpi@lineheadforce\bxpi@dima{} +\bxDebug{forceind:\bxpi@lineheadforce} + \fi + \ifbool{bxpi@prnind}{ + \futurelet\bxpi@tok\bxpi@prnindent@a + }{%else + \ignorespaces + } +} +\expandafter\def\expandafter\bxpi@prnindent@space\space{ + \futurelet\bxpi@tok\bxpi@prnindent@a +} +\def\bxpi@prnindent@a{ + \bxIf{\@sptoken\bxpi@tok}{ + \bxpi@prnindent@space + }{\bxIfCharToken\bxpi@tok{ + \bxpi@prnindent@b + }{%else + \ignorespaces + }} +} +\def\bxpi@prnindent@b#1{ + \bxpi@if@open@paren#1{ + \ifbxpi@diaprnind + \if m\bxpi@choice \else + \bxpi@if@dia@open@paren#1{ + \let\bxpi@value\bxpi@dialogue + \if p\bxpi@choice + {\setbox0=\lastbox} +\bxDebug{cancel parindent} + \fi + } + \fi + \fi + \bxpi@prnindent@c + } + #1 +} +\def\bxpi@prnindent@c{ + \ifdim \bxpi@dima<\z@ + \bxGetZenkakuWidth + \bxpi@dima=\bxResDim + \fi + \kern\bxpi@value\bxpi@dima +\bxDebug{parind:\bxpi@value} + \bxpi@inhibitglue +} + +%% \bxpi@if@open@paren +\def\bxpi@if@open@paren#1{ + \bxIfcsundef{bxpi@P/#1} + {\@gobble} + {\@firstofone} +} + +%% \bxpi@if@dia@open@paren +\def\bxpi@if@dia@open@paren#1{ + \bxIfcsundef{bxpi@DP/#1} + {\@gobble} + {\@firstofone} +} + +%% \bxpi@prnind@pardflt +\edef\bxpi@prnind@pardflt{ + \let\bxCsNoexpand{ifbxpi@prnind} + \bxCsNoexpand{ifbxpi@d@parprnind} +} +%% \bxpi@prnind@linedflt +\edef\bxpi@prnind@linedflt{ + \let\bxCsNoexpand{ifbxpi@prnind} + \bxCsNoexpand{ifbxpi@d@lineprnind} +} + +%------------------- character table + +%% \bxpi@P/ +\def\do#1#2{% + \bxToUcsCharDual{"#1}{"#2} + \cslet{bxpi@P/\bxRes}{t} +} +\do{2146}{2018} +\do{2148}{201C} +\do{214A}{FF08} +\do{214C}{3014} +\do{214E}{FF3B} +\do{2150}{FF5B} +\do{2152}{3008} +\do{2154}{300A} +\do{2156}{300C} +\do{2158}{300E} +\do{215A}{3010} +\ifbxHasUcsChar + \def\do#1{ + \bxToUcsChar{"#1} + \cslet{bxpi@P/\bxRes}{t} + } +\do{2985} +\do{3018} +\do{3016} +\do{00AB} +\do{301D} +\fi + +%% \bxpi@DP/ +\def\do#1#2{% + \bxToUcsCharDual{"#1}{"#2} + \cslet{bxpi@DP/\bxRes}{t} +} +\do{2156}{300C} +\do{2158}{300E} + +%------------------- all done +\endinput diff --git a/Master/tlpkg/bin/tlpkg-ctan-check b/Master/tlpkg/bin/tlpkg-ctan-check index cefb8063226..c5d1f335d98 100755 --- a/Master/tlpkg/bin/tlpkg-ctan-check +++ b/Master/tlpkg/bin/tlpkg-ctan-check @@ -124,7 +124,7 @@ my @TLP_working = qw( breakcites breakurl bredzenie breqn bropd brushscr bullcntr bundledoc burmese bussproofs bxbase bxcalc bxcjkjatype bxdpx-beamer bxdvidriver - bxpapersize bxpdfver bxeepic bxenclose + bxjaprnind bxpapersize bxpdfver bxeepic bxenclose bxjalipsum bxjscls bxnewfont bxorigcapt bytefield c90 c-pascal cabin cachepic caladea calcage calctab calculation calculator calligra calligra-type1 callouts calrsfs cals calxxxx-yyyy cancel diff --git a/Master/tlpkg/tlpsrc/bxjaprnind.tlpsrc b/Master/tlpkg/tlpsrc/bxjaprnind.tlpsrc new file mode 100644 index 00000000000..e69de29bb2d diff --git a/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc b/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc index b43ad67f1bd..65f579d942f 100644 --- a/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc +++ b/Master/tlpkg/tlpsrc/collection-langjapanese.tlpsrc @@ -8,6 +8,7 @@ depend babel-japanese depend bxbase depend bxcjkjatype depend bxjalipsum +depend bxjaprnind depend bxjscls depend bxorigcapt depend convbkmk -- cgit v1.2.3