Ribbon for WinForms
GetPresetImage(String,Int32,Boolean) メソッド

C1.Win.Ribbon.4.5.2 アセンブリ > C1.Win.Ribbon 名前空間 > C1Ribbon クラス > GetPresetImage メソッド : GetPresetImage(String,Int32,Boolean) メソッド
The icon key.
The icon size
Determines whether the icons are dark or not.
Returns a bitmap image from build-in C1Ribbon presets.
シンタックス
'宣言
 
Public Overloads Function GetPresetImage( _
   ByVal key As String, _
   ByVal size As Integer, _
   ByVal isDarkTheme As Boolean _
) As Image
public Image GetPresetImage( 
   string key,
   int size,
   bool isDarkTheme
)

パラメータ

key
The icon key.
size
The icon size
isDarkTheme
Determines whether the icons are dark or not.

戻り値の型

The bitmap image from build-in C1Ribbon preset. If image with specified key is not found, returns null. If image with specified size is not found, returns the most appropriate image resized to the specified size.
解説
You have item with a icon from build-in preset: ribbonButton1.IconSet.Add(new C1.Framework.C1BitmapIcon("Book", new System.Drawing.Size(32, 32), System.Drawing.Color.Transparent, "Preset_LargeImages", 22)); You can get this image: var bookImage = c1ribbon.GetPressetImage(ribbonButton1.IconSet[1].Key, 32); The C1Ribbon contains 16px, 20px and 32px build-in presets.
参照

C1Ribbon クラス
C1Ribbon メンバ
オーバーロード一覧