summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/platexcheat/platexsheet.tex
blob: 6b54ae8ced98f640243f416a2ee7ed459481810c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
\documentclass[10pt,a4paper,landscape,dvipdfmx]{jarticle}

% 使用パッケージ
\usepackage[small]{titlesec}
\usepackage[final]{plistings}
\usepackage{geometry}
\usepackage{graphicx}
\usepackage{multicol}
\usepackage{shortvrb}
\usepackage{siunitx}
\usepackage{xcolor}
\usepackage{otf}
\usepackage{url}

% ドキュメント設定
%% ページ
\geometry{top=1cm, left=1cm, right=1cm, bottom=1cm}
\pagestyle{empty}

%% 見出し
\setcounter{secnumdepth}{0}
\titlespacing{\section}{0pt}{5pt}{0pt}
\titlespacing{\subsection}{0pt}{0pt}{0pt}
\titlespacing{\subsubsection}{0pt}{0pt}{0pt}
\makeatletter
\protected@xdef\ttl@fonts{%
  \ttl@fonts\protect\sffamily\protect\gtfamily\protect\mdseries}
\makeatother

%% 寸法
\setlength{\parindent}{0pt}
\setlength{\parskip}{0pt plus 4.5pt}

%% コード
\MakeShortVerb{\|}
\lstset{
  language={[LaTeX]TeX},
  basicstyle={\scriptsize\ttfamily\gtfamily},
  commentstyle={\scriptsize\textcolor{gray}},
  keywordstyle={\scriptsize\ttfamily\bfseries},
  columns=[l]{fullflexible}}

% マクロ定義
\makeatletter

%% 列挙用テーブル
\def\set@etsep#1#2{\def\etcolsep{#1}\def\etitemsep{#2}}
\newenvironment{entable}[3][\quad\qquad]{%
  \set@etsep#1\relax\relax
  \begin{tabular}{%
    @{}*{\the\numexpr#3-1}{*{\the\numexpr#2-1}{l@{\etcolsep}}l@{\etitemsep}}%
    *{\the\numexpr#2-1}{l@{\etcolsep}}l@{}}}{%
  \end{tabular}}
\newcommand{\mergecol}[2]{\multicolumn{#1}{@{}l@{}}{#2}}

%% PXghost <https://gist.github.com/zr-tex8r/4461060>
%%% use an arbitrary font available in T1 encoding
\font\pxqgg@TI=ec-lmr10 at 1.23456pt
\chardef\pxqgg@cwm=23 % compwordmark (in T1)
\xspcode\pxqgg@cwm=3 % allow xkanjiskip around
%%%%<*> \eghostguarded{<text>}
\newcommand*\eghostguarded{%
  \ifmmode \expandafter\@firstofone
  \else \expandafter\pxqgg@eghostguarded@a
  \fi}
\def\pxqgg@eghostguarded@a#1{%
  {\pxqgg@TI\pxqgg@cwm}%
  #1%
  {\pxqgg@TI\pxqgg@cwm}}

%% ユーザ用マクロ
\chardef\vbar=`\| \chardef\bs=`\\
\let\lbrace\{ \let\rbrace\}
\chardef\{=`\{ \chardef\}=`\}
\newcommand{\codefont}{\ttfamily\gtfamily}
\newcommand{\cs}[1]{\eghostguarded{{\codefont \bs #1}}}
\newcommand{\code}[1]{\eghostguarded{{\codefont #1}}}
\newcommand{\single}[1]{\eghostguarded{`{\codefont #1}'}}
\newcommand{\mboxtt}[1]{\mbox{\texttt{#1}}}
\newcommand{\Meta}[1]{$\langle$\mbox{}\emph{#1}\mbox{}$\rangle$}

\makeatother

% -----------------------------------------------------------------------

\begin{document}

% 三段組を開始
\setlength{\columnsep}{10pt}
\begin{multicols}{3}
\setlength{\premulticols}{1pt}
\setlength{\postmulticols}{1pt}
\setlength{\multicolsep}{1pt}
\setlength{\columnsep}{2pt}

% 文字サイズ
\footnotesize

% タイトル
\begin{center}
\Large\sffamily\gtfamily
p\LaTeXe チートシート
\end{center}

\section{p\LaTeXe の基本}

\begin{entable}{2}{1}
\emph{命令} & \single{\bs}で始まる.
  必須の引数は\code{\{\}},省略可能な引数は\code{[]}で囲う \\
\emph{環境} & \cs{begin\{\Meta{環境名}\}}と\cs{end\{\Meta{環境名}\}}に挟まれた部分 \\
\emph{コメント} & \single{\%}以降は行末までコメントとして扱われる(無視される) \\
\end{entable}

すべてではないが,多くの命令や環境は入れ子にすることが可能.

\subsection{長さの単位}

\begin{entable}{2}{2}
|cm|/|mm|/|in|
  & \mergecol{3}{一般的な長さの単位($\SI{1}{in}=\SI{25.4}{mm}$)} \\
|pt|/|bp|/|sp|
  & \mergecol{3}{%
      ポイント($\SI{72.27}{pt}=\SI{72}{bp}=\SI{1}{in},\;\SI{65536}{sp}=\SI{1}{pt}$)} \\
|Q|/|H|
  & \mergecol{3}{級と歯($\SI{1}{Q}=\SI{1}{H}=\SI{0.25}{mm}$)} \\
|em|/|ex|\phantom{/|pt|} & Mの幅とxの高さ & |zw|/|zh| & 和文文字の幅と高さ \\
\end{entable}

\section{プリアンブル}

文書はクラス宣言で開始:
\code{\cs{documentclass}[\Meta{オプション}]\{\Meta{クラス}\}}.\\
本文はdocument環境に書く.\cs{documentclass}と\code{\cs{begin}\{document\}}の間は
\emph{プリアンブル}と呼ばれ,文書全体に適用する設定などを記述する.

\subsection{標準クラス}

\begin{entable}{2}{2}
|jbook| & 横書き書籍 & |tbook| & 縦書き書籍 \\
|jarticle| & 横書き論文 & |tarticle| & 縦書き論文 \\
|jreport| & 横書きレポート & |treport| & 縦書きレポート \\
\end{entable}

クラスによってデフォルトのオプションや使える見出し命令などが異なる.

\subsection{主な標準クラスオプション}

\begin{entable}[\enspace\qquad]{2}{2}
\mergecol{4}{%
  |a4paper|/|a5paper|/|b4paper|/|b5paper|\enspace 用紙サイズ(B系列はJIS規格)} \\
|a4j|/|a5j|/|b4j|/|b5j| & 上記より余白が狭い & |landscape| & 用紙を横向き \\
|10pt|/|11pt|/|12pt| & 文字サイズ & |twocolumn| & 二段組 \\
|titlepage| & タイトルを独立ページ & |twoside| & 両面印刷 \\
|leqno| & 数式番号を左側に表示 & |dvipdfmx| & dviドライバ \\
|fleqn| & 別行立て数式を左寄せ & |tombo| & トンボを表示 \\
\end{entable}

クラスオプションに指定したものは読み込んだパッケージへも適用される.

\subsection{文書情報}

\begin{entable}[\enspace\quad]{2}{2}
|\author{|\Meta{著者}|}|
  & \mergecol{3}{文書の著者.複数のときは \cs{and}で区切る} \\
|\thanks{|\Meta{注釈}|}|
  & \mergecol{3}{著者名に脚注(主に所属機関)を付ける} \\
|\title{|\Meta{タイトル}|}| & 文書のタイトル & |\date{|\Meta{日付}|}| & 文書の作成日 \\
\end{entable}

本文中\cs{maketitle}を記述すると上記の情報を基に表題が出力される.

\subsection{ページスタイル}

\begin{entable}[\enspace\qquad]{2}{2}
|empty| & 空のヘッダ・フッタ & |plain| & ノンブル(ページ番号) \\
|headings| & 柱とノンブル & |myheadings| & カスタムの柱
\end{entable}

\code{\cs{pagestyle}\{\Meta{スタイル}\}}の形式で指定.この命令は本文中でも利用可能.
\code{\cs{thispagestyle}\{\Meta{スタイル}\}}により一時的な変更もできる.
\code{myheadings}指定時は\code{\cs{markboth}\{\Meta{偶数ページ用}\}\{\Meta{奇数ページ用}\}}で
柱を設定.

\subsection{各種設定など}

\begin{entable}{2}{1}
|\usepackage[|\Meta{オプション}|]{|\Meta{パッケージ}|}| & パッケージ読み込み \\
|\setcounter{|\Meta{カウンタ}|}{|\Meta{数値}|}| & カウンタの値を設定 \\
|\setlength{|\Meta{寸法を表す命令}|}{|\Meta{長さ}|}| & 寸法を設定 \\
|\newcommand{|\Meta{命令}|}[|\Meta{引数の数}|]{|\Meta{定義}|}| & マクロの定義 \\
\end{entable}

\cs{usepackage}はプリアンブルのみで利用可.他の命令は中級者以上向け.

\section{文書の論理構造}

\begin{entable}[\enspace\quad]{2}{3}
\mergecol{2}{%
  \texttt{\bs part}\enspace 部\quad\texttt{\bs chapter}\enspace 章} &
|\section| & 節 & |\subsection| & 小節 \\
|\subsubsection| & 小々節 & |\paragraph| & 段落 & |\subparagraph| & 小段落 \\
\end{entable}

これらの命令は共通の書式をもつ:\Meta{命令}|[|\Meta{目次用の見出し}|]{|\Meta{見出し}|}|.\\
\Meta{命令}の直後に\single{*}を付けた場合,見出し番号が付かず目次にも載らない.

\subsection{箇条書き}

\begin{entable}[\enspace\qquad]{2}{2}
|\begin{itemize}| & 記号付き & |\begin{enumerate}| & 連番付き \\
|\begin{description}| & 見出し付き \\
\end{entable}

各項目は上記の環境中で\code{\cs{item} \Meta{テキスト}}により表現.
\code{\cs{item}[\Meta{ラベル}]}のようにすると当該項目のラベルのみを変更
(description環境では必須).

\subsection{フロート}

\begin{entable}[\enspace\quad]{2}{2}
|\begin{figure}[|\Meta{位置}|]| & 図を配置 & |\begin{table}[|\Meta{位置}|]| & 表を配置 \\
\end{entable}

各環境中\code{\cs{caption}[\Meta{図表目次用}]\{\Meta{説明文}\}}でキャプションを付けられる.
\Meta{位置}は次の文字の組み合わせで指定:$\mboxtt{t}=\mbox{ページ上部}$,
$\mboxtt{b}=\mbox{ページ下部}$,$\mboxtt{p}=\mbox{独立ページ}$,$\mboxtt{h}=\mbox{その場}$,
$\mboxtt{!}=\mbox{条件が悪くても指定位置に配置}$.

\subsection{引用と注釈}

\begin{entable}[\enspace\qquad]{2}{2}
|\begin{quote}| & 短い引用 & |\begin{quotation}| & 複数段落の引用 \\
\mergecol{2}{\code{\cs{footnote}[\Meta{番号}]\{\Meta{脚注}\}}}
  & \mergecol{2}{\code{\cs{marginpar}\{\Meta{傍注}\}}} \\
\end{entable}

\section{テキストプロパティ}

\subsection{書体}

\begin{entable}[\enspace]{3}{1}
|\textmc{|\Meta{テキスト}|}| & |{\mcfamily |\Meta{テキスト}|}| & \textmc{明朝体} \\
|\textgt{|\Meta{テキスト}|}| & |{\gtfamily |\Meta{テキスト}|}| & \textgt{ゴシック体} \\
|\textrm{|\Meta{テキスト}|}| & |{\rmfamily |\Meta{テキスト}|}| & \textrm{Roman family} \\
|\textsf{|\Meta{テキスト}|}| & |{\sffamily |\Meta{テキスト}|}| & \textsf{Sans serif family} \\
|\texttt{|\Meta{テキスト}|}| & |{\ttfamily |\Meta{テキスト}|}| & \texttt{Typewriter family} \\
|\textmd{|\Meta{テキスト}|}| & |{\mdseries |\Meta{テキスト}|}| & \textmd{Medium series} \\
|\textbf{|\Meta{テキスト}|}| & |{\bfseries |\Meta{テキスト}|}| & \textbf{Bold series} \\
|\textup{|\Meta{テキスト}|}| & |{\upshape |\Meta{テキスト}|}| & \textup{Upright shape} \\
|\textit{|\Meta{テキスト}|}| & |{\itshape |\Meta{テキスト}|}| & \textit{Italic shape} \\
|\textsl{|\Meta{テキスト}|}| & |{\slshape |\Meta{テキスト}|}| & \textsl{Slanted shape} \\
|\textsc{|\Meta{テキスト}|}| & |{\scshape |\Meta{テキスト}|}| & \textsc{Small Caps shape} \\
\end{entable}

\code{\cs{textnormal}\{\Meta{テキスト}\}}や\cs{normalfont}で常にデフォルトを適用可能.

\subsection{装飾}

\begin{entable}[\enspace]{3}{1}
|\emph{|\Meta{テキスト}|}| & |{\em |\Meta{テキスト}|}| & \emph{強調}(効果は環境依存) \\
|\underline{|\Meta{テキスト}|}| & & \underline{下線} \\
\end{entable}

\subsection{フォントサイズ}

\bgroup
\setlength{\columnsep}{14pt}
\begin{multicols}{2}
\begin{tabbing}
|\footnotesize| \= \kill
|\tiny| \> {\tiny 極小} \\
|\scriptsize| \> {\scriptsize スクリプトサイズ} \\
|\footnotesize| \> {\footnotesize 脚注サイズ} \\
|\small| \> {\small 小さい} \\
|\normalsize| \> {\normalsize 標準サイズ} \\
|\large| \> {\large 大きい} \\
|\Large| \= {\Large 超大きい} \\
|\LARGE| \> {\LARGE 超々大きい} \\
|\huge| \> {\huge 巨大} \\
|\Huge| \> {\Huge 超巨大} %\\
\end{tabbing}
\end{multicols}
\egroup

\code{\cs{fontsize}\{\Meta{サイズ}\}\{\Meta{行送り}\}\cs{selectfont}}で寸法による指定も可能.
これらの命令は通常\code{\{\Meta{命令} \Meta{テキスト}\}}の形で使用.

\subsection{入力通りに出力}

\begin{entable}[\enspace]{2}{1}
|\verb!|\Meta{テキスト}|!| & デリミタ(ここでは\single{!})間の内容をそのまま出力 \\
|\begin{verbatim}| & 入力通りに出力される環境 \\
\end{entable}

\code{\cs{verb*}}や\code{\cs{begin}\{verbatim*\}}を用いると空白
が\eghostguarded{}`\verb*! !'\eghostguarded{}で明示される.

\subsection{配置}

\begin{entable}[\qquad]{3}{1}
|\begin{center}| & |\centering| & 中央寄せ \\
|\begin{flushleft}| & |\raggedright| & 左寄せ \\
|\begin{flushright}| & |\raggedleft| & 右寄せ \\
\end{entable}

\section{空白・行・ページ}

\subsection{水平スペース(文字送り方向)}

\begin{entable}[\enspace\quad]{2}{4}
\verb*!\ ! & 空白 & |\enspace| & \SI{0.5}{em} & |\quad| & \SI{1}{em} & |\,|
  & \SI{1/6}{em}程度 \\
|~| & 改行禁止 & \mergecol{2}{\texttt{\bs hspace\{}\Meta{長さ}\texttt{\}}}
  & |\qquad| & \SI{2}{em} \\
\end{entable}

\cs{hfill}は無限に伸びる空白.英大文字で終わる文のピリオド直前に置く\cs{@}や
イタリック補正の\cs{/}もスペーシングに影響.

\subsection{垂直スペース(行送り方向)}

\begin{entable}[\quad]{6}{1}
|\smallskip| & |\medskip| & |\bigskip| & |\vspace{|\Meta{長さ}|}| & |\vfill| \\
\end{entable}

\code{\cs{phantom}\{\Meta{文字列}\}}を用いると\Meta{文字列}と縦横同じ寸法の空白を作る.

\subsection{行とページ}

\begin{entable}[\enspace]{2}{2}
|\par| & 改段落(空行と同じ) & |\noindent| & 行のインデントなし \\
|\\*| & 改行(改ページ禁止) & |\\[|\Meta{長さ}|]| & 改行(+垂直スペース) \\
|\linebreak| & 行分割を促進 & |\pagebreak| & ページ分割を促進 \\
|\newpage| & 改ページ(段移動) & |\clearpage| & 全図表出力+改ページ \\
\end{entable}

\section{記号・その他}

\subsection{特殊記号}

\begin{entable}[\thinspace\quad]{2}{4}
\& & |\&| & \dag & |\dag| & \textasciitilde & |\textasciitilde| & \textbackslash & |\textbackslash| \\
\% & |\%| & \ddag & |\ddag| & \textasciicircum & |\textasciicircum| & \textbar & |\textbar| \\
\# & |\#| & \dots & |\dots| & \texttrademark & |\texttrademark| & \textbardbl & |\textbardbl| \\
\_ & |\_| & \copyright & |\copyright| & \textregistered & |\textregistered| & \textbullet & |\textbullet| \\
\$ & |\$| & \pounds & |\pounds| & \textordfeminine & |\textordfeminine| & \textless & |\textless| \\
\P & |\P| & \S & |\S| & \textordmasculine & |\textordmasculine| & \textgreater & |\textgreater| \\
\end{entable}

\subsection{括弧類}

\begin{entable}{2}{6}
` ' & \verb*!` '! & `` '' & \verb*!`` ''! & \lbrace\space\rbrace & \verb*!\{ \}!
  & [ ] & \verb*![ ]! & ( ) & \verb*!( )! \\
\end{entable}

\subsection{ダッシュ類}

\begin{entable}[\qquad]{4}{1}
ハイフン & |-| & X-ray & 単語内,2単語の連結 \\
en-dash & |--| & 1--5 & 範囲を表す場合など \\
em-dash & |---| & Yes---or no? & 挿入句の導入など \\
\end{entable}

\subsection{アクセント類}

\begin{entable}[\enspace\qquad]{2}{6}
!` & |!`| & ?` & |?`| & \.a & |\.a| & \'a & |\'a| & \"a & |\"a| & \`a & |\`a| \\
\^a & |\^a| & \=a & |\=a| & \~a & |\~a| & \aa & |\aa| & \AA & |\AA| & \ae & |\ae| \\
\AE & |\AE| & \b a & |\b a| & \c c & |\c c| & \d a & |\d a| & \H a & |\H a| & \i & |\i| \\
\j & |\j| & \l & |\l| & \L & |\L| & \o & |\o| & \O & |\O| & \oe & |\oe| \\
\OE & |\OE| & \r a & |\r a| & \ss & |\ss| & \t oo & |\t oo| & \u a & |\u a| & \v a & |\v a| \\
\end{entable}

\subsection{その他}

\begin{entable}{2}{1}
|\today| & 現在の日付({\codefont\bs 西暦}, {\codefont\bs 和暦}で形式を変更可能) \\
|\TeX|/|\LaTeX|/|\LaTeXe| & \TeX/\LaTeX/\LaTeXe(ロゴ) \\
\end{entable}

\section{表組み}

\subsection{tabular環境}

\begin{entable}{1}{2}
|\begin{tabular}{|\Meta{列指定}|}| & |\begin{tabular*}{|\Meta{幅}|}{|\Meta{列指定}|}| \\
\end{entable}

\Meta{列指定}は次の文字を並べて指定:$\mboxtt{l}=\mbox{左寄せの列}$,
$\mboxtt{c}=\mbox{中央寄せの列}$,$\mboxtt{r}=\mbox{右寄せの列}$,
$\mboxtt{p\{\Meta{幅}\}}=\mbox{寸法指定の列}$,
$\mboxtt{@\{\Meta{区切り}\}}=\mbox{列間の区切り}$,
$\mboxtt{*\{\Meta{回数}\}\{\Meta{データ}\}}=\mbox{繰り返し}$,
$\mboxtt{\vbar}=\mbox{表全体の縦罫線}$.

\begin{entable}{2}{2}
|&| & 列の区切り & |\hline| & 表全体の横罫線 \\
|\\| & 行の終端 & |\cline{|\Meta{開始}|-|\Meta{終了}|}| & 範囲指定の横罫線 \\
\end{entable}

セルの結合:\code{\cs{multicolumn}\{\Meta{列数}\}\{\Meta{列指定}\}\{\Meta{テキスト}\}}.

\subsection{tabbing環境}

\begin{entable}{2}{2}
|\=| & タブ位置を設定 & |\>| & 次のタブ位置に移動 \\
|\\| & 行の終端 & |\kill| & 非表示行(タブ位置設定)の終端 \\
\end{entable}

\section{数式モード}

\begin{entable}{2}{2}
|$|\Meta{数式}|$| & インライン数式 & |\begin{equation}| & 別行立て数式 \\
|\[|\Meta{数式}|\]| & \mergecol{3}{別行立て数式(式番号なし)} \\
\end{entable}

\subsection{数式の基本}

\begin{entable}[\enspace\quad]{2}{5}
$p'=0$ & |p'=0| & $a_1$ & |a_1| & $x^{2}$ & |x^2| & $\frac{3}{4}$ & |\frac{3}{4}|
  & $\sqrt[5]{6}$ & |\sqrt[5]{6}| \\
\mergecol{10}{\code{\cs{begin}\{array\}\{\Meta{列指定}\}}\enspace 行列用の表} \\
\end{entable}

数式モードではテキスト中で使える水平スペース命令のほかに以下が使える.

\begin{entable}{2}{3}
|\:| & \SI{4/18}{em}程度 & |\;| & \SI{5/18}{em}程度 & |\!| & \SI{-3/18}{em}程度 \\
\end{entable}

\subsection{スタイルと書体}

\begin{entable}[\enspace\quad]{2}{2}
|\displaystyle| & 別行立てスタイル & |\textstyle| & インラインスタイル \\
\end{entable}

書体の変更には\cs{mathrm}, \cs{mathbf}, \cs{mathit}, \cs{mathsf}, \cs{mathtt},
\cs{mathmc}, \cs{mathgt}および\cs{mathnormal}を用いる(組み合わせは不可).
英大文字に対してのみカリグラフ体への変更命令\cs{mathcal}が利用できる(例:$\mathcal{ABC}$).

\subsection{上下の装飾}

\begin{entable}[\enspace\quad]{2}{3}
$\overline{ab}$ & |\overline{ab}| & $\overrightarrow{ab}$ & |\overrightarrow{ab}|
  & $\widehat{ab}$ & |\widehat{ab}| \\
$\underline{ab}$ & |\underline{ab}| & $\overleftarrow{ab}$ & |\overleftarrow{ab}|
  & $\widetilde{ab}$ & |\widetilde{ab}| \\[2pt]
\mergecol{6}{%
  $\overbrace{a+b}$\enspace \texttt{\bs overbrace\{a+b\}}\quad
  $\underbrace{a+b}$\enspace \texttt{\bs underbrace\{a+b\}}} \\
\end{entable}

\subsection{ギリシャ文字}

\begin{entable}[\enspace\quad]{2}{6}
$\alpha$ & |\alpha| & $\beta$ & |\beta| & $\gamma$ & |\gamma| & $\delta$ & |\delta| & $\epsilon$ & |\epsilon| \\
$\zeta$ & |\zeta| & $\eta$ & |\eta| & $\theta$ & |\theta| & $\iota$ & |\iota| & $\kappa$ & |\kappa| \\
$\lambda$ & |\lambda| & $\mu$ & |\mu| & $\nu$ & |\nu| & $\xi$ & |\xi| & $\pi$ & |\pi| \\
$\rho$ & |\rho| & $\sigma$ & |\sigma| & $\tau$ & |\tau| & $\upsilon$ & |\upsilon| & $\phi$ & |\phi| \\
$\chi$ & |\chi| & $\omega$ & |\omega| & $\Gamma$ & |\Gamma| & $\Delta$ & |\Delta| & $\Theta$ & |\Theta| \\
$\Lambda$ & |\Lambda| & $\Xi$ & |\Xi| & $\Pi$ & |\Pi| & $\Sigma$ & |\Sigma| & $\Upsilon$ & |\Upsilon| \\
$\Phi$ & |\Phi| & $\Psi$ & |\Psi| & $\Omega$ & |\Omega| & $\varpi$ & |\varpi| & $\varphi$ & |\varphi| \\
$\varepsilon$ & \mergecol{3}{\texttt{\bs varepsilon}}
  & $\vartheta$ & \mergecol{3}{\texttt{\bs vartheta}} & $\varsigma$ & |\varsigma| \\
\end{entable}

\subsection{二項演算子}

\begin{entable}[\enspace\quad]{2}{4}
$\times$ & |\times| & $\div$ & |\div| & $\vee$ & |\vee| & $\triangleright$ & |\triangleright| \\
$\cdot$ & |\cdot| & $\mp$ & |\mp| & $\wedge$ & |\wedge| & $\bigtriangleup$ & |\bigtriangleup| \\
$\ast$ & |\ast| & $\pm$ & |\pm| & $\uplus$ & |\uplus| & $\bigtriangledown$ & |\bigtriangledown| \\
$\star$ & |\star| & $\cap$ & |\cap| & $\sqcap$ & |\sqcap| & $\triangleleft$ & |\triangleleft| \\
$\setminus$ & |\setminus| & $\cup$ & |\cup| & $\sqcup$ & |\sqcup| & $\dagger$ & |\dagger| \\
$\oslash$ & |\oslash| & $\odot$ & |\odot| & $\bullet$ & |\bullet| & $\ddagger$ & |\ddagger| \\
$\otimes$ & |\otimes| & $\oplus$ & |\oplus| & $\circ$ & |\circ| & $\bigcirc$ & |\bigcirc| \\
$\ominus$ & |\ominus| & $\wr$ & |\wr| & $\amalg$ & |\amalg| & & |\mathbin{|\Meta{記号}|}| \\
\end{entable}

\subsection{関係演算子}

\begin{entable}[\enspace\quad]{2}{5}
$\neq$ & |\neq| & $\supset$ & |\supset| & $\perp$ & |\perp| & $\parallel$ & |\parallel| & $\mid$ & |\mid| \\
$\leq$ & |\leq| & $\subset$ & |\subset| & $\equiv$ & |\equiv| & $\doteq$ & |\doteq| & $\asymp$ & |\asymp| \\
$\geq$ & |\geq| & $\supseteq$ & |\supseteq| & $\sim$ & |\sim| & $\simeq$ & |\simeq| & $\models$ & |\models| \\
$\gg$ & |\gg| & $\subseteq$ & |\subseteq| & $\cong$ & |\cong| & $\approx$ & |\approx| & $\propto$ & |\propto| \\
$\ll$ & |\ll| & $\sqsubseteq$ & |\sqsubseteq| & $\succ$ & |\succ| & $\succeq$ & |\succeq| & $\dashv$ & |\dashv| \\
$\in$ & |\in| & $\sqsupseteq$ & |\sqsupseteq| & $\prec$ & |\prec| & $\preceq$ & |\preceq| & $\vdash$ & |\vdash| \\
$\ni$ & |\ni| & $\bowtie$ & |\bowtie| & $\not$ & |\not| &
  & \mergecol{3}{\texttt{\bs mathrel\{}\Meta{記号}\texttt{\}}} \\
\end{entable}

関係演算子の前に\cs{not}を前置すると,その否定形を作ることができる.

\subsection{大型演算子}

\begin{entable}[\enspace\quad]{2}{4}
$\int$ & |\int| & $\bigotimes$ & |\bigotimes| & $\bigcap$ & |\bigcap| & $\bigcup$ & |\bigcup| \\[3pt]
$\oint$ & |\oint| & $\bigoplus$ & |\bigoplus| & $\biguplus$ & |\biguplus| & $\bigsqcup$ & |\bigsqcup| \\[3pt]
$\sum$ & |\sum| & $\bigodot$ & |\bigodot| & $\bigvee$ & |\bigvee| & $\bigwedge$ & |\bigwedge| \\[3pt]
$\prod$ & |\prod| & $\coprod$ & |\coprod| & $\smallint$ & |\smallint| & & |\mathop{|\Meta{記号}|}| \\
\end{entable}

\subsection{括弧類}

\begin{entable}[\enspace\quad]{2}{6}
$\langle$ & |\langle| & $\lceil$ & |\lceil| & $\lfloor$ & |\lfloor| 
& \scalebox{.5}{$\big\lgroup$} & |\lgroup| & \scalebox{.5}{$\big\lmoustache$} & |\lmoustache| \\
$\rangle$ & |\rangle| & $\rceil$ & |\rceil| & $\rfloor$ & |\rfloor| 
& \scalebox{.5}{$\big\rgroup$} & |\rgroup| & \scalebox{.5}{$\big\rmoustache$} & |\rmoustache| \\
\mergecol{2}{$\vbar$ \texttt{\vbar} \quad $\|$ \texttt{\bs\vbar}} &
  & \mergecol{3}{\texttt{\bs mathopen\{}\Meta{記号}\texttt{\}}} &
  & \mergecol{3}{\texttt{\bs mathclose\{}\Meta{記号}\texttt{\}}} \\
\end{entable}

\cs{left}\Meta{開き括弧}\Meta{数式}\cs{right}\Meta{閉じ括弧}で括弧類のサイズを自動調整.

\subsection{矢印類}

\begin{entable}[\thinspace\enspace]{2}{3}
$\to$ & |\to| & $\hookrightarrow$ & |\hookrightarrow| & $\Uparrow$ & |\Uparrow| \\
$\gets$ & |\gets| & $\hookleftarrow$ & |\hookleftarrow| & $\Downarrow$ & |\Downarrow| \\
$\nearrow$ & |\nearrow| & $\leftrightarrow$ & |\leftrightarrow| & $\rightleftharpoons$ & |\rightleftharpoons| \\
$\searrow$ & |\searrow| & $\rightharpoonup$ & |\rightharpoonup| & $\longrightarrow$ & |\longrightarrow| \\
$\nwarrow$ & |\nwarrow| & $\rightharpoondown$ & |\rightharpoondown| & $\Longrightarrow$ & |\Longrightarrow| \\
$\swarrow$ & |\swarrow| & $\leftharpoonup$ & |\leftharpoonup| & $\longleftarrow$ & |\longleftarrow| \\
$\mapsto$ & |\mapsto| & $\leftharpoondown$ & |\leftharpoondown| & $\Longleftarrow$ & |\Longleftarrow| \\
$\longmapsto$ & |\longmapsto| & $\Leftrightarrow$ & |\Leftrightarrow| & $\longleftrightarrow$ & |\longleftrightarrow| \\
$\Rightarrow$ & |\Rightarrow| & $\updownarrow$ & |\updownarrow| & $\Longleftrightarrow$ & |\Longleftrightarrow| \\
$\Leftarrow$ & |\Leftarrow| & $\downarrow$ & |\downarrow| & & |\iff|(前後の空白大) \\
$\uparrow$ & |\uparrow| & $\Updownarrow$ & |\Updownarrow| \\
\end{entable}

\subsection{関数名}

\begin{entable}[\quad\quad]{1}{8}
|\log| & |\sin| & |\arcsin| & |\sinh| & |\max| & |\arg| & |\exp| & |\ker| \\
|\lg| & |\cos| & |\arccos| & |\cosh| & |\min| & |\lim| & |\Pr| & |\dim| \\
|\ln| & |\tan| & |\arctan| & |\tanh| & |\sup| & |\limsup| & |\gcd| & |\hom| \\
|\sec| & |\csc| & |\cot| & |\coth| & |\inf| & |\liminf| & |\deg| & |\det| \\
\end{entable}

\subsection{アクセント類}

\begin{entable}[\enspace\qquad]{2}{4}
$\bar{a}$ & |\bar{a}| & $\acute{a}$ & |\acute{a}| & $\dot{a}$ & |\dot{a}| & $\ddot{a}$ & |\ddot{a}| \\
$\vec{a}$ & |\vec{a}| & $\breve{a}$ & |\breve{a}| & $\grave{a}$ & |\grave{a}| & $\mathring{a}$ & |\mathring{a}| \\
$\hat{a}$ & |\hat{a}| & $\check{a}$ & |\check{a}| & $\tilde{a}$ & |\tilde{a}| &  &  \\
\end{entable}

\subsection{その他}

\begin{entable}[\enspace\quad]{2}{4}
$\spadesuit$ & |\spadesuit| & $\flat$ & |\flat| & $\surd$ & |\surd| & $\nabla$ & |\nabla| \\
$\heartsuit$ & |\heartsuit| & $\natural$ & |\natural| & $\smile$ & |\smile| & $\partial$ & |\partial| \\
$\diamondsuit$ & |\diamondsuit| & $\sharp$ & |\sharp| & $\frown$ & |\frown| & $\infty$ & |\infty| \\
$\clubsuit$ & |\clubsuit| & $\prime$ & |\prime| & $\top$ & |\top| & $\angle$ & |\angle| \\
$\diamond$ & |\diamond| & $\Re$ & |\Re| & $\bot$ & |\bot| & $\triangle$ & |\triangle| \\
$\backslash$ & |\backslash| & $\Im$ & |\Im| & $\forall$ & |\forall| & $\exists$ & |\exists| \\
$\aleph$ & |\aleph| & $\hbar$ & |\hbar| & $\neg$ & |\neg| & $\emptyset$ & |\emptyset| \\
$\ell$ & |\ell| & $\wp$ & |\wp| & $\imath$ & |\imath| & $\jmath$ & |\jmath| \\[-6pt]
$\cdots$ & |\cdots| & $\ldots$ & |\ldots| & \raisebox{-2pt}{$\vdots$} & |\vdots| & \raisebox{-2pt}{$\ddots$} & |\ddots| \\
\end{entable}

\section{相互参照・目次・索引・文献リスト}

これらの機能を利用するには一般に\code{platex}を複数回実行する必要がある.

\subsection{相互参照}

\begin{entable}{2}{1}
|\label{|\Meta{ラベル}|}| & 相互参照用のラベルをセット \\
|\ref{|\Meta{ラベル}|}| & ラベル位置(章や図表,式番号など)を出力 \\
|\pageref{|\Meta{ラベル}|}| & ラベル位置のページ番号を出力 \\
\end{entable}

\subsection{目次}

\begin{entable}[\enspace\qquad]{3}{2}
|toc| & |\tableofcontents|
  & \mergecol{4}{目次(|tocdepth| カウンタで掲載項目を調整)} \\
|lof| & |\listoffigures| & 図目次 & |lot| & |\listoftables| & 表目次 \\
\end{entable}

項目の追加:
\code{\cs{addcontentsline}\{\Meta{目次の種類}\}\{\Meta{項目の種類}\}\{\Meta{項目}\}}.

\subsection{索引}

\begin{entable}{2}{1}
|\index{|\Meta{上位項目}|!|\Meta{読み}|@|\Meta{項目}\texttt{\vbar}\Meta{体裁}|}|
  & 索引項目の追加 \\
\end{entable}

indファイルは\code{mendex}で処理.索引の出力には別途パッケージが必要.

\subsection{文献リスト}

\begin{entable}{2}{1}
|\cite[|\Meta{コメント}|]{|\Meta{キー}|,|\Meta{キー}|,|\dots|}| & 対応する文献を引用 \\
|\begin{thebibliography}{|\Meta{最大ラベル}|}| & 文献リスト用の箇条書き \\
|\bibitem[|\Meta{ラベル}|]{|\Meta{キー}|} |\Meta{テキスト} & 文献項目の記述 \\
\end{entable}

\code{pbibtex}を用いて文献リストをデータベースから自動生成する方法もある.

\section{p\LaTeX 文書のサンプル}

\lstinputlisting{sample.tex}

\rule{.3\linewidth}{.25pt}
\scriptsize

\LaTeXe 版 {\copyright} 2006 Winston Chang \\
\url{http://www.stdout.org/~winston/latex/}

p\LaTeXe 版 {\copyright} 2017 Takuto Asakura \\
\url{https://wtsnjp.com/pdf/platexsheet.pdf}

バージョン:3.1, 更新日:2018/12/31

\end{multicols}
\end{document}