Hello,
I recently made a post about TextBlock.shadowOffset not scaling properly when added to an AdvancedDynamicTexture that has and ideal size set.
(Shadow offset of a textBlock doesn't scale properly with AdvancedDynamicTexture that has an ideal size)
I found another issue similar to that one, this time regarding StackPanel and spacing. Since the other issue was a bug with the engine, I’m inclined to believe this one is as well.
I created a playground replicating the issue: https://playground.babylonjs.com/#B6DRYU#2
Thanks