Timeline for Spanning horizontally and vertically in Grid
Current License: CC BY-SA 4.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jun 13, 2023 at 14:43 | history | edited | Michael E2 |
edited tags
|
|
Jul 25, 2018 at 23:20 | comment | added | Chris Wilson | Well said! Should we submit a bug? | |
Jul 25, 2018 at 23:04 | vote | accept | Chris Wilson | ||
Jul 25, 2018 at 15:00 | history | tweeted | twitter.com/StackMma/status/1022134461939560448 | ||
Jul 25, 2018 at 1:38 | comment | added | John Fultz |
It is a bug, but this description doesn't quite characterize it correctly. The problem isn't that a vertical spanning member can't properly span. Changing Alignment shows this. @ChrisWilson misses seeing this in part because of an extra newline at the end...try wrapping Framed around the Style or using Bottom alignment. What it cannot do is to calculate the required height of the first row correctly. It apportions to the first row enough pixels to hold everything, although it could have subtracted the number of vertical pixels in the second row.
|
|
Jul 24, 2018 at 22:20 | answer | added | X. Wang | timeline score: 5 | |
Jul 23, 2018 at 16:41 | comment | added | Kuba | This is what I see - link. But I wouldn't be surprised by another bug of Grid, just want to make sure it is clear. | |
Jul 23, 2018 at 16:28 | comment | added | Chris Wilson |
FWIW, this works fine if you replace Grid with GraphicsGrid . Seems like a bug to me.
|
|
Jul 23, 2018 at 15:57 | comment | added | Chris Wilson |
Even with the alignment, the content of the right-most box never stretches to the second row. Here's the same thing with four "4"s: Grid[{{Style["1", FontSize -> 30], SpanFromLeft, Style["4\n4\n4\n4\n", FontSize -> 30]}, {Style["2", FontSize -> 30], Style["3", FontSize -> 30], SpanFromAbove}}, Frame -> All, Spacings -> {3, 3}, Alignment -> {Center, Center}]
|
|
Jul 23, 2018 at 15:54 | comment | added | Kuba |
I'm not sure what do you mean, is the height of the first item the problem? Because except that size issue everything seems ok, with Alignment -> {Center, Center} you can see that the item with 4s is streched. Or did I miss the point? Grid[{{Style["1", FontSize -> 30], SpanFromLeft, Style["4\n4", FontSize -> 30]}, {Style["2", FontSize -> 30], Style["3", FontSize -> 30], SpanFromAbove}}, Frame -> All, Spacings -> {3, 3}, Alignment -> {Center, Center}]
|
|
Jul 23, 2018 at 15:48 | history | asked | Chris Wilson | CC BY-SA 4.0 |