BitmapImage.CreateOptions 속성

정의

BitmapCreateOptionsBitmapImage를 가져오거나 설정합니다.

public:
 property System::Windows::Media::Imaging::BitmapCreateOptions CreateOptions { System::Windows::Media::Imaging::BitmapCreateOptions get(); void set(System::Windows::Media::Imaging::BitmapCreateOptions value); };
public System.Windows.Media.Imaging.BitmapCreateOptions CreateOptions { get; set; }
member this.CreateOptions : System.Windows.Media.Imaging.BitmapCreateOptions with get, set
Public Property CreateOptions As BitmapCreateOptions

속성 값

BitmapCreateOptions

BitmapCreateOptions에 사용되는 BitmapImage입니다. 기본값은 None입니다.

예제

다음 코드 예제에서는 설정 하는 방법에 설명 합니다 CreateOptionsBitmapImage 코드를 사용 하 여 합니다.

// Define a BitmapImage.
Image myImage = new Image();
BitmapImage bi = new BitmapImage();

// Begin initialization.
bi.BeginInit();

// Set properties.
bi.CacheOption = BitmapCacheOption.OnDemand;
bi.CreateOptions = BitmapCreateOptions.DelayCreation;
bi.DecodePixelHeight = 125;
bi.DecodePixelWidth = 125;
bi.Rotation = Rotation.Rotate90;
MessageBox.Show(bi.IsDownloading.ToString());
bi.UriSource = new Uri("smiley.png", UriKind.Relative);

// End initialization.
bi.EndInit();
myImage.Source = bi;
myImage.Stretch = Stretch.None;
myImage.Margin = new Thickness(5);
' Define a BitmapImage.
Dim myImage As New Image()
Dim bi As New BitmapImage()

' Begin initialization.
bi.BeginInit()

' Set properties.
bi.CacheOption = BitmapCacheOption.OnDemand
bi.CreateOptions = BitmapCreateOptions.DelayCreation
bi.DecodePixelHeight = 125
bi.DecodePixelWidth = 125
bi.Rotation = Rotation.Rotate90
MessageBox.Show(bi.IsDownloading.ToString())
bi.UriSource = New Uri("smiley.png", UriKind.Relative)

' End initialization.
bi.EndInit()
myImage.Source = bi
myImage.Stretch = Stretch.None
myImage.Margin = New Thickness(5)

설명

종속성 속성 정보

식별자 필드 CreateOptionsProperty
메타 데이터 속성 설정 true 없음

적용 대상

추가 정보