Does Juce have a SwipeView type of widget?

Hi. I’ve been away from Juce for a couple of years due to work changes, but glad to be back.

Does Juce have a SwipeView widget, which allows a a user to make a swipe gesture to switch pages or switch the contents of an area on the display?

I went through some of the online doc this morning and didn’t see anything like that, but I wondering if I may have missed it.

Maybe this is beyond the typical use of Juce.

  • Steve
1 Like

Hi there (and welcome back!). Look at Viewport and AnimatedPositionBehaviours. There’s SnapToPageBoundaries, which could be what your’e after (but I haven’t used it yet).

Also check out this recent thread for a solution to a problem with the inertia:

Things get tricky if you want to swipe through pages with GUI elements, because this does not work as in iOS or Android (and as users surely expect!). If one initiates a swipe gesture over a GUI element, this activates the element. This is specially problematic with comboboxes and sliders. I’m at the moment trying to figure how to best deal with this.