Debian Codegraph @

texmf-dist/doc/latex/onedown/Examples/showNS-warn-II.tex

raw
1 \documentclass[onedown-examples]{subfiles}
2 \begin{document}
3 In the previous example we enabled warnings and set a much smaller font to
4 make the example fit on the page. As we compile these examples as one big
5 file, \OneDown remembers these values. If you compile this file
6 (showNS-warn-II) standalone with |pdflatex showNS-warn-II| and view the
7 result, then you'll see no warnings and no shrinking.
8
9 \vfill
10 \begin{HBox}{showNS \hfill File: \FileName}
11 \northhand{KJ92}{KQ9}{J}{AQJT8}
12 \southhand{AQT85}{A52}{64}{K96}
13 \showNS
14 \end{HBox}
15 %
16 \vfill
17 \needspace{8\baselineskip}
18 \vfill
19 Now warnings are switched off explicitly and the size is reset by calling
20 |\resetfonts|.
21 \vfill
22 \begin{HBox}{showNS \hfill File: \FileName}
23 \setdefaults{warn=off}
24 \resetfonts
25 \showNS
26 \end{HBox}
27 %
28 \vfill
29 |\newgame| clears the hands. A hand with no cards at all is completely
30 suppressed, so we see only the compass. With |\setdefaults{compmid=text}|
31 we can write 'text' in the middle of the compass. We enlarged the compass,
32 so you can see that it \emph{is} on the vertical line through the mids of
33 \North*! and \South*!. With |\resetfonts| we return to the default values
34 of the fonts. With |\setdefaults| one can influence the look of diagrams.
35 In section |Compass| we'll go more into detail. Please note that |\setdefaults| has
36 only 1 argument, It is \emph{mandatory} and must be enclosed in
37 braces (|{...}|). The argument is a key-val list, separated by commas. I.e. rather
38 than |\setdefaults{warn=off}\setdefaults{compmid=15}| one can also write
39 |\setdefaults{warn=off,compmid=15}|.
40 \vfill
41 \begin{HBox}{showNS \hfill File: \FileName}
42 \newgame
43 \raggedright
44 \setdefaults{compmid=15}
45 \showNS
46 \showNS
47 \gamefont{\sffamily\bfseries\Huge}
48 \showNS
49 \resetfonts
50 \setdefaults{compmid=}
51 \showNS
52 \gamefont{\smaller\smaller}
53 \showNS
54 \end{HBox}
55 \vfill
56 %
57 \end{document}
58 \endinput
59