Re: Fixing padding inside Inset

*To*: mathgroup at smc.vnet.net*Subject*: [mg114954] Re: Fixing padding inside Inset*From*: Leonid Shifrin <lshifr at gmail.com>*Date*: Fri, 24 Dec 2010 04:11:10 -0500 (EST)*References*: <201012230851.DAA04731@smc.vnet.net>

Hi Yaroslav, This works for me: gr2 = Graphics[ Inset[gr1 /. (ImageSize -> x_) :> (ImageSize -> x*0.9)], ImageSize -> 160, ImagePadding -> 0, ImageMargins -> 0, PlotRangePadding -> 0] although it is not identical in size, inset image is made slightly smaller. Regards, Leonid On Thu, Dec 23, 2010 at 11:51 AM, Yaroslav Bulatov <yaroslavvb at gmail.com>wrote: > Below I have a Graphics3D and a corresponding Graphics using Inset > command. The box in Inset graphics is slightly larger and is cut off. > I can't seem to get them to display identically, any suggestions? > > shape = {Opacity[0.5], > GraphicsComplex[{{-1., 0., 0.}, {0., -1., 0.}, {0., 0., -1.}, {0., > 0., 1.}, {0., 1., 0.}, {1., 0., > 0.}}, {{{EdgeForm[GrayLevel[0.]], > GraphicsGroup[{Polygon[{{4, 5, 1}, {1, 5, 3}, {1, 3, 2}, {4, 1, > 2}, {3, 5, 6}, {5, 4, 6}, {4, 2, 6}, {2, 3, > 6}}]}]}, {}, {}, {}, {}}}]}; > gr1 = Graphics3D[shape, ImageSize -> 160, > PlotRange -> {{-1, 1}, {-1, 1}, {-1, 1}}, ImageMargins -> 0, > PlotRangePadding -> 0, ImagePadding -> 0] > gr2 = Graphics[Inset[gr1], ImageSize -> 160, ImagePadding -> 0, > ImageMargins -> 0, PlotRangePadding -> 0] > >

**References**:**Fixing padding inside Inset***From:*Yaroslav Bulatov <yaroslavvb@gmail.com>