BitmapImage
Provides image data from a stream or an embedded resource for Spreadsheet rendering.
Definition
Namespace:Telerik.WinControls.Spreadsheet.UI
Assembly:Telerik.WinControls.RadSpreadsheet.dll
Syntax:
public sealed class BitmapImage : BitmapSource
Inheritance: objectBitmapSourceBitmapImage
Constructors
Creates an empty bitmap source.
public BitmapImage()
Assign StreamSource or UriSource before using the image.
Loads an embedded bitmap resource identified by the URI's original string.
public BitmapImage(Uri uri)
A URI whose OriginalString is the manifest resource name in the assembly containing BitmapSource.
The resource is copied into a memory stream; this constructor does not resolve file paths or network URIs.
Properties
Gets or sets WPF-compatible creation-option flags.
public BitmapCreateOptions CreateOptions { get; set; }
The flags are stored but do not affect resource lookup or image decoding in this implementation.
Gets the decoded image height in pixels.
public int PixelHeight { get; }
Gets the decoded image width in pixels.
public int PixelWidth { get; }
Gets or sets the stream used to decode the bitmap.
public Stream StreamSource { get; set; }
Assigning a non-null stream reads its dimensions through GDI+ and retains the same stream for later image use. Exceptions other than InvalidOperationException raised while decoding are wrapped in NotSupportedException.
Gets or sets the URI used to locate an embedded bitmap resource.
public Uri UriSource { get; set; }
Setting this property copies the resource named by OriginalString from the assembly containing BitmapSource into StreamSource.