Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • VTK VTK
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 833
    • Issues 833
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 234
    • Merge requests 234
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Package Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • VTKVTK
  • VTKVTK
  • Issues
  • #17993
Closed
Open
Issue created Aug 31, 2020 by Petr Matoušek@mat127

vtkBalloonWidget.SetTimerDuration() is broken in Java

It is not possible to adjust the timer duration for the vtkBalloonWidget in an application using Java wrapper. Calling

vtkBalloonWidget.SetTimerDuration(delay)

has no effect. Regardless the value of the delay, the balloon info is shown immediately after the mouse moves above the prop having the balloon assigned.

I think that this behavior is caused by the vtkCanvas implementation that uses javax.swing.Timer to invoke private inner DelayAction that invokes TimerEvent on the associated renderer interactor. This leads to vtkHoverWidget::HoverAction which causes balloon info to show up before the original vtkHoverWidget timer expires.

To see an example have a look at https://gitlab.kitware.com/snippets/2301

The timer duration is set to 500ms but balloon info show up immediately after the mouse is above the prop. Try to uncomment the throw statement in the timer() method (line 96) and explore the stack trace of the thrown exception. It is clear that the timer event the widget receives comes from the vtkCanvas code.

Assignee
Assign to
Time tracking