ToolStripItemImageScaling 列挙体とは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > ToolStripItemImageScaling 列挙体の意味・解説 

ToolStripItemImageScaling 列挙体

メモ : この列挙体は、.NET Framework version 2.0新しく追加されたものです。

ToolStripItem 上のイメージサイズを、元のイメージ比率維持しながら、ToolStrip に合わせて自動的に調節するかどうか指定します

名前空間: System.Windows.Forms
アセンブリ: System.Windows.Forms (system.windows.forms.dll 内)
構文構文

Public Enumeration ToolStripItemImageScaling
Dim instance As ToolStripItemImageScaling
public enum ToolStripItemImageScaling
public enum class ToolStripItemImageScaling
public enum ToolStripItemImageScaling
public enum ToolStripItemImageScaling
メンバメンバ
解説解説
使用例使用例

SizeToFit メンバを ToolStripButton に適用するコード例次に示します

Friend WithEvents imageButton As
 ToolStripButton

Private Sub InitializeImageButtonWithToolTip()

    ' Construct the button and set the image-related properties.
    imageButton = New ToolStripButton()
    imageButton.Image = New Bitmap(GetType(Timer),
 "Timer.bmp")
    imageButton.ImageScaling = ToolStripItemImageScaling.SizeToFit

    ' Set the background color of the image to be transparent.
    imageButton.ImageTransparentColor = Color.FromArgb(0, 255, 0)

    ' Show ToolTip text, set custom ToolTip text, and turn
    ' off the automatic ToolTips.
    toolStrip1.ShowItemToolTips = True
    imageButton.ToolTipText = "Click for the current time"
    imageButton.AutoToolTip = False

    ' Add the button to the ToolStrip.
    toolStrip1.Items.Add(imageButton)

End Sub
internal ToolStripButton imageButton;

private void InitializeImageButtonWithToolTip()
{

    // Construct the button and set the image-related properties.
    imageButton = new ToolStripButton();
    imageButton.Image = new Bitmap(typeof(Timer), "Timer.bmp");
    imageButton.ImageScaling = ToolStripItemImageScaling.SizeToFit;

    // Set the background color of the image to be transparent.
    imageButton.ImageTransparentColor = Color.FromArgb(0, 255, 0);

    // Show ToolTip text, set custom ToolTip text, and turn
    // off the automatic ToolTips.
    toolStrip1.ShowItemToolTips = true;
    imageButton.ToolTipText = "Click for the current time";
    imageButton.AutoToolTip = false;

    // Add the button to the ToolStrip.
    toolStrip1.Items.Add(imageButton);

}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照



英和和英テキスト翻訳>> Weblio翻訳
英語⇒日本語日本語⇒英語
  

辞書ショートカット

すべての辞書の索引

ToolStripItemImageScaling 列挙体のお隣キーワード
検索ランキング

   

英語⇒日本語
日本語⇒英語
   



ToolStripItemImageScaling 列挙体のページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

   
日本マイクロソフト株式会社日本マイクロソフト株式会社
© 2025 Microsoft.All rights reserved.

©2025 GRAS Group, Inc.RSS