Debian Codegraph @

texmf-dist/doc/latex/kksymbols/kksymbols-doc.tex

raw
1 \documentclass[luatex,fontsize=8pt,paper=b5,twoside]{jlreq}%
2 \usepackage{amsmath,amssymb}
3 \usepackage{booktabs,caption}
4 \usepackage{luwa-ul,KKluaverb}
5 \usepackage[most]{tcolorbox}
6 \usepackage{luatexja-ruby,lltjext}
7 \usepackage{KKsymbols}
8
9 % You can omit these font settings.
10 \makeatletter
11 \RequirePackage[no-math]{fontspec}
12 \RequirePackage[no-math,match,scale=1]{luatexja-fontspec}
13 \RequirePackage[hiragino-pro,deluxe,expert]{luatexja-preset}
14 \setmainfont{HiraMinPro-W3}[BoldFont=HiraMinPro-W6]
15 \setmainjfont{HiraMinPro-W3}[BoldFont=HiraMinPro-W6]
16 \newfontfamily{\sfhira@pre}{HiraKakuPro-W3}[BoldFont=HiraKakuPro-W6]
17 \newjfontfamily{\sfhiraj@pre}{HiraKakuPro-W3}[BoldFont=HiraKakuPro-W6]
18 \newfontfamily{\mchira@pre}{HiraMinPro-W3}[BoldFont=HiraMinPro-W6]
19 \newjfontfamily{\mchiraj@pre}{HiraMinPro-W3}[BoldFont=HiraMinPro-W6]
20 \newfontfamily{\gthira@pre}{HiraKakuPro-W3}[BoldFont=HiraKakuPro-W6,FontFace={eb}{\shapedefault}{HiraKakuStd-W8}]
21 \newjfontfamily{\gthiraj@pre}{HiraKakuPro-W3}[BoldFont=HiraKakuPro-W6,FontFace={eb}{\shapedefault}{HiraKakuStd-W8}]
22 \newfontfamily{\mghira@pre}{HiraMaruPro-W4}
23 \newjfontfamily{\mghiraj@pre}{HiraMaruPro-W4}
24 \renewcommand{\sffamily}{\sfhira@pre\sfhiraj@pre}
25 \renewcommand{\mcfamily}{\mchira@pre\mchiraj@pre}
26 \renewcommand{\gtfamily}{\gthira@pre\gthiraj@pre}
27 \renewcommand{\mgfamily}{\mghira@pre\mghiraj@pre}
28 \makeatother
29 %%%
30
31
32 \usepackage{hyperref}
33 \hypersetup{
34 luatex, pdfencoding=auto,
35 colorlinks=true,
36 linkcolor=black,
37 citecolor=black,
38 urlcolor=DeepSkyBlue3,
39 pdfborder={0 0 0},
40 }
41
42 \colorlet{grayLight}{white!80!black}
43
44 \NewTCBListing{SourceCode}{ m m !o !O{DeepSkyBlue3} }{%
45 enhanced, colback=black!70, colframe=Snow4,
46 toptitle=-1mm, bottomtitle=-1mm,
47 righttitle=-1mm, lefttitle=-1mm,
48 arc=.5mm,
49 title={\tcbox[on line, arc=.5mm, boxsep=0pt, boxrule=0pt, top=1mm, bottom=0.8mm, left=2mm, right=2.2mm, colback=gray!80, coltext=white]{\raisebox{-0.1ex}{\vphantom{羅}\vphantom{j}#1}}},fonttitle=\gtfamily\footnotesize,boxrule=0.8pt,
50 breakable,before upper={\color{white}},top=-0.5mm,bottom=-0.5mm,
51 after title=\IfNoValueTF{#3}{}{{\hfill\tcbox[on line, arc=.5mm, boxsep=0pt, boxrule=0pt, top=1mm, bottom=0.8mm, left=2mm, right=2.2mm, colback=white!80!black, coltext=#4]{\raisebox{-0.1ex}{\vphantom{羅}\vphantom{j}#3}}}},
52 listing only,
53 listing options={
54 language={#2},
55 basicstyle=\ttfamily,
56 keywordstyle=\ttfamily\color{white},
57 stringstyle=\itshape\color{white},
58 commentstyle=\small\gtfamily\color{DeepSkyBlue2},
59 showspaces=false,showtabs=false,
60 breaklines=true,breakindent=0pt,
61 showstringspaces=false,
62 columns=fullflexible,
63 tabsize=2,
64 numbers=left,numbersep=1.5pt,
65 numberstyle=\scriptsize\gtfamily\color{gray},
66 }
67 }
68
69 \NewTColorBox{OutPut}{ m !o !O{DeepSkyBlue3} }{%
70 enhanced, colframe=Snow4,
71 toptitle=-1mm, bottomtitle=-1mm,
72 righttitle=-1mm, lefttitle=-1mm,
73 arc=.5mm, colback=white,
74 title={\tcbox[on line, arc=.5mm, boxsep=0pt, boxrule=0pt, top=1mm, bottom=0.8mm, left=2mm, right=2.2mm, colback=gray!40, coltext=DeepSkyBlue3]{\raisebox{-0.1ex}{\vphantom{羅}\vphantom{j}#1}}},fonttitle=\gtfamily\footnotesize,boxrule=0.8pt,
75 breakable,top=-0.5mm,bottom=-0.5mm,
76 after title=\IfNoValueTF{#2}{}{{\hfill\tcbox[on line, arc=.5mm, boxsep=0pt, boxrule=0pt, top=1mm, bottom=0.8mm, left=2mm, right=2.2mm, colback=white!80!black, coltext=#3]{\raisebox{-0.1ex}{\vphantom{羅}\vphantom{j}#2}}}}, bottom=2mm, top=2mm,
77 }
78
79 \title{\texttt{KKsymbols} Package Documentation}
80 \author{Kosei Kawaguchi a.k.a. KKTeX}
81 \date{Version 2.1.4 (2026/04/17)}
82 \begin{document}
83
84 \begin{titlepage}
85 \maketitle
86 \end{titlepage}
87 \newpage
88 \tableofcontents
89 \newpage
90
91 \section{Outline}
92 Japanese: このパッケージは、既存のotfフォントに頼ることなく、「任意のフォント、任意の引数で」丸数字などの特殊記号を再現する目的で作成されています。
93
94 luatexja-otfにおける\verb|\ajMaru|などは、その設計上いたしかなないデメリットとして、早見表がないと使い物にならないというものがありました。しかし、本パッケージでは、一から特殊文字を設計し直すというという取り組みを行なっているため、そのようなデメリットが解消されています。
95
96 English: This package is designed to reproduce special characters, such as circled numbers, using arbitrary fonts and parameters without relying on existing otf font sets.
97
98 A known disadvantage of commands like \verb|\ajMaru| in luatexja-otf is that they are practically unusable without a reference chart. In contrast, this package addresses this issue by re-engineering special characters from the ground up, eliminating the need for complex lookup tables.
99
100 {%
101 \fboxsep=0pt\fboxrule=.1pt
102 \makebox[10\zw][s]{ああ\kakko{あ}ああ}
103
104
105 \directlua{
106 for i = 1, 26 do
107 local char = i
108 tex.print("\\fbox{\\maru{" .. char .. "}}")
109 end
110 }
111
112
113 \directlua{
114 for i = string.byte("a"), string.byte("z") do
115 local char = string.char(i)
116 tex.print("\\fbox{\\maru*{" .. char .. "}}")
117 end
118 }
119
120
121 \directlua{
122 for i = string.byte("A"), string.byte("Z") do
123 local char = string.char(i)
124 tex.print("\\fbox{\\maru{" .. char .. "}}")
125 end
126 }
127
128 \directlua{
129 for i = 1, 26 do
130 local char = i
131 tex.print("\\fbox{\\jegg{" .. char .. "}}")
132 end
133 }
134
135
136 \directlua{
137 for i = string.byte("a"), string.byte("z") do
138 local char = string.char(i)
139 tex.print("\\fbox{\\jegg{" .. char .. "}}")
140 end
141 }
142
143 \directlua{
144 for i = string.byte("a"), string.byte("z") do
145 local char = string.char(i)
146 tex.print("\\fbox{\\jegg*{" .. char .. "}}")
147 end
148 }
149
150
151 \directlua{
152 for i = string.byte("a"), string.byte("z") do
153 local char = string.char(i)
154 tex.print("\\fbox{\\kuromaru*{" .. char .. "}}")
155 end
156 }
157
158
159 \directlua{
160 for i = string.byte("A"), string.byte("Z") do
161 local char = string.char(i)
162 tex.print("\\fbox{\\kuromaru{" .. char .. "}}")
163 end
164 }
165
166 \directlua{
167 for i = string.byte("a"), string.byte("z") do
168 local char = string.char(i)
169 tex.print("\\fbox{\\nmaru*{" .. char .. "}}")
170 end
171 }
172
173
174 \directlua{
175 for i = string.byte("A"), string.byte("Z") do
176 local char = string.char(i)
177 tex.print("\\fbox{\\nmaru{" .. char .. "}}")
178 end
179 }
180
181
182 \directlua{
183 for i = string.byte("a"), string.byte("z") do
184 local char = string.char(i)
185 tex.print("\\fbox{\\hishi*{" .. char .. "}}")
186 end
187 }
188
189
190 \directlua{
191 for i = string.byte("A"), string.byte("Z") do
192 local char = string.char(i)
193 tex.print("\\fbox{\\hishi{" .. char .. "}}")
194 end
195 }
196
197
198 \directlua{
199 for i = string.byte("a"), string.byte("z") do
200 local char = string.char(i)
201 tex.print("\\fbox{\\kurohishi*{" .. char .. "}}")
202 end
203 }
204
205
206 \directlua{
207 for i = string.byte("A"), string.byte("Z") do
208 local char = string.char(i)
209 tex.print("\\fbox{\\kurohishi{" .. char .. "}}")
210 end
211 }
212
213
214 \directlua{
215 for i = string.byte("a"), string.byte("z") do
216 local char = string.char(i)
217 tex.print("\\fbox{\\maruhishi*{" .. char .. "}}")
218 end
219 }
220
221
222 \directlua{
223 for i = string.byte("A"), string.byte("Z") do
224 local char = string.char(i)
225 tex.print("\\fbox{\\maruhishi{" .. char .. "}}")
226 end
227 }
228
229
230 \directlua{
231 for i = string.byte("a"), string.byte("z") do
232 local char = string.char(i)
233 tex.print("\\fbox{\\kuromaruhishi*{" .. char .. "}}")
234 end
235 }
236
237
238 \directlua{
239 for i = string.byte("A"), string.byte("Z") do
240 local char = string.char(i)
241 tex.print("\\fbox{\\kuromaruhishi{" .. char .. "}}")
242 end
243 }
244
245
246 \directlua{
247 for i = string.byte("a"), string.byte("z") do
248 local char = string.char(i)
249 tex.print("\\fbox{\\seihou*{" .. char .. "}}")
250 end
251 }
252
253
254 \directlua{
255 for i = string.byte("A"), string.byte("Z") do
256 local char = string.char(i)
257 tex.print("\\fbox{\\seihou{" .. char .. "}}")
258 end
259 }
260
261
262 \directlua{
263 for i = string.byte("a"), string.byte("z") do
264 local char = string.char(i)
265 tex.print("\\fbox{\\kuroseihou*{" .. char .. "}}")
266 end
267 }
268
269
270 \directlua{
271 for i = string.byte("A"), string.byte("Z") do
272 local char = string.char(i)
273 tex.print("\\fbox{\\kuroseihou{" .. char .. "}}")
274 end
275 }
276
277
278 \directlua{
279 for i = string.byte("a"), string.byte("z") do
280 local char = string.char(i)
281 tex.print("\\fbox{\\seimaru*{" .. char .. "}}")
282 end
283 }
284
285
286 \directlua{
287 for i = string.byte("A"), string.byte("Z") do
288 local char = string.char(i)
289 tex.print("\\fbox{\\seimaru{" .. char .. "}}")
290 end
291 }
292
293
294 \directlua{
295 for i = string.byte("a"), string.byte("z") do
296 local char = string.char(i)
297 tex.print("\\fbox{\\kuroseimaru*{" .. char .. "}}")
298 end
299 }
300
301
302 \directlua{
303 for i = string.byte("A"), string.byte("Z") do
304 local char = string.char(i)
305 tex.print("\\fbox{\\kuroseimaru{" .. char .. "}}")
306 end
307 }
308
309
310 \directlua{
311 for i = 1,26 do
312 local char = i
313 tex.print("\\fbox{\\kakko{" .. char .. "}}")
314 end
315 }
316
317
318 \directlua{
319 for i = string.byte("a"), string.byte("z") do
320 local char = string.char(i)
321 tex.print("\\fbox{\\kakko*{" .. char .. "}}")
322 end
323 }
324
325
326 \directlua{
327 for i = string.byte("A"), string.byte("Z") do
328 local char = string.char(i)
329 tex.print("\\fbox{\\kakko{" .. char .. "}}")
330 end
331 }%
332 }
333
334
335 \section{Acknowledgements / Credit}
336 In developing this package, I made extensive use of the advice I received from Mr.~Yusuke~Terada.
337
338 I recommend you to refer to his article when you develop new-type symbols on \LaTeX.
339
340 \begin{quotation}
341 \url{https://doratex.hatenablog.jp/entry/20211205/1638697391}
342 \end{quotation}
343
344 \section{Installation}
345 Place \texttt{KKsymbols.sty} in a directory where LaTeX can find it, e.g., your local \texttt{texmf} tree or alongside your document.
346
347 \subsection{Dependencies}
348 This package depends on the following packages.
349
350 \begin{itemize}
351 \item \texttt{LuaLaTeX-ja}
352 \item \texttt{tikz}
353 \item \texttt{clac}
354 \item \texttt{luacode}
355 \item \texttt{kvoptions}
356 \end{itemize}
357
358 \subsection{Loading and Options}
359 Load the package: \KKverb|\usepackage[<options>]{KKsymbols}|
360
361 Currently, the following package option is provided.
362
363 \begin{description}
364 \item[tsumesuji] To specify whether or not to ``shrink'' the box width occupied by ``1''. By default, \KKverb|tsumesuji=1| is specified, and the effect is activated. If you deactivate it, \KKverb|tsumesuji=0| will do.
365
366 To clarify, this option is applied when the argument of a command subject to the \KKverb|tsumesuji| option—after expansion—is a numeric string of two or more digits and contains the digit ``1''. The differnce is present in the following example:
367 \begin{SourceCode}{Input}{TeX}
368 % NOT APPLIED
369 \kakko{\vphantom{X}12}
370
371 % APLIED
372 \kakko{12}
373 \end{SourceCode}
374 \begin{OutPut}{Output}
375 % NOT APPLIED
376 \kakko{\vphantom{X}12}
377
378 % APLIED
379 \kakko{12}
380 \end{OutPut}
381 \end{description}
382
383 \section{Caution}
384 \namiKK{Since this package internally calls \KKverb|\ltjghostbeforejachar| and \KKverb|\ltjghostafterjachar|, it can be used \textbf{only in a LuaLaTeX environment.}}
385
386 \section{Commands}
387 \subsection{The maru series}
388 This package provides \verb|\maru|, \verb|\kuromaru|, and \verb|\nmaru|. Each of them takes one mandatory argument and no optional arguments. You can pass strings of any length and in any font as arguments.
389
390 In most cases, \verb|\maru{argument}| will meet your demands. However, only when you take lowercase alphabet in these commands, you must use star-command just like \verb|\maru*{m}|\footnote{\KKverb|\jegg| is an exception of this rule. When you use \KKverb|\jegg|, you don't have to put the star option no matter the argument is lowercase or not. If you do it, the background color of the \KKverb|\jegg| changes into gray. Only in this case, the effect of the option is different.}.
391
392 \begin{SourceCode}{Input}{TeX}[Mind the star option!]
393 % Normal Characters
394 \maru{A}\maru{あ}\maru{QED.}
395
396 % Lowercase Alphabetic Characters
397 \maru*{a}\maru*{j}\maru*{z}
398 \end{SourceCode}
399
400 \begin{OutPut}{Output}
401 % Normal Characters
402 \maru{A}\maru{あ}\maru{QED.}
403
404 % Lowercase Alphabetic Characters
405 \maru*{a}\maru*{j}\maru*{z}
406 \end{OutPut}
407
408 They are used as follows.
409
410 \begin{table}[h]
411 \centering
412 \caption{maru series}
413 \begin{tabular}{|c|c|c|c|c|c|}
414 \hline
415 argument & \texttt{\textbackslash maru} & \texttt{\textbackslash kuromaru} & \texttt{\textbackslash nmaru} & \texttt{\textbackslash jegg} & \texttt{\textbackslash jegg*} \\
416 \hline
417 1 & \maru{1} & \kuromaru{1} & \nmaru{1} & \jegg{1} & \jegg*{1} \\
418 97 & \maru{97} & \kuromaru{97} & \nmaru{97} & \jegg{97} & \jegg*{97} \\
419 だ & \maru{だ} & \kuromaru{だ} & \nmaru{だ} & \jegg{だ} & \jegg*{だ} \\
420 ばばば & \maru{ばばば} & \kuromaru{ばばば} & \nmaru{ばばば} & \jegg{ばばば} & \jegg*{ばばば} \\
421 m & \maru*{m} & \kuromaru*{m} & \nmaru*{m} & \jegg{m} & \jegg*{m} \\
422 Qjg & \maru{Qjg} & \kuromaru{Qjg} & \nmaru{Qjg} & \jegg{Qjg} & \jegg*{Qjg} \\
423 \hline
424 \end{tabular}
425 \end{table}
426
427 They behave as if they were single kanji or hiragana characters:
428
429 \fboxsep=0pt\fboxrule=0.1pt
430 \begin{quotation}
431 あいう\fbox{\maru{あ}}\fbox{あ}いう\maru{1}\maru{2}\maru{3}あいうえお
432 \end{quotation}
433
434 The spacing between \verb|\maru| and other characters is adjusted using \verb|\ltjghostbeforejachar| and \verb|\ltjghostafterjachar| so that it behaves like hiragana or kanji.
435
436 When changing the font size using commands such as \verb|\Large|, each command is scaled proportionally according to the font size change:
437
438 \begin{quotation}
439 {\tiny \maru{あああ}\kuromaru{2222}\nmaru{亀}}
440
441 {\normalsize \maru{あああ}\kuromaru{2222}\nmaru{亀}}
442
443 {\Huge \maru{あああ}\kuromaru{2222}\nmaru{亀}}
444 \end{quotation}
445
446 You can also change the current font:
447 \begin{quotation}
448 {\LARGE\maru{あいう}\kuromaru{午後}\nmaru{悟}}%
449
450 {\gtfamily \maru{あいう}\kuromaru{午後}\nmaru{悟}}
451 \end{quotation}
452
453
454 \section{Rotation}
455 \subsection{Commands}
456 This package provides \verb|\RotTate| and \verb|\RotYoko|. The differnces are as follows:
457
458 \begin{description}
459 \item[In horizontal mode] You should use \verb|\RotYoko|. The default value is \verb|0|. Therefore, if you use \verb|\RotYoko| with no arguments, this is equal to \verb|\RotYoko[0]|
460 \item[In vertical mode] You should use \verb|\RotTate|. The default value is \verb|90|. Therefore, if you use \verb|\RotTate| with no arguments, this is equal to \verb|\RotTate[90]|
461 \end{description}
462
463 From a technical perspective: Commands like \verb|\maru| provided by this package automatically rotate their arguments based on the ``current typesetting direction'' Specifically, the package applies a 0-degree rotation for horizontal writing (yoko-gaki) and a 90-degree rotation for vertical writing (tate-gaki).
464
465 The commands \verb|\RotYoko| and \verb|\RotTate| redefine this "automatic rotation angle" to the value specified in their arguments. Consequently, the effect is persistent unless localized (similar to how font-size commands like \verb|\small| behave). Therefore, please ensure you use appropriate scoping, such as enclosing the command within curly braces \verb|{...}|, when applying these settings.
466
467 \begin{SourceCode}{Input}{TeX}
468 % In horizontal mode
469 {\RotYoko[45]\kakko{あ}\kakko{い}\kakko{う}}\par
470 {\RotYoko[60]\kakko{1}\kakko{2}\kakko{3}}
471
472 % In vertical mode
473 \parbox<t>{5\zw}{% <t> option requires lltjext package.
474 {\RotTate[45]\kakko{あ}\kakko{い}\kakko{う}}\par
475 {\RotTate[60]\kakko{1}\kakko{2}\kakko{3}}
476 }
477 \end{SourceCode}
478
479 \begin{OutPut}{Output}
480 {\RotYoko[45]\kakko{あ}\kakko{い}\kakko{う}}\par
481 {\RotYoko[60]\kakko{1}\kakko{2}\kakko{3}}
482
483 \bigskip
484
485 \parbox<t>{5\zw}{% <t> option requires lltjext package.
486 {\RotTate[45]\kakko{あ}\kakko{い}\kakko{う}}\par
487 {\RotTate[60]\kakko{1}\kakko{2}\kakko{3}}
488 }
489 \end{OutPut}
490
491 \subsection{Vertical mode}
492 When you want to typeset \maru{あ}, for instance, in vertical mode, you should use \verb|\RotTate| command.
493
494 As described in the previous subsection, the effect of \verb|\RotTate| lasts, when localized, in a certain group. So when you typeset hiragana or kanji, use it like this:
495
496 \begin{SourceCode}{Input}{TeX}
497 % In vertical mode
498 \parbox<t>{5\zw}{%
499 {\RotTate[0]\kakko{あ}\kakko{い}\kakko{う}}\par
500 \kakko{1}\kakko{1}\kakko{3}
501 }
502 \end{SourceCode}
503
504 \begin{OutPut}{Output}
505 \parbox<t>{5\zw}{%
506 {\RotTate[0]\kakko{あ}\kakko{い}\kakko{う}}\par
507 \kakko{1}\kakko{1}\kakko{3}
508 }
509 \end{OutPut}
510
511 \section{The seihou series}
512 The commands introduced below are used in exactly the same way as the maru series.
513 In most cases, \verb|\seihou{argument}| will meet your demands. However, only when you take lowercase alphabet in these commands, you must use star-command just like \verb|\seihou*{m}|.
514
515 \bigskip{%
516 \centering
517 \captionof{table}{seihou series}
518 \begin{tabular}{|c|c|c|c|c|}
519 \hline
520 argument & \texttt{\textbackslash seihou} & \texttt{\textbackslash kuroseihou} & \texttt{\textbackslash seimaru} & \texttt{\textbackslash kuroseimaru} \\
521 \hline
522 1 & \seihou{1} & \kuroseihou{1} & \seimaru{1} & \kuroseimaru{1} \\
523 97 & \seihou{97} & \kuroseihou{97} & \seimaru{97} & \kuroseimaru{97} \\
524 だ & \seihou{だ} & \kuroseihou{だ} & \seimaru{だ} & \kuroseimaru{だ} \\
525 ばばば & \seihou{ばばば} & \kuroseihou{ばばば} & \seimaru{ばばば} & \kuroseimaru{ばばば} \\
526 m & \seihou*{m} & \kuroseihou*{m} & \seimaru*{m} & \kuroseimaru*{m} \\
527 Qjg & \seihou{Qjg} & \kuroseihou{Qjg} & \seimaru{Qjg} & \kuroseimaru{Qjg} \\
528 \hline
529 \end{tabular}
530 }\bigskip
531
532 {%
533 \centering
534 \captionof{table}{hishi series}
535 \begin{tabular}{|c|c|c|c|c|}
536 \hline
537 argument & \texttt{\textbackslash hishi} & \texttt{\textbackslash kurohishi} & \texttt{\textbackslash maruhishi} & \texttt{\textbackslash kuromaruhishi} \\
538 \hline
539 1 & \hishi{1} & \kurohishi{1} & \maruhishi{1} & \kuromaruhishi{1} \\
540 97 & \hishi{97} & \kurohishi{97} & \maruhishi{97} & \kuromaruhishi{97} \\
541 だ & \hishi{だ} & \kurohishi{だ} & \maruhishi{だ} & \kuromaruhishi{だ} \\
542 ばばば & \hishi{ばばば} & \kurohishi{ばばば} & \maruhishi{ばばば} & \kuromaruhishi{ばばば} \\
543 m & \hishi*{m} & \kurohishi*{m} & \maruhishi*{m} & \kuromaruhishi*{m} \\
544 Qjg & \hishi{Qjg} & \kurohishi{Qjg} & \maruhishi{Qjg} & \kuromaruhishi{Qjg} \\
545 \hline
546 \end{tabular}
547 }\bigskip
548
549
550 \begin{SourceCode}{Input}{TeX}[Mind the star option!]
551 % Normal Characters
552 \seihou{A}\seihou{あ}\seihou{QED.}
553
554 % Lowercase Alphabetic Characters
555 \seihou*{a}\seihou*{j}\seihou*{z}
556 \end{SourceCode}
557
558 \begin{OutPut}{Output}
559 % Normal Characters
560 \seihou{A}\seihou{あ}\seihou{QED.}
561
562 % Lowercase Alphabetic Characters
563 \seihou*{a}\seihou*{j}\seihou*{z}
564 \end{OutPut}
565
566
567 \section{The kakko series}
568 The commands introduced below are used in exactly the same way as the maru series.
569
570 In most cases, \verb|\kakko{argument}| will meet your demands. However, only when you take lowercase alphabet in these commands, you must use star-command just like \verb|\kakko*{m}|\footnote{\KKverb|\zenkakuhabafixer| is an exception of this rule. It does not take a star option.}.
571
572 \bigskip{%
573 \centering
574 \captionof{table}{kakko series\maru{1}}
575 \begin{tabular}{|c|c|c|c|c|c|}
576 \hline
577 argument & \texttt{\textbackslash kakko} & \texttt{\textbackslash sumikakko} & \texttt{\textbackslash kakukakko} & \texttt{\textbackslash kikakko} & \texttt{\textbackslash ykakko} \\
578 \hline
579 1 & \kakko{1} & \sumikakko{1} & \kakukakko{1} & \kikakko{1} & \ykakko{1} \\
580 97 & \kakko{97} & \sumikakko{97} & \kakukakko{97} & \kikakko{97} & \ykakko{97} \\
581 だ & \kakko{だ} & \sumikakko{だ} & \kakukakko{だ} & \kikakko{だ} & \ykakko{だ} \\
582 ばばば & \kakko{ばばば} & \sumikakko{ばばば} & \kakukakko{ばばば} & \kikakko{ばばば} & \ykakko{ばばば} \\
583 m & \kakko*{m} & \sumikakko*{m} & \kakukakko*{m} & \kikakko*{m} & \ykakko*{m} \\
584 Qjg & \kakko{Qjg} & \sumikakko{Qjg} & \kakukakko{Qjg} & \kikakko{Qjg} & \ykakko{Qjg} \\
585 \hline
586 \end{tabular}
587 }
588
589 \bigskip{%
590 \centering
591 \captionof{table}{kakko series\maru{2}}
592 \begin{tabular}{|c|c|c|c|c|c|c|}
593 \hline
594 argument & \texttt{\textbackslash nykakko} & \texttt{\textbackslash namikakko} & \texttt{\textbackslash kagikakko} & \texttt{\textbackslash nkagikakko} & \texttt{\textbackslash ichimoji} & \texttt{\textbackslash zenkakuhabafixer}\\
595 \hline
596 1 & \nykakko{1} & \namikakko{1} & \kagikakko{1} & \nkagikakko{1} & \ichimoji{1} & \zenkakuhabafixer{1} \\
597 97 & \nykakko{97} & \namikakko{97} & \kagikakko{97} & \nkagikakko{97} & \ichimoji{97} & \zenkakuhabafixer{97} \\
598 だ & \nykakko{だ} & \namikakko{だ} & \kagikakko{だ} & \nkagikakko{だ} & \ichimoji{だ} & \zenkakuhabafixer{だ} \\
599 ばばば & \nykakko{ばばば} & \namikakko{ばばば} & \kagikakko{ばばば} & \nkagikakko{ばばば} & \ichimoji{ばばば} & \zenkakuhabafixer{ばばば} \\
600 m & \nykakko*{m} & \namikakko*{m} & \kagikakko*{m} & \nkagikakko*{m} & \ichimoji*{m} & \zenkakuhabafixer{m} \\
601 Qjg & \nykakko{Qjg} & \namikakko{Qjg} & \kagikakko{Qjg} & \nkagikakko{Qjg} & \ichimoji{Qjg} & \zenkakuhabafixer{Qjg} \\
602 \hline
603 \end{tabular}
604 }\bigskip
605
606 \begin{SourceCode}{Input}{TeX}[Mind the star option!]
607 % Normal Characters
608 \kakko{A}\kakko{あ}\kakko{QED.}
609
610 % Lowercase Alphabetic Characters
611 \kakko*{a}\kakko*{j}\kakko*{z}
612 \end{SourceCode}
613
614 \begin{OutPut}{Output}
615 % Normal Characters
616 \kakko{A}\kakko{あ}\kakko{QED.}
617
618 % Lowercase Alphabetic Characters
619 \kakko*{a}\kakko*{j}\kakko*{z}
620 \end{OutPut}
621
622 \subsection{Additional Description: \KKverb|\ichimoji| and \KKverb|\zenkakuhabafixer|}
623 The major differnce of \verb|\ichimoji| and \verb|\zenkakuhabafixer| is that the former changes the vertical scale to force its totalheight to \verb|\zw|, but the latter doesn't. You can see the differnce as follows:
624
625 \begin{description}
626 \item[\KKverb|\ichimoji|] \fbox{\ichimoji{123}}
627 \item[\KKverb|\zenkakuhabafixer|] \fbox{\zenkakuhabafixer{123}}
628 \end{description}
629
630 \section{License}
631
632 Released under the MIT License.
633
634 \section{Version History}
635
636 \begin{itemize}
637 \item \textbf{v1.0.0 (2025/10/03)} --- Initial public release.
638 \item \textbf{v1.0.1--1.0.4} --- Added \verb|\ichimoji|; fixed various bugs.
639 \item \textbf{v1.1.0 (2025/10/28)} --- Unified all commands to \textit{zenkaku} (full-width).
640 \item \textbf{v1.1.1 (2025/11/10)} --- Refined \verb|\ichimoji| scaling logic.
641 \item \textbf{v2.0.0 (2025/12/23)} --- Overhauled scaling to match OTF character quality.
642 \item \textbf{v2.0.1 (2026/01/08)} --- With the update to luatexja version 20260107.0, the commands provided by the KKsymbols package now behave identically to native Japanese characters. This improvement is due to the bug fixes in \verb|\ltjghostbeforejachar| and \verb|\ltjghostafterjachar|. Previously, when multiple commands from this package were used consecutively, proper glue was not inserted between them; however, this issue has been resolved in this update.
643 \item \textbf{v2.0.2 (2026/01/20)} --- This update fixes a critical bug where arguments of the \verb|\kakko| command could overflow when using specific fonts (for example, Hiragino fonts with weights W4 and above).
644 \item \textbf{v2.1.0 (2026/02/16)} --- In this update, the following points are changed.
645 \begin{itemize}
646 \item \verb|\period| command was deleted. It have never been used since the significance of existence had been absolutely questionable. I finally decided to delete it.
647 \item New package option \verb|tsumesuji| was added.
648 \item New command \verb|\zenkakuhabafixer| was added.
649 \end{itemize}
650 \item \textbf{v2.1.1 (2026/02/17)} --- An emergency update to fix a bug where the arguments of \KKverb|\kakko|, \KKverb|\maru| etc. caused expansion errors.
651 \item \textbf{v2.1.2 (2026/02/19)} --- The effects are applied when the argument of a command subject to the \KKverb|tsumesuji| option—after expansion—is a numeric string of two or more digits and contains the digit ``1''.
652 \item \textbf{v2.1.4 (2026/04/17)} --- When the arguments provided by this package contain only one-digit-number, the internal resize algorithm is nullified.
653 \end{itemize}
654
655 \end{document}