is a symbol that can appear at a particular position in a Grid or related construct to indicate that the corresponding position is occupied by a spanning element that appears to its left.
SpanFromLeft
is a symbol that can appear at a particular position in a Grid or related construct to indicate that the corresponding position is occupied by a spanning element that appears to its left.
Details
- If SpanFromLeft appears at several successive positions in a row, it indicates spanning across all these positions.
Examples
open all close allBasic Examples (4)
Make the element 4 span the column to its right:
Grid[{{1, 2, 3}, {4, SpanFromLeft, 6}, {7, 8, 9}}, Frame -> All]Grid[{{1, 2, 3}, {4, SpanFromLeft, SpanFromLeft}, {7, 8, 9}}, Frame -> All]Span across the remaining width of the grid:
Grid[{{1, 2, 3, 4}, {5, SpanFromLeft}, {6, 7, 8, 9}}, Frame -> All]Spanning in a GraphicsGrid:
GraphicsGrid[{{1, 2, 3}, {4, SpanFromLeft, SpanFromLeft}, {7, 8, 9}}, Frame -> All]Scope (2)
Spanned elements inherit their styles:
Grid[{{1, 2, 3}, {Item[4, Background -> Red], SpanFromLeft, SpanFromLeft}, {7, 8, 9}},
Frame -> All]Grid[{{1, 2, 3}, {4, SpanFromLeft, SpanFromLeft}, {7, 8, 9}},
Frame -> All, Background -> {Automatic, Automatic, {2, 1} -> Red}]Graphics will default to filling the available space:
GraphicsGrid[{{Graphics[Rectangle[]], Graphics[Rectangle[]]}, {Graphics[Rectangle[], AspectRatio -> .5], SpanFromLeft}}]An explicit ImageSize setting will prevent this behavior:
GraphicsGrid[{{Graphics[Rectangle[], ImageSize -> {100, 100}], Graphics[Rectangle[], ImageSize -> {100, 100}]}, {Graphics[Rectangle[], AspectRatio -> .5, ImageSize -> {100, 100}], SpanFromLeft}}]Possible Issues (2)
Spanning regions must be rectangular in shape:
Grid[{{1, SpanFromLeft, 3}, {4, SpanFromAbove, 6}, {7, 8, 9}}, Frame -> All]Use SpanFromBoth when spanning across both columns and rows:
Grid[{{1, SpanFromLeft, 3}, {SpanFromAbove, SpanFromBoth, 6}, {7, 8, 9}}, Frame -> All]See Also
Tech Notes
Related Guides
Related Workflows
- Put Graphics in a Grid ▪
- Make a Grid of Output Data
History
Text
Wolfram Research (2007), SpanFromLeft, Wolfram Language function, https://reference.wolfram.com/language/ref/SpanFromLeft.html.
CMS
Wolfram Language. 2007. "SpanFromLeft." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/SpanFromLeft.html.
APA
Wolfram Language. (2007). SpanFromLeft. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/SpanFromLeft.html
BibTeX
@misc{reference.wolfram_2026_spanfromleft, author="Wolfram Research", title="{SpanFromLeft}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/SpanFromLeft.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_spanfromleft, organization={Wolfram Research}, title={SpanFromLeft}, year={2007}, url={https://reference.wolfram.com/language/ref/SpanFromLeft.html}, note=[Accessed: 13-June-2026]}