PowerTools InputMan for Windows Forms 8.0J
ShowItemImage プロパティ
使用例 

先頭カラムに画像を表示するかしないかを取得または設定します。
構文
Public Property ShowItemImage As Boolean
public bool ShowItemImage {get; set;}

プロパティ値

説明
True 画像を表示します。
False 画像を表示しません。

既定値はFalseです。
解説
ShowItemImage プロパティは、先頭カラムに画像を表示するかどうかを指定します。
使用例
外観を設定した GcListBox コントロールを作成するコード例を次に示します。この例では他に GradientEffectItemImageAlignItemImageWidth、 ShowItemImage、 ShowCheckBoxThreeDCheckBoxes プロパティを使用しています。
//  Please use the following namespace
//  using System.Windows.Forms;
//  using GrapeCity.Win.Editors;

public void SetAppearanceSettings()
{
    // Creates the GcListBox control.
    GcListBox gcListBox1 = new GcListBox();

    // Creates the GradientEffect.
    GradientEffect gradienteffect = new GradientEffect();
    gradienteffect.Direction = GrapeCity.Win.Editors.GradientDirection.Side;
    gradienteffect.EndColor = System.Drawing.Color.FromArgb(224, 224, 224);

    // Sets the GradientEffect to the control.
    gcListBox1.GradientEffect = gradienteffect;

    // Sets the image of the item settings.
    gcListBox1.ItemImageAlign = System.Windows.Forms.HorizontalAlignment.Center;
    gcListBox1.ItemImageWidth = 30;
    gcListBox1.ShowItemImage = true;

    // Sets the check box settings for displaying the check box of ListItem.
    gcListBox1.ShowCheckBox = true;
    gcListBox1.ThreeDCheckBoxes = true;
}
'  Please use the following namespace
'  Imports System.Windows.Forms;
'  Imports GrapeCity.Win.Editors;

Public Sub SetAppearanceSettings()
    ' Creates the GcListBox control.
    Dim gcListBox1 As New GcListBox()

    ' Creates the GradientEffect.
    Dim gradienteffect As New GradientEffect()
    gradienteffect.Direction = GrapeCity.Win.Editors.GradientDirection.Side
    gradienteffect.EndColor = System.Drawing.Color.FromArgb(224, 224, 224)

    ' Sets the GradientEffect to the control.
    gcListBox1.GradientEffect = gradienteffect

    ' Sets the image of the item settings.
    gcListBox1.ItemImageAlign = System.Windows.Forms.HorizontalAlignment.Center
    gcListBox1.ItemImageWidth = 30
    gcListBox1.ShowItemImage = True

    ' Sets the check box settings for displaying the check box of ListItem.
    gcListBox1.ShowCheckBox = True
    gcListBox1.ThreeDCheckBoxes = True
End Sub
参照

GcListBox クラス
GcListBox メンバ

 

 


© 2004-2015 GrapeCity inc. All rights reserved.