Spacings
Details
- For Grid and Column , settings for Spacings are in units of the current font size.
- For GraphicsGrid , GraphicsColumn , and GraphicsRow , settings are in printer's points.
- A setting of the form Scaled [s] gives spacing that is a fraction s of the size of an item.
- A setting of the form Spacings->v specifies that the absolute space between items should be v, independent of the presence of frames or dividers. A setting of the form Offset [v] inserts space v beyond space taken by frames or dividers.
- Settings for Spacings in Grid and related constructs can be given as:
-
{specx,specy} use the speci at successive x and y positions
- For a grid with n items in a particular direction, Spacings can specify settings for spacings in the n+1 gaps between items, starting before the first item, and ending after the last item.
- The outer edge of the grid is taken to be at the midpoint of the outermost spacing on every side.
- The speci in each direction can have the following forms:
-
{s1,s2,…,sn} use s1 through sn, then use defaults{{c}} use c in all cases{{c1,c2}} alternate between c1 and c2{{c1,c2,…}} cycle through all ci{s,{c}} use s, then repeatedly use c{s1,{c},sn} use s1, then repeatedly use c, but use sn at the end{ s 1 , s 2 , … , { c 1 , c 2 , … }, s m , … , s n }use the first sequence of si at the beginning, then cyclically use the ci, then use the last sequence of si at the end{s1,s2,…,{},sm,…,sn} use the first sequence of si at the beginning and the last sequence at the end{i1->v1,i2->v2,…} specify what to use at positions ik{spec,rules} use rules to override specifications in spec
Examples
open all close allBasic Examples (2)
Set the horizontal spacing between items:
Set the horizontal and vertical spacings:
Scope (5)
Insert no additional space between columns:
Insert no additional space between rows or columns:
Use Offset to indicate spacings in addition to the thickness of any frames or dividers:
Insert additional space at the second horizontal divider:
Set the size of the grid's margins:
See Also
Tech Notes
Related Guides
History
Text
Wolfram Research (2007), Spacings, Wolfram Language function, https://reference.wolfram.com/language/ref/Spacings.html.
CMS
Wolfram Language. 2007. "Spacings." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Spacings.html.
APA
Wolfram Language. (2007). Spacings. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Spacings.html
BibTeX
@misc{reference.wolfram_2025_spacings, author="Wolfram Research", title="{Spacings}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/Spacings.html}", note=[Accessed: 04-January-2026]}
BibLaTeX
@online{reference.wolfram_2025_spacings, organization={Wolfram Research}, title={Spacings}, year={2007}, url={https://reference.wolfram.com/language/ref/Spacings.html}, note=[Accessed: 04-January-2026]}