DrawToolTipEventArgs.DrawBackground メソッドとは? わかりやすく解説

Weblio 辞書 > コンピュータ > .NET Framework クラス ライブラリ リファレンス > DrawToolTipEventArgs.DrawBackground メソッドの意味・解説 

DrawToolTipEventArgs.DrawBackground メソッド

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

システム背景色使用してToolTip背景描画ます。

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

Public Sub DrawBackground
Dim instance As DrawToolTipEventArgs

instance.DrawBackground
public void DrawBackground ()
public:
void DrawBackground ()
public void DrawBackground ()
public function DrawBackground ()
解説解説
使用例使用例

ToolTipカスタム描画する方法次のコード例示します。この例では、ToolTip作成しForm 上にある 3 つの Button コントロール関連付けています。また、OwnerDraw プロパティtrue設定しDraw イベント処理してます。Draw イベント ハンドラでは、どのボタンToolTip表示されるかをDrawToolTipEventArgs.AssociatedControl プロパティ指定し、それによって ToolTipカスタム描画されます。

DrawBorder、DrawBackground、および DrawText の各メソッド使用方法次のコード例抜粋示しますコード例全体については、DrawToolTipEventArgs クラス概要参照してください

ElseIf (e.AssociatedControl Is button3) Then
    ' Draw the ToolTip using default values if the ToolTip is for button3.
    e.DrawBackground()
    e.DrawBorder()
    e.DrawText()
End If
// Draw the ToolTip using default values if the ToolTip is for button3.
else if (e.AssociatedControl == button3)
{
    e.DrawBackground();
    e.DrawBorder();
    e.DrawText();
}
// Draw the ToolTip using default values if the ToolTip is for button3.
else if ( e->AssociatedControl == button3
 )
{
   e->DrawBackground();
   e->DrawBorder();
   e->DrawText();
}
// Draw the ToolTip using default values if the ToolTip is
// for button3.
else {
    if (e.get_AssociatedControl().Equals(button3)) {
        e.DrawBackground();
        e.DrawBorder();
        e.DrawText();
    }
}
プラットフォームプラットフォーム
バージョン情報バージョン情報
参照参照
関連項目
DrawToolTipEventArgs クラス
DrawToolTipEventArgs メンバ
System.Windows.Forms 名前空間



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

辞書ショートカット

すべての辞書の索引

DrawToolTipEventArgs.DrawBackground メソッドのお隣キーワード
検索ランキング

   

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



DrawToolTipEventArgs.DrawBackground メソッドのページの著作権
Weblio 辞書 情報提供元は 参加元一覧 にて確認できます。

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

©2024 GRAS Group, Inc.RSS