[]
        
(Showing Draft Content)

GrapeCity.Documents.Excel.Drawing.IBackgroundPicture.BackgroundImageLayout

BackgroundImageLayout Property

BackgroundImageLayout

Gets or sets a value that describes how an image should be stretched to fill the destination rectangle.

The returned ImageLayout value controls how the background picture is arranged within its destination rectangle, such as centered, stretched, zoomed, or tiled.

Declaration
ImageLayout BackgroundImageLayout { get; set; }
Property BackgroundImageLayout As ImageLayout
Examples
IBackgroundPictures backgroundPictures = worksheet.BackgroundPictures;
IBackgroundPicture picture = null;
using (MemoryStream stream = CreateSampleImageStream())
{
    picture = backgroundPictures.AddPicture(stream, ImageType.PNG, 12, 18, 120, 80);
}
picture.BackgroundImageLayout = ImageLayout.Center;
ImageLayout layout = picture.BackgroundImageLayout;