CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutSign UpSign In

Real-time collaboration for Jupyter Notebooks, Linux Terminals, LaTeX, VS Code, R IDE, and more,
all in one place.

| Download

GAP 4.8.9 installation with standard packages -- copy to your CoCalc project to get it

Views: 418346
1
<?xml version="1.0" encoding="UTF-8"?>
2
3
<Chapter Label="options">
4
<Heading>
5
The <Package>IntPic</Package> package options.
6
</Heading>
7
<Section>
8
<Heading>Available options</Heading>
9
The list of allowed options, some of which already familiar from the examples, can be obtained as follows:
10
<Example><![CDATA[
11
gap> RecNames(IP_TikzDefaultOptionsForArraysOfIntegers);
12
[ "other", "colors", "highlights", "shape_only", "colsep", "rowsep",
13
"cell_width", "allow_adjust_cell_width", "scale", "inner_sep",
14
"line_width", "line_color" ]
15
]]></Example>
16
Its meaning is as follows:
17
<List>
18
<Item>
19
<A>colors</A>: any list of colors (to be used with the &LaTeX; package <Package>xcolor</Package>)
20
</Item>
21
<Item>
22
<A>highlights</A>: a list of lists of integers -- the elements of the first are colored by using the first color, etc. In cases of elements that appear in more than one list a kind of gradient (made with 4 colors at most) is used to fill the cell; the number may be printed with a fifth color and a sixt color may be used for the border.
23
</Item>
24
<Item>
25
<A>shape_only</A>: an option to be used when only the shape is important. When <A>true</A> or " " is used, all the nodes are empty; using a symbol, for instance a <M>*</M>, this symbol is printed in all the nodes.
26
</Item>
27
<Item>
28
<A>colsep</A>: the <Package>tikz</Package> matrix option <A>column sep</A>
29
</Item>
30
<Item>
31
<A>rowsep</A>: the <Package>tikz</Package> matrix option <A>row sep</A>
32
</Item>
33
<Item>
34
<A>cell_width</A>: the <Package>tikz</Package> matrix option <A>minimum width</A>
35
</Item>
36
<Item>
37
<A>scale</A>: the <Package>tikz</Package> matrix option <A>scale</A>
38
</Item>
39
<Item>
40
<A>inner_sep</A>: the <Package>tikz</Package> matrix option <A>inner sep</A>
41
</Item>
42
<Item>
43
<A>line_width</A>: the <Package>tikz</Package> matrix option <A>line width</A>
44
</Item>
45
<Item>
46
<A>line_color</A>: the <Package>tikz</Package> matrix option <A>line color</A>: the color of the cell borders
47
</Item>
48
<Item>
49
<A>allow_adjust_cell_width</A>: the number of points per digit (to avoid discrepancies between the width of the cells when there are numbers with different number of digits to be printed). When the user sets the option cell_width, then allow_adjust_cell_width is automatically set to <A>false</A>
50
</Item>
51
<Item>
52
<A>other</A>: if non empty, the complete <C>tikz</C> code has to be written (it may be useful when several images are to be produced - otherwise, changing the <C>tikz</C> code would be enough)
53
<Example><![CDATA[
54
other := ["\\draw[postaction={draw,line width=1pt,red}] (-80pt,-8pt)
55
rectangle (16pt,40pt);","\\draw[postaction={draw,line width=1pt,blue}]
56
(-16pt,8pt) rectangle (80pt,-40pt);"]]]></Example>
57
</Item>
58
</List>
59
Adding this option to one of the preceding examples, one obtains the following:
60
<Alt Only="LaTeX">
61
\begin{center}
62
\includegraphics[width=0.80\textwidth]{../images/table_axis_ground_shape_other_option}
63
\end{center}
64
</Alt>
65
<Alt Only="HTML">
66
&#60;br&#62;&#60;center&#62;&#60;img src=&#34;../images/table_axis_ground_shape_other_option.jpg&#34;&#62;&#60;/center&#62;&#60;br&#62;
67
</Alt>
68
69
</Section>
70
<Section><Heading>Default options</Heading>
71
The defaults for the available options are as follows
72
<List>
73
<Item> <A>colors</A>: <![CDATA[ShuffledIP_colors]]></Item>
74
<Item>
75
<A>highlights</A>: <![CDATA[ [[]] ]]>
76
</Item>
77
<Item>
78
<A>shape_only </A>: <![CDATA["false"]]>
79
</Item>
80
<Item>
81
<A>colsep</A>: <![CDATA["2"]]>
82
</Item>
83
<Item>
84
<A>rowsep</A>: <![CDATA["2"]]>
85
</Item>
86
<Item>
87
<A>cell_width</A>: <![CDATA["30"]]>
88
</Item>
89
<Item>
90
<A>scale</A>: <![CDATA["1"]]>
91
</Item>
92
<Item>
93
<A>inner_sep</A>: <![CDATA["3"]]>
94
</Item>
95
<Item>
96
<A>line_width</A>: <![CDATA["0"]]>
97
</Item>
98
<Item>
99
<A>line_color</A>: <![CDATA["black"]]>
100
</Item>
101
<Item>
102
<A>allow_adjust_cell_width</A>: <![CDATA["10"]]>
103
</Item>
104
<Item>
105
<A>other</A>: <![CDATA[[]]]></Item>
106
</List>
107
108
They may be consulted:
109
<Example><![CDATA[
110
gap> IP_TikzDefaultOptionsForArraysOfIntegers;
111
rec( allow_adjust_cell_width := "10", cell_width := "30",
112
colors := [ "red", "green", "blue", "-red", "-green", "-blue", "black!80",
113
"black!30", "red!50", "green!50", "blue!50", "-red!50", "-green!50",
114
"-blue!50", "black!70", "black!25", "red!20", "green!20", "blue!20",
115
"-red!20", "-green!20", "-blue!20", "black!60", "black!20",
116
"red!80!green!50", "green!80!red!50", "blue!80!red!50",
117
"-red!80!green!50", "-green!80!red!50", "-blue!80!red!50", "black!50",
118
"black!15", "red!80!blue!60", "green!80!blue!60", "blue!80!green!60",
119
"-red!80!blue!60", "-green!80!blue!60", "-blue!80!green!60",
120
"black!40", "black!10" ], colsep := "2", highlights := [ [ ] ],
121
inner_sep := "3", line_color := "black", line_width := "1", other := [ ],
122
rowsep := "2", scale := "1", shape_only := "false" )
123
]]>
124
</Example>
125
126
The user may want to change the defaults by editing the file <C>options.gd</C> in the folder <C>gap</C>. The changes are lost whenever any re-installation occurs. It is recommended that in this case a copy is made, although it is not guaranteed that it will work in the next release.
127
</Section>
128
</Chapter>
129
130