다음을 통해 공유


방법: BetweenShowDelay 속성 사용

업데이트: 2010년 7월

이 예제에서는 BetweenShowDelay 시간 속성을 사용하여 사용자가 한 도구 설명에서 다른 도구 설명으로 마우스 포인터를 이동할 때 지연 없이 도구 설명이 빠르게 나타나도록 설정하는 방법을 보여 줍니다.

예제

다음 예제에서는 두 Ellipse 컨트롤의 도구 설명 모두에 대해 InitialShowDelay 속성은 1초(1000밀리초)로 설정하고 BetweenShowDelay는 2초(2000밀리초)로 설정합니다. Ellipse 중 하나에 대한 도구 설명을 표시한 다음 2초 내에 마우스 포인터를 다른 Ellipse로 이동하여 그 위에 계속 두면 두 번째 Ellipse의 도구 설명이 즉시 표시됩니다.

다음과 같은 시나리오 중 하나에서 InitialShowDelay를 적용하면 두 번째 Ellipse의 도구 설명이 1초 후에 나타납니다.

  • 두 번째 단추로 이동하는 데 걸린 시간이 2초 이상인 경우

  • 첫 번째 Ellipse에 대한 시간 간격의 시작 부분에서 도구 설명이 표시되지 않는 경우

      <Ellipse Height="25" Width="50" 
               Fill="Gray" 
               HorizontalAlignment="Left"
               ToolTipService.InitialShowDelay="1000"
               ToolTipService.ShowDuration="7000"
               ToolTipService.BetweenShowDelay="2000">
        <Ellipse.ToolTip>
          <ToolTip Placement="Right" 
                   PlacementRectangle="50,0,0,0"
                   HorizontalOffset="10" 
                   VerticalOffset="20"
                   HasDropShadow="false"
                   Opened="whenToolTipOpens"
                   Closed="whenToolTipCloses"
                   >
            <BulletDecorator>
              <BulletDecorator.Bullet>
                <Ellipse Height="10" Width="20" Fill="Blue"/>
              </BulletDecorator.Bullet>
              <TextBlock>Uses the ToolTip Class</TextBlock>
            </BulletDecorator>
          </ToolTip>
        </Ellipse.ToolTip>
      </Ellipse>



...


<Ellipse Height="25" Width="50" 
      Fill="Gray" 
      HorizontalAlignment="Left"
      ToolTipService.InitialShowDelay="1000"
      ToolTipService.ShowDuration="7000"
      ToolTipService.BetweenShowDelay="2000"
      ToolTipService.Placement="Right" 
      ToolTipService.PlacementRectangle="50,0,0,0"
      ToolTipService.HorizontalOffset="10" 
      ToolTipService.VerticalOffset="20"
      ToolTipService.HasDropShadow="false"
      ToolTipService.ShowOnDisabled="true" 
      ToolTipService.IsEnabled="true"
      ToolTipOpening="whenToolTipOpens"
      ToolTipClosing="whenToolTipCloses"
      >
  <Ellipse.ToolTip>
    <BulletDecorator>
      <BulletDecorator.Bullet>
        <Ellipse Height="10" Width="20" Fill="Blue"/>
      </BulletDecorator.Bullet>
      <TextBlock>Uses the ToolTipService class</TextBlock>
    </BulletDecorator>
  </Ellipse.ToolTip>
</Ellipse>

참고 항목

참조

ToolTip

ToolTipService

개념

도구 설명 개요

기타 리소스

도구 설명 방법 항목

변경 기록

날짜

변경 내용

이유

2010년 7월

누락되었던 코드가 추가되었습니다.

고객 의견