summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/istgame/istgame-doc.tex
blob: 52ec5a61497bff879d5ad5237c429958f91caac2 (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
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
%!TEX program = arara
% arara: pdflatex: {shell: yes, synctex: yes}
% arara: xelatex: {shell: yes, synctex: yes}
% arara: makeindex: {style: istgame} 
% arara: xelatex: {shell: yes, synctex: yes}
% arara: xelatex: {shell: yes, synctex: yes}

\def\tmpdate{2022/03/22}
\def\tmpdate{\today}
\def\tmpversion{2.1}	

\def\printtikztreetest{}
\def\printtest{}
\def\printteststar{}
\def\printdoc{}
%\renewcommand\printtikztreetest{\input{istgame_test_tree}}
%\renewcommand\printtest{\clearpage\input{istgame_test}}
%\renewcommand\printteststar{\clearpage\input{istgame_test-star}}
\renewcommand\printdoc{\include{istgame-doc-v\tmpversion}}

%% ======================================================
\documentclass[a4paper,amsmath]{oblivoir}
%% ======================================================
%\documentclass[a4paper,article]{memoir}
%\renewcommand\thesection{\arabic{section}}

%\usepackage{istgame-v\tmpversion}
\usepackage{istgame}

\usepackage{fapapersize}
\usefapapersize{*,*,30mm,*,28mm,*}
\setsecnumdepth{subsubsection}
\settocdepth{subsubsection}
\setlength\cftsubsubsectionindent{4.5em}

%% us date
\usepackage{datetime}
\usdate \let\mytoday\today
\AtBeginDocument{\let\today\mytoday}

\AtBeginDocument{%
\renewcommand\contentsname{Table of Contents}
\renewcommand\figurename{Figure}
\renewcommand\tablename{Table}
\renewcommand\abstractname{Abstract}
\renewcommand\indexname{Index}
\renewcommand\pagerefname{\kern-4pt}%
}


%\usepackage[hidelinks]{hyperref} % (memoir)
\hypersetup{pdfborder={0 0 0}} % to suppress the hyperlink red box

%\usepackage{amsmath,mathtools}
%\usepackage{xparse}  %% oblivoir loads xparse
%\usepackage{tikz}    %% istgame loads tikz
\usepackage{makecell}
\usepackage{capt-of}
\usepackage{multido}
\usepackage[normalem]{ulem} % [normalem] to correct the pdf bookmark broken characters
\usepackage{idxlayout}
%\usepackage{url}

%\setistdefaultnodedrawcolor{red} % test
%\setistdefaultnodefillcolor{black!16} % (try for MacOS mohave dark mode, TeXShop background color)

\usepackage{tcolorbox}
\tcbuselibrary{minted,xparse,listings,breakable}
\tcbset{%
  listing engine=minted,breakable,
%  minted language=latex,
  after={\par\vspace{.5\baselineskip}\noindent}
}
\tcbset{%
  colback=yellow!5!white,
  colframe=blue!30,
  listing outside text,
  righthand width=.3\linewidth,
  center upper,
  center lower,
  sidebyside gap=5pt,
  minted style=igor, %tango, **igor, xcode, ***manni, *autumn, colorful,
  listing options={%
    style=tcblatex,
%    keywordstyle={\color{blue}},
    commentstyle=\color{black!20!green},
%    morekeywords={
%      istgamefontsize,setistgamefontsize,setistgamearrowendshorten,
%      istgame,istroot,istrooto,istb,endist,xtdistance,istbm,
%      istbt,istB,istBt,istbA,cntmAInfoset,cntmAInfosetO,
%      istrootcntm,istrootcntmA,istrootocntm,istrootocntmA,
%      setistgrowdirection,istgrowdirection,
%      setistmathTF,istownerlmathtrue,istownermathfalse,istactioinlabelmathtrue,
%      istactionlabelmathfalse,istpayoffmathtrue,istpayoffmathfalse,
%      cntmdistance,cntmlevdist,cntmsibdist,
%      cntmApreset,cntmistb,cntmAistb,cntmAexpostShowEndPoints,
%      xtInfoset,xtInfosetO,xtActionLabel,
%      xtSubgame,xtSubgameBox,xtSubgameOval,
%      xtgrow,setxtgrowkey,xtInfosetOwner,xtOwner,xtPayoff,xtNode,
%      xtALPush,xtALShift,
%      xtShowEndPoints,xtHideEndPoints,
%      xtShowTerminalNodes,xtHideTerminalNodes,
%      xtTimeLineH,xtTimeLineV,xtCommentTo,xtCommentFrom,xtShowArrows,xtHideArrows,
%      xtlevdist,xtsibdist,
%      xtShowArrows,xtHideArrows,xtShowMidArrows,xtHideMidArrows,
%      setxtshowarrows,setxtmidarrows,setxtshowmidarrows,
%      setxtinfosetlayer,setxtsubgamelayer,
%      setistNewNodeStyle,
%      setistDecisionNodeStyle,setistOvalNodeStyle,
%      setistSolidNodeStyle,setistHollowNodeStyle,
%      setistEllipseNodeStyle,setistNullNodeStyle,setistRectangleNodeStyle,
%      xtALpush,xtALshift,
%      xtdefaultsubrootshiftoval,
%      tikzstyle,draw,coordinate,foreach,setlength,
%      NewDocumentCommand,NewDocumentEnvironment,IfBooleanTF,tikzset,   
%      xtCInfoset,xtCInfosetO,xtCInfosetOTurnX,
%      cntmpreset,cntmApreset,cntmAlayerpreset
%      setxtinfosetstyle,setxtarrowtips,setxtinfosetstyle
%    },
  }, % end of listing options
}

\DeclareTCBListing{docstx}{ !O{} }
  {colback=blue!5!white,listing only,#1}
\DeclareTCBListing{docsty}{ !O{} }
  {colback=red!5!white,listing only,#1}
\DeclareTCBListing{docplain}{ !O{} }
  {colback=white,colframe=gray!15,listing only,#1}
\DeclareTCBListing{doccode}{ !G{1} !O{} }
  {righthand width=\expandafter#1\linewidth,#2}


%\usepackage{tikz-qtree} %%% DO NOT USE
% or, add the following in the option
%     [ edge from parent path={(\tikzparentnode) -- (\tikzchildnode)} ]


\linespread{1}

\newcommand*\Tikz{Ti\textit{k}Z}
\let\TikZ\Tikz

\newenvironment{keywords}{%
	\par\vskip2pt
	\noindent\hangfrom{\textsc{Keywords: }}%
}

\NewExpandableDocumentCommand\xcol{mO{c|}m}
  {\multicolumn{#1}{#2}{\ensuremath{#3}}}

%% more lazy macros
\newcommand\xbigskip[1]{\multido{}{#1}\bigskip}
\newcommand\xmedskip[1]{\multido{}{#1}\bigskip}
\newcommand\xsmallskip[1]{\multido{}{#1}\bigskip}
\def\hpara{\hangpara{1.52em}{1}}
\def\listdivider{\leavevmode\smallskip\hrule width 1.5em\smallskip}

\NewDocumentCommand\remark{ O{1} }
  {\xmedskip{#1}\noindent \textbf{Remark: }}
\NewDocumentCommand\warning{ O{1} }
  {\xmedskip{#1}\noindent \textbf{Warning: }}
%
\newcommand\sourcelink[1]{\ttfamily\color{blue}\uline{#1}}
%
%%% index
%\renewcommand\cmd[1]{\cmdprint{#1}}
\ExplSyntaxOn
\renewcommand \cmd [1]
{
  \texorpdfstring 
    { \cmdprint {#1} }
    { \textbackslash \cs_to_str:N #1 }
}
\let\CMD\cmd
\ExplSyntaxOff

\newcommand\xw[1]{\cmd{#1}}
\newcommand\xttw[1]{\texttt{#1}}
\newcommand\pkg[1]{\textsf{#1}}
\newcommand\env[1]{\textsf{#1}}
\newcommand\isw[1]{#1\index{#1}}                        % simple word in text/index
\newcommand\ixsw[1]{\cmd{#1}\index{#1}}                 % texttt in text, simple word in index
\newcommand\ixw[1]{\textsf{#1}\index{#1@\textsf{#1}}}   % textsf in text/index
\newcommand\ixttw[1]{\texttt{#1}\index{#1@\texttt{#1}}} % texttt in text/index
\newcommand\ipkg[1]{\textsf{#1}\index{#1@\textsf{#1}}}
\newcommand\ienv[1]{\textsf{#1}\index{#1@\textsf{#1}}}


\makeatletter
\newcommand{\icmd}[1]{\cmdprint{#1}%
  \index{\expandafter\@gobble\string#1(@\string\cmdprint{\string#1}}}
\makeatother

\makeindex

\title{\texttt{istgame.sty} \\
Draw Game Trees with \Tikz}
\author{In-Sung Cho \\  \texttt{ischo <at> ktug.org}}
\date{Economics, Kongju National University\\[3pt] \tmpdate\quad version \tmpversion}

\def\tmpclearpage{\clearpage}

\AtBeginDocument{\MakeShortVerb{\|}}

%%=======================================================================
\begin{document}

\frontmatter
\maketitle

\renewcommand{\abstracttextfont}{\normalfont\small\noindent\ignorespaces}
\begin{abstract}
This is a \LaTeX{} package that provides \Tikz-based macros to draw game trees. The main idea underlying the core macros here is the completion of a whole tree by using a sequence of simple `parent-child' tree structures, with no longer nested relations involved like the use of grandchildren or great-grandchildren.
With the \ipkg{istgame} package, you can draw game trees as easily as drawing game trees with pen and paper.
\begin{keywords}
game trees, nodes, branches, information sets, continuum of branches, subgames
\end{keywords}
\end{abstract}

\tableofcontents*

\mainmatter


\printtikztreetest
\printtest
\printteststar
\printdoc


%\clearpage
\setsecnumdepth{chapter}
\section{Version history}
\label{version-history}

\begin{itemize}
%\item v\tmpversion (\tmpdate) to be uploaded to CTAN
%  \begin{itemize}
%  \item 
%  \end{itemize}
\item v2.1 (2022/03/22) uploaded to CTAN
  \begin{itemize}
  \item document done!
  \end{itemize}
\item v2.092 (2022/03/21)
  \begin{itemize}
  \item working on the documentation
  \item added |arrows.meta| and |bending| to the list of preloaded |tikz| libraries
    \begin{itemize}
    \item applied |arrows.meta| arrow tips to the related examples
    \end{itemize}
  \end{itemize}
\item v2.091 (2022/03/16)
  \begin{itemize}
  \item modified |istgame| environment to add its starred version
    \begin{itemize}
    \item |\begin{istgame}*| is essentially the same as |\begin{tikzpicture}|
    \item but loses some feature of the \pkg{istgame} package
    \end{itemize}
  \item fixed all macros related information sets to remove arrow tips
  \item touched |\AtBeginDocument{\setxtarrowtips}|
  \item rewrote |\setistmathTF(*)| and related macros to avoid a possible conflict
  \end{itemize}
\item v2.09 (2021/04/05)
  \begin{itemize}
  \item removed |\pgfextra| from |\istrootcntm| and |\istrootcntmA| (debugging)
  \item resolved the null font problem in |\cntmistb| and |\cntmAistb| using |\l_nullfont_tl| (debugging)
  \item added |\setist<...>nodesize| for |solid|, |hollow|, |ellipse|, and |rectangle| (for global setting in the preamble)
  \end{itemize}
\item v2.0 (2019/01/27) uploaded to CTAN
  \begin{itemize}
  \item changed the title of the package to ``Draw Game Trees with \Tikz"
  \item package document done
  \end{itemize}
\item v2.0rc (2019/01/27)
  \begin{itemize}
  \item introduced |\setxtinfosetstyle|
    \begin{itemize}
    \item introduced |infoset style|, a new style for information sets
    \item modified all definitions of information sets, accordingly
    \end{itemize}
  \item redefined macros related to layer, to easily restore default values
  \item modified the cross arrow tip options
  \item modified defaults of |\setxtarrowtips| not to depend on branch styles initially
  \item code refinement
  \end{itemize}
\item v2.0beta1 (2019/01/26)
  \begin{itemize}
%  \item beta test
  \item introduced |\xtshowXpoints| and |\xtshowXcircles| (for developer only, not documented)
  \end{itemize}
%%%\item v1.99x (2019/01/24)
%%%  \begin{itemize}
%%%  \item changed |expl3| macros
%%%    \begin{itemize}
%%%    \item \verb+\str_case_x:nnTF+ to \verb+\str_case_e:nnTF+ and then to \verb+\str_case:nnTF+
%%%    \item \verb+\str_if_eq_x:nnTF+ to \verb+\str_if_eq:eeTF+ and then to \verb+\str_if_eq:nnTF+
%%%    \end{itemize}
%%%  \item modified macros on arrows and middle arrows
%%%  \item redefined |\xtTimeLineH| and |\xtTimeLineV| to deal with swap of branches
%%%  \item modified |\xtCommentTo| and |\xtCommentFrom| for the last option delimiters
%%%  \end{itemize}
%%%\item v1.99w (2019/01/21)
%%%  \begin{itemize}
%%%  \item fixed bug in |\xtInfosetO| regarding |\xtinfosetheihtvar| for |rounded corner|
%%%  \item corrected |\cntmistb| and |\cntmAistb|
%%%    \begin{itemize}
%%%    \item separated options for |\cntmAistb| from those for |\cntmistb|
%%%    \item those two are independent to each other (except the way to deal with endpoints)
%%%    \end{itemize}
%%%  \item redefined |\endist| to restore initial values after each execution of the \verb+cntm(A)istb+ 
%%%    \begin{itemize}
%%%    \item but not for the effect of printing endpoints
%%%    \item (internally introduced) |\cntmistbVariablesRestore|
%%%    \item (internally introduced) |\cntmAistbVariablesRestore|
%%%    \end{itemize}
%%%  \item introduced |\xtHideEndPoints*| for extra work for continuum endpoints
%%%  \item introduced |\cntmAlayerpreset|, with |behind| as default
%%%  \item redefined |\xtShowArrows| to add an option for a node style
%%%  \item changed the order of options for |\setxtshowarrows|
%%%  \item changed the order of options for |\setxtarrowtips|
%%%  \item renamed |\setxtmidarrows| to |\setxtarrowtips|
%%%  \end{itemize}
%%%\item v1.99v (2018/01/17)
%%%  \begin{itemize}
%%%  \item redefined the \env{istgame} environment and |\istgameScaleCallTestAndAdjust| 
%%%        to take care of simultaneous use of |xscale| and |yscale|.
%%%  \item modified macros to make singleton information sets scaled accordingly when needed
%%%    \begin{itemize}
%%%    \item |\xtInfosetO|, |\xtCInfosetO|, |\cntmAInfosetO|, |\istgameScaleCallTestAndAdjust|
%%%    \item (internally) added |\xtinfosetheightvar| and |\cntminfosetheightvar|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99u (2019/01/15)
%%%  \begin{itemize}
%%%  \item redefined macros to deal with local change of sibling distances
%%%    \begin{itemize}
%%%    \item redefined |\istrootcntm|, |\istrootcntmA|, |\istrootocntm|, |\istrootocntmA|, 
%%%    \item redefined |\istbA|, |\istbAt|
%%%    \item redefined |\cntmpreset|, |\cntmApreset|  -- NEED TO GO BACK (no need call test)
%%%    \end{itemize}
%%%  \item redefined |\xtCInfoset| to add abbreviations for the position of owners
%%%  \item redefined |\xtCInfoset| to print a singleton information set
%%%  \item modified |\xtCInfoset| to change the way of input for its position (|add to \textbackslash cntmApos|)
%%%  \end{itemize}\
%%%\item v1.99t (2019/01/13)
%%%  \begin{itemize}
%%%  \item redefined macros to deal with local change of level and sibling distances for |\istbA|
%%%    \begin{itemize}
%%%    \item code complication, inevitable to take care of too many cases
%%%    \item redefined |\istroot| and |\istrooto|
%%%    \item redefined |\istrootcntm| and its variants
%%%    \item redefined |\istbA| and |\istbAt|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99s (2019/01/10)
%%%  \begin{itemize}
%%%  \item modified |\xtCInfosetO| for better results when swapped with \xw{plotfactor} less than 1
%%%  \item modified |\istrootcntm| and its variants for better results of shrunken continua
%%%  \item redefined |\xtTimeLineH| (for a horizontal time-line)
%%%  \item introduced |\xtTimeLineH(')| for a vertical time-line
%%%  \item introduced |\xtCInfosetOTurnX| for turning X circles to use it just in case
%%%  \end{itemize}
%%%\item v1.99r (2019/01/07)
%%%  \begin{itemize}
%%%  \item redefined |\istrootcntm| and |\istrootocntm| for smaller triangle continua of branches 
%%%  \item introduced |\cntmpreset| and |\cntmpreset*|
%%%  \item put `call test' for cases of how to change level distance with |\istbA|
%%%  \item modified |\xtCInfosetO| and |\cntmAInfosetO| for coloring
%%%  \end{itemize}
%%%\item v1.99q (2019/01/05)
%%%  \begin{itemize}
%%%  \item modified |\xtInfosetO| to print a singleton information set by a circle.
%%%  \item finished fine-tuning |\cntmAInfosetO| (for tuning base circles)
%%%  \end{itemize}
%%%\item v1.99p (2019/01/02)
%%%  \begin{itemize}
%%%  \item redefined |\xtInfoset| and |\xtInfosetO| in accordance with new |\xtCInfosetO|
%%%  \item redefined completely |\cntmAInfoset| and |\cntmAInfsetO| in the way of |\xtCInfosetO|
%%%  \item redefined |\cntmAInfoset|, |\cntmAInfosetO|, |\istrootcntmA|, and |\istrootocntmA|
%%%    \begin{itemize}
%%%    \item to compensate the dependency of arcs on the ratio of |\cntmlevdist| to |\cntmsibdist|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99o (2018/12/31)
%%%  \begin{itemize}
%%%  \item redefined completely |\xtCInfosetO| and |\xtCInfoset| for enhancement
%%%    \begin{itemize}
%%%      \item (internally) added |\setxtCIAngleAccordingtoGrowswapCallForCI|
%%%      \item to make it possible for the control points to turn accordingly along the base circles 
%%%            for sides of curved information sets
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99n (2018/12/27)
%%%  \begin{itemize}
%%%  \item redefined |\setistmathTF*| to make it work with basic text font styles
%%%    \begin{itemize}
%%%    \item |\istownertextfont|, |\istactionlabeltextfont|, |\istpayofftextfont|
%%%    \item all working only in text mode
%%%    \end{itemize}
%%%  \item introduced |\xtcureslopedlabelsNS| and |\xtcureslopedlabelsEW| to resolve a \Tikz\ conflict to sloped labels
%%%    \begin{itemize}
%%%    \item (internally) added |\xtlevdistadj| and |\xtsibdistadj|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99m (2018/12/21)
%%%  \begin{itemize}
%%%  \item added starred versions that work with |\setistmathTF|
%%%  \begin{itemize}
%%%  \item |\xtInfoset*|, |\xtInfosetO*|, |\xtCInfoset|, |\xtCInfosetO|
%%%  \item |\xtOwner*|, |\xtActionLabel*|, |\xtPayoff*|, |\xtInfosetOwner*|
%%%  \end{itemize}
%%%  \end{itemize}
%%%\item v1.99l (2018/12/18)
%%%  \begin{itemize}
%%%  \item changed the order and the type of argument delimiters for input consistency
%%%    \begin{itemize}
%%%    \item |\xtCInfosetO|, |\cmtmAinfosetO|, and their related macros
%%%    \item effective from \xw{v.1.99l}
%%%      \begin{itemize}
%%%      \item not consistent with the earlier versions of update
%%%      \item but intact with the \xw{version 1}
%%%      \end{itemize}
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99k (2018/12/15)
%%%  \begin{itemize}
%%%  \item introduced |\xtCInfosetO| for bubble type curved information sets
%%%    \begin{itemize}
%%%    \item (internally) added |\xtPrototypeForCInfosetO| -- only for |\xtCInfosetO|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99j (2018/12/11)
%%%  \begin{itemize}
%%%  \item introduced |\xtCInfoset| for curved information sets
%%%    \begin{itemize}
%%%    \item (internally) added |\istgameScaleCallTestAndAdjust| (must be used in a group)
%%%    \item (internally) added |\setxtCIAngleAccordingtoGrowswapCall|
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99i (2018/12/08)
%%%  \begin{itemize}
%%%  \item (macro name change,  effective from \xw{v1.99i}) all `\xw{cntmarc}' changed to `\xw{cntmA}'
%%%  \item introduced |\cntmAInfosetO|
%%%  \item introduced |\cntmAexpostShowEndPoints|
%%%  \item introduced |\istbA(*)| and |\istbAt(*)|
%%%  \end{itemize}
%%%\item v1.99h (2018/11/07)
%%%  \begin{itemize}
%%%  \item changed the default position of a continuum arc from \xw{.5} to \xw{1}
%%%  \item introduced |\cntmarcInfoset|
%%%  \end{itemize}
%%%\item v1.99g (2018/09/30)
%%%  \begin{itemize}
%%%  \item put |\xtShowArrows| and |\xtShowMidArrows| into |\istB|
%%%  \item found issues with |\xtShowArrows| and |\xtShowMidArrows| related to \xw{postaction}
%%%  \item added the arrow end shorten option to |\xtCommentTo| and |\xtCommentFrom|.
%%%  \item (internal) minor changes
%%%    \begin{itemize}
%%%    \item redefined |\setistSolidNodeStyle| to keep consistency with other node styles
%%%    \item redefined |\setistNullNodeStyle| to keep consistency with other node styles
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99f (2018/09/19)
%%%  \begin{itemize}
%%%  \item (internally) redefined |\cntmistb| and |\cntmarcistb| to resolve endpoints problems
%%%  \begin{itemize}
%%%    \item (internally) added |\cntmOUTERistb| and |\cntmarcOUTERistb|
%%%    \item (internally) removed |\cntmendpointsShow| and |\cntmendpointsPrint|
%%%    \item (internally) redefined |\istrootcntm| and its variants accordingly
%%%  \end{itemize}
%%%  \end{itemize}
%%%\item v1.99e (2018/09/15)
%%%  \begin{itemize}
%%%  \item introduced |\xtShowArrows| and |\xtHideArrows(*)|
%%%  \item introduced |\setxtshowarrows|
%%%  \item introduced |\xtShowMidArrows| and |\xtHideMidArrows|
%%%  \end{itemize}
%%%\item v1.99d (2018/09/13)
%%%  \begin{itemize}
%%%  \item introduced |\setxtarrowtips| with a tikzstyle \xw{->-}
%%%  \item introduced new arrow styles: \xw{->>-}, \xw{->>>-}, \xw{-o-}, and \xw{-x-}
%%%  \end{itemize}
%%%\item v1.99c (2018/09/09)
%%%  \begin{itemize}
%%%  \item introduced |\cntmistb| and |\cntmarcistb|
%%%  \item redefined |\cntmdistance| to check if |\cntmactsibdist| is called or not
%%%  \item (internally) added |\cntmendpointsShow|
%%%    \begin{itemize}
%%%    \item redefined |\xtShowEndPoints| and |\xtHideEndPoints| accordingly
%%%    \item introduced |\xtShowEndPoints*| (for outermost branches of a continuum)
%%%    \end{itemize}
%%%  \item (internally) added |\cntmendpointsPrint|
%%%    \begin{itemize}
%%%    \item redefined |\istrootcntm| and its variants accordingly
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.99b (2018/09/07)
%%%  \begin{itemize}
%%%  \item redesigned |\istrootcntm| and its variants
%%%    \begin{itemize}
%%%    \item removed |\ISTCntm(')| and |\ISTCntmArc(')|
%%%    \end{itemize}
%%%  \item introduced |\cntmdraw|, |\cntmdrawset| and related macros
%%%  \item redfined |\cntmdistance| to check if |\cntmactsibdist| is called or not
%%%  \end{itemize}
%%%\item v1.99a (2018/09/05)
%%%  \begin{itemize}
%%%  \item introduced |\setistgameshorten| (for \env{istgame} environment option)
%%%  \end{itemize}
%%%\item v1.98 (2018/09/03)
%%%  \begin{itemize}
%%%  \item redefined |\istrootcntm(arc)| to make it work with |\setistmathTF(*)|
%%%  \item redefined |\istrootocntm(arc)| to make it work with |\setistmathTF(*)|
%%%  \end{itemize}
%%%\item v1.97 (2018/09/02)
%%%  \begin{itemize}
%%%  \item redefined |\istroot(o)| to resolve tex expansion problems
%%%  \item redefined |\istrootcntm(arc)| to resolve tex expansion problems
%%%  \item redefined |\istrootocntm(arc)| to resolve tex expansion problems
%%%  \item redefined the \env{istgame} environment to add \xw{[shorten >=0pt]} if \xw{[->]} exists
%%%  \end{itemize}
%%%\item 1.96 (2018/08/30)
%%%  \begin{itemize}
%%%  \item minor changes
%%%    \begin{itemize}
%%%    \item altered the default sibling distance of |\xtdistance| from \xw{15mm} to \xw{\levdist}
%%%    \item altered initial options for \xw{null}, \xw{solid}, and \xw{hollow} nodes (added \xw{thin}, \xw{solid})
%%%    \item added \xw{text depth=.25ex} for some definitions
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.95 (2018/08/27)
%%%  \begin{itemize}
%%%  \item resolved dimension issues for |\cntmdistance|
%%%  \item added |\xtOwner*|, |\xtActionLabel*|, |\xtPayoff*| (working with |\setistmathTF(*)|)
%%%  \end{itemize}
%%%\item v1.94 (2018/08/22)
%%%  \begin{itemize}
%%%  \item resolved tex expansion issues in the macros for a continuum of branches
%%%  \end{itemize}
%%%\item v1.93 (2018/08/19)
%%%  \begin{itemize}
%%%  \item introduced |\setistmath| to set input mode for owners, action labels, and payoffs
%%%  \item introduced |\setistmath*| to print action labels in italics, in case of text mode
%%%  \item (internally) added |\istownerstyle|, |\istactionlabelstyle|, and |\istpayoffstyle|
%%%  \end{itemize}
%%%\item v1.92 (2018/08/17)
%%%  \begin{itemize}
%%%  \item redesigned the \env{istgame} environment
%%%    \begin{itemize}
%%%    \item to extract the number input from \xw{scale}, \xw{xscale}, or \xw{yscale}
%%%    \item added |\xtscale|, |\xtxscale|, and |\xtyscale| to save scale option values
%%%    \end{itemize}
%%%  \item tested to apply scale values to improve the result of |\xtInfosetO|
%%%  \end{itemize}
%%%\item v1.91 (2018/08/16)
%%%  \begin{itemize}
%%%  \item many changes to resolve expansion problems
%%%    \begin{itemize}
%%%    \item redefined |\cntmset|, |\cntmarcset|, and related macors
%%%    \item redifined |\cntmlevdist| and |\cntmsibdist| as lengths
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.9 (2018/08/11)
%%%  \begin{itemize}
%%%  \item introduced |\cntmarcplotfactorset|
%%%  \end{itemize}
%%%\item v1.8 (2018/08/09)
%%%  \begin{itemize}
%%%  \item made possible to use the directional abbreviations with |\xtInfoset|
%%%  \item introduced |\istrootocntm| and |\istrootocntmarc| (oval versions)
%%%  \end{itemize}
%%%\item v1.7 (2018/08/04)
%%%  \begin{itemize}
%%%  \item introduced |\istbm|
%%%  \item introduced |\setistNewNodeStyle|
%%%  \end{itemize}
%%%\item v1.6 (2018/08/01)
%%%  \begin{itemize}
%%%  \item resigned |\cntmdistance| (now ready for users)
%%%    \begin{itemize}
%%%    \item added |\cntmactsibdist| to distinguish it from |\cntmsibdist|
%%%    \end{itemize}
%%%  \item added |\cntmdistance*| to incorporate with |\xtdistance|
%%%  \item introduced |\istrootcntmA(')|
%%%    \begin{itemize}
%%%    \item added (internally) |\ISTCntmArc(')|
%%%    \item added |\cntmarcset|
%%%    \end{itemize}
%%%  \item introduced |\istrootcntm(')|
%%%    \begin{itemize}
%%%    \item added (internally) |\ISTCntm(')|
%%%    \end{itemize}
%%%  \item (internally) renamed |\istCntmRoot(Arc)| to |\obsoleteISTCntm(Arc)|
%%%  \end{itemize}  
%%%\item v1.5 (2018/07/26)
%%%  \begin{itemize}
%%%  \item introduced |\setxtinfosetlayer|
%%%  \item introduced |\setxtsubgamelayer|
%%%  \end{itemize}
%%%\item v1.4 (2018/07/12)
%%%  \begin{itemize}
%%%  \item completely rewrote |\xtInfosetO| to deal with sloped information sets
%%%    \begin{itemize}
%%%    \item removed |\xtInfosetO'| and |\xtInfoset'| (critical change for users!)
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v1.3 (2018/07/06)
%%%  \begin{itemize}
%%%  \item (internally) renamed some macros (such as |\xt@...|)
%%%  \item (internally) renamed |\xtaction| to |\istaction|
%%%  \item (internally) renamed |\xtpayoff| to |\istpayoff|
%%%  \item (internally) renamed |\istRoot(O)| to |\ISTRoot(O)|
%%%  \end{itemize}
%%%\item v1.2 (2017/12/11)
%%%  \begin{itemize}
%%%  \item replaced |\istb.| by |\istbt| (critical change for users!)
%%%    \begin{itemize}
%%%    \item |\istb| redefined accordingly
%%%    \item this is the cost of introducing |\istB(*)|
%%%    \end{itemize}
%%%  \item introduced |\istB(*)| to deal with dual action labels
%%%  \item added |\istbt(*)| and |\istBt(*)|
%%%  \item added \xw{text depth=.25ex} as an option to |\istroot| and |\istrooto|
%%%  \end{itemize}
%%%\item v1.1 (2017/10/02)
%%%  \begin{itemize}
%%%  \item introduced |\xtCommentTo| and |\xtCommentFrom|
%%%  \item introduced |\xtTimeLineH(')|
%%%  \item redefined |\xtActionLabel| to deal with sloped labels
%%%  \item replaced |\tikzstyle| by |\tikzset|
%%%  \end{itemize}
\item v1.0 (2017/09/04)
  \begin{itemize}
  \item introduced |\cntmlevdist| and |\cntmsibdist|
  \item introduced |\cntmdistance|
  \item redefined related marcos
  \item package document done
  \end{itemize}
%%%\item v1.0 (2017/09/04) ready to submit to CTAN
%%%  \begin{itemize}
%%%  \item introduced |\cntmlevdist| and |\cntmsibdist|
%%%  \item introduced |\cntmdistance| (for internal use)
%%%  \item redefined related marcos.
%%%  \item package document done
%%%  \end{itemize}
%%%\item v0.99g (2017/08/21)
%%%  \begin{itemize}
%%%  \item redefined the \env{istgame} environment to add \xw{>=stealth} as default
%%%  \item added \xw{text depth=.25ex} as an option to |\istb| to get better alignment of action labels
%%%  \end{itemize}
%%%\item v0.99f (2017/08/02)
%%%  \begin{itemize}
%%%  \item redefined |\xtInfosetO(')|
%%%    \begin{itemize}
%%%    \item added \verb+\begin{scope}[on background layer]...\end{scope}+
%%%    \end{itemize}
%%%  \end{itemize}
%%%\item v0.99e (2017/08/01)
%%%  \begin{itemize}
%%%  \item introduced the prime(\xw{'}) versions to deal with \xw{grow'} (this is the swap version in \TikZ)
%%%  \item redefined |\istroot(')|
%%%  \item defined |\istrooto(')| to replace |\istroot*|
%%%    \begin{itemize}
%%%    \item |\istroot*| completely replaced by |\istrooto|
%%%    \end{itemize}
%%%  \item redefinde |\istcntm|
%%%  \item defined |\istcntmarc|
%%%    \begin{itemize}
%%%    \item |\istcntm*| completely replaced by |\istcntmarc|
%%%    \end{itemize}
%%%  \item redefined |\xtInfoset(')| and |\xtInfosetOwner(')|
%%%  \item introduced |\xtInfosetO(')|
%%%    \begin{itemize}
%%%    \item |\xtInfoset*| completely replaced by |\xtInfosetO|
%%%    \end{itemize}
%%%  \item introduced |\xt@growswap| introduced
%%%  \item redefined |\xtNode| accordingly
%%%  \end{itemize}
%%%\item v0.99d (2017/07/27)
%%%  \begin{itemize}
%%%  \item defined |\xtSubgameBox(*)| and |\xtSubgameOval(*)| to express a subgame
%%%  \end{itemize}
%%%\item v0.99c (2017/07/20)
%%%  \begin{itemize}
%%%  \item defined |\xtgrow| to deal with going `clockwise' of branch arrangement
%%%  \item defined |\setxtgrowkey| to change between \xw{grow} and \xw{grow'}
%%%  \item introduced |\setistgrowdirection'| by redefining |\setistgrowdirection|
%%%  \item updated `related macros' accordingly
%%%  \end{itemize}
%%%\item v0.99b (2017/07/16)
%%%  \begin{itemize}
%%%  \item renamed \xw{zero node} as \xw{plain node}
%%%  \item added |\setistPlainNodeStyle|
%%%  \item defined |\xtNode*| (for a terminal node text with a plain node)
%%%  \item redefined |\xt<...>NodeStyle| (now all arguments are optional)
%%%  \item renamed |\isthorizontallabelshift| as |\istactionlabelxshift|, with default \xw{1pt}
%%%  \item renamed |\istverticallabelshift| as |\istactionlabelyshift|, with default \xw{2pt}
%%%  \end{itemize}
%%%\item v0.99a (2017/03/10)
%%%  \begin{itemize}
%%%  \item started rewriting package manual
%%%  \item introduced |\istb.|\ (for terminal nodes)
%%%  \item redefined |\xtShowTerminalNodes|
%%%  \item introduced |\xtShowEndPoints| and |\xtHideEndPoints|
%%%  \item redefined |\xtInfoset*|, with |\xtdefaultinfosep| added
%%%  \end{itemize}
%%%\item v0.9 (2017/02/13)
%%%  \begin{itemize}
%%%  \item some internal macro names changed (|\xtnode|, |\xttnode|,|\xtshowtnode|)
%%%%  \item conflict with \pkg{tikz-qtree} resolved. (\env{istgame} differs from \env{tikzpicture} with \pkg{tikz-qtree})
%%%%  \item |\setistbranchanchors| added
%%%  \item added \xw{zero node}
%%%  \end{itemize}
%%%\item v0.8 (2017/01/17)
%%%  \begin{itemize}
%%%  \item macro names changed
%%%    \begin{itemize}
%%%      \item |\xtdistance|: prefix `\xw{x}' changed to `\xw{xt}' meaning `extensive tree'
%%%      \item |\xtInfoset(*)|, |\xtInfosetOwner|, |\xtActionLabel|, |xtOwner|, |\xtPayoff|, |\xtNode|
%%%      \item |\xtShowTerminalNodes|, |\xtHideTerminalNodes|
%%%      \item |\xtlevdist|, |\xtsibdist|
%%%    \end{itemize}
%%%  \item |\xtNode| redefined
%%%  \item some internal macro names changed (including |\xtpayff|, |\xtmove|)
%%%  \item node styles redefined
%%%  \item |\setist<Solid>NodeStyle| added for <Various> node styles
%%%  \item |\setistdefaultnodecolor|, |setistdefaultnodebgcolor| added
%%%  \end{itemize}
\end{itemize}


\section{Acknowledgement}

The basic idea of the \pkg{istgame} package came from Osborne's \pkg{egameps} package and Chen (2013). 
The update of the package \pkg{istgame} to \xw{version 2.0} is partly motivated by the questions and discussions on the \xw{game tree} topic at \url{https://tex.stackexchange.com/}.
Special thanks go to Kangsoo Kim of KTUG for his great help in using \pkg{expl3} to simplify the appearance and the usage of the macros, and to resolve the issues on \TeX's expansion.


\section{References}
\hpara{}Chen, H.~K.~(2013), ``Drawing Game Trees with \TikZ,'' \url{http://www.sfu.ca/~haiyunc/notes/Game_Trees_with_TikZ.pdf}.

\hpara{}Cho, I-S.~(2017), ``\pkg{istgame}: Drawing Game Trees with \TikZ,'' in Korean TeX Society, \emph{\TeX, Beyond the World of Typesetting}, Seoul: Kyungmoonsa, 203--237.

\hpara{}Osborne, M.~J.~(2004a), ``Manual for \pkg{egameps.sty},'' Version 1.1, \url{http://texdoc.net/texmf-dist/doc/latex/egameps/egameps.pdf}

\hpara{}\uline{\hphantom{Osborne, M.~J}}~(2004b), \emph{An Introduction to Game Theory}, New York: Oxford.

\hpara{}Tantau, T.~(2021), ``\TikZ\ and PGF: Manual for version 3.1.9a,'' \url{http://sourceforge.net/projects/pgf}.

%\section*{Discussions (in Korean) on KTUG board}
%
%\begin{itemize}
%\item Drawing Game Trees 1: \url{http://www.ktug.org/xe/index.php?document_srl=207287}
%
%\item Drawing Game Trees 1-1: \url{http://www.ktug.org/xe/index.php?document_srl=207513}
%
%\item Drawing Game Trees 1-2:
%\url{http://www.ktug.org/xe/index.php?document_srl=208286}
%
%\item Drawing Game Trees 2: \url{http://www.ktug.org/xe/index.php?document_srl=212043}
%
%\item Drawing Game Trees 2-1:
%\url{http://www.ktug.org/xe/index.php?document_srl=212225}
%
%\item Drawing Game Trees 2-2:
%\url{http://www.ktug.org/xe/index.php?document_srl=212319}
%\end{itemize}

\clearpage
\printindex

\end{document}