I've often wanted to set the size of an interface element to something like Full - 50
, so as to not over-constrain box sizes.
One approach to this would be to simply use a Dynamic[boxsize - 50]
as my ImageSize
.
Unfortunately, for boxes that information isn't possible to extract by normal means.
I've always resorted to hacks and workarounds, but I don't see what that info shouldn't be possible to extract from the FE.
In digging I found FrontEnd`GetBoundingBoxSizePacket
, but it always returns one of two things. Either it gives:
FrontEndExecute[FrontEnd`GetBoundingBoxSizePacket@EvaluationCell[]]
{{34., 13., 7.}}
Or
FrontEndExecute[FrontEnd`GetBoundingBoxSizePacket@1]
$Failed
No matter what FE object I pass to it, it only ever returns one size.
Does anyone know can I get the size of a BoxObject
?