ToolTip.ReshowDelay プロパティ

定義

ポインターが 1 つのコントロールから別のコントロールに移動したときに、移動先のツールヒント ウィンドウが表示されるまでに経過する必要のある時間の長さを取得または設定します。

public:
 property int ReshowDelay { int get(); void set(int value); };
public int ReshowDelay { get; set; }
member this.ReshowDelay : int with get, set
Public Property ReshowDelay As Integer

プロパティ値

Int32

移動先のツールヒント ウィンドウが表示されるまでにかかる時間 (ミリ秒単位)。

次のコード例では、クラスのインスタンスを ToolTip 作成し、インスタンスをインスタンスが Form 作成されたインスタンスに関連付けます。 次に、遅延プロパティ AutoPopDelayInitialDelayおよび ReshowDelay. さらに、クラスの ToolTip インスタンスは、フォームが ShowAlways アクティブかどうかに関係なく、ToolTip テキストを表示できるようにプロパティ true を設定します。 最後に、ツールヒント テキストをフォームの 2 つのコントロール a と CheckBoxa Button に関連付けます。 このコード例では、この例で定義されているメソッドが、名前付きのコントロールとcheckBox1,CheckBox名前付きのbutton1コントロールを含みButton、メソッドがコンストラクターFormから呼び出されるメソッド内Formに配置されている必要があります。

// This example assumes that the Form_Load event handling method
// is connected to the Load event of the form.
void Form1_Load( Object^ sender, System::EventArgs^ e )
{
   // Create the ToolTip and associate with the Form container.
   ToolTip^ toolTip1 = gcnew ToolTip;
   
   // Set up the delays for the ToolTip.
   toolTip1->AutoPopDelay = 5000;
   toolTip1->InitialDelay = 1000;
   toolTip1->ReshowDelay = 500;
   // Force the ToolTip text to be displayed whether or not the form is active.
   toolTip1->ShowAlways = true;
   
   // Set up the ToolTip text for the Button and Checkbox.
   toolTip1->SetToolTip( this->button1, "My button1" );
   toolTip1->SetToolTip( this->checkBox1, "My checkBox1" );
}
// This example assumes that the Form_Load event handling method
// is connected to the Load event of the form.
private void Form1_Load(object sender, System.EventArgs e)
{
   // Create the ToolTip and associate with the Form container.
   ToolTip toolTip1 = new ToolTip();

   // Set up the delays for the ToolTip.
   toolTip1.AutoPopDelay = 5000;
   toolTip1.InitialDelay = 1000;
   toolTip1.ReshowDelay = 500;
   // Force the ToolTip text to be displayed whether or not the form is active.
   toolTip1.ShowAlways = true;
      
   // Set up the ToolTip text for the Button and Checkbox.
   toolTip1.SetToolTip(this.button1, "My button1");
   toolTip1.SetToolTip(this.checkBox1, "My checkBox1");
}
' This example assumes that the Form_Load event handling method
' is connected to the Load event of the form.
Private Sub Form1_Load(sender As Object, e As System.EventArgs) Handles MyBase.Load
   ' Create the ToolTip and associate with the Form container.
   Dim toolTip1 As New ToolTip()
   
   ' Set up the delays for the ToolTip.
   toolTip1.AutoPopDelay = 5000
   toolTip1.InitialDelay = 1000
   toolTip1.ReshowDelay = 500
   ' Force the ToolTip text to be displayed whether or not the form is active.
   toolTip1.ShowAlways = True
   
   ' Set up the ToolTip text for the Button and Checkbox.
   toolTip1.SetToolTip(Me.button1, "My button1")
   toolTip1.SetToolTip(Me.checkBox1, "My checkBox1")
End Sub

注釈

このプロパティを ReshowDelay 使用すると、前のツールヒント ウィンドウが表示された ToolTip 後にツールヒント ウィンドウを表示する前に待機する時間を短縮または延長できます。 ツールヒント ウィンドウを初めて表示する場合は、プロパティの値を InitialDelay 使用して、ツールヒント ウィンドウを最初に表示する前に適用する遅延を決定します。 ツールヒント ウィンドウが現在表示されていて、ユーザーがツールヒント ウィンドウを表示する別のコントロールにポインターを移動すると、新しいコントロールのツールヒントを表示する前にプロパティの ReshowDelay 値が使用されます。 プロパティで指定された遅延を使用するには、前のコントロールのツールヒント ウィンドウを ReshowDelay 引き続き表示する必要があります。それ以外の InitialDelay 場合は、プロパティ値が使用されます。

ツールヒント ウィンドウに対して一貫した遅延パターンを設定する場合は、プロパティを AutomaticDelay 設定できます。 このプロパティはAutomaticDelayAutoPopDelayReshowDelay1 つの時間値に基づいて、プロパティ 、およびInitialDelayプロパティを初期値に設定します。 プロパティが AutomaticDelay 設定されるたびに、プロパティ値の ReshowDelay 1/5 に AutomaticDelay 設定されます。 プロパティが AutomaticDelay 設定されたら、プロパティを個別に設定 ReshowDelay して、既定値をオーバーライドできます。

適用対象

こちらもご覧ください