# Swipe gesture for template repeater, possible?

**URL:** <https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802>\
**Category:** Ignition\
**Tags:** ignition80\
**Created:** [August 17, 2020, 12:33pm UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802 "2020-08-17T12:33:10Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [August 17, 2020, 12:33pm UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802/1 "2020-08-17T12:33:10Z")

</div>

Hi all,

Does anyone know if this is possible to create a scroll function for a template repeater?

Meaning the scroll gesture should scroll down in the list of repeated templates.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [August 17, 2020, 3:11pm UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802/2 "2020-08-17T15:11:39Z")

</div>

Assuming the Vision template repeater, generally speaking any interactions beyond single mouse clicks are not supported well by Java Swing. You could theoretically do something like this with a mouse dragged listener, but it would likely be an exercise in frustration, and you’ll run into limits of what events Java Swing will actually record will a user is attempting the interaction.

---

<div class="post-metadata">

**Author:** ![Paullys50](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paullys50/32/3324_2.png) [@Paullys50](https://forum.inductiveautomation.com/u/Paullys50)\
**Post date:** [August 17, 2020, 3:39pm UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802/3 "2020-08-17T15:39:20Z")

</div>

I’ve actually been interested in similar. What’s the functional difference between scrolling using the scroll bar that automatically appears on the template repeater versus a mouse dragged listener?

For me, the value is touch screen interaction where click & drag on the component would expose a larger interaction area than the side scroll bar. Even with a wider scroll bar, you still have to hit it with your finger and it consumes real-estate so triggering the scroll directly on the component mouse click and drag can’t be that frustrating given it already does it with the native scroll bar.

---

<div class="post-metadata">

**Author:** ![SBL\_MC](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/sbl_mc/32/56813_2.png) [@SBL\_MC](https://forum.inductiveautomation.com/u/SBL_MC)\
**Post date:** [August 18, 2020, 8:13am UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802/4 "2020-08-18T08:13:46Z")

</div>

I tried to find a value to manipulate to be able scroll the repeater trough bindings. Any tips ?

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [August 18, 2020, 3:15pm UTC](https://forum.inductiveautomation.com/t/swipe-gesture-for-template-repeater-possible/37802/5 "2020-08-18T15:15:22Z")

</div>

There's various threads on the forum. This one doesn't solve the exact same problem, but gets you 90% of the way there:

> [@Scroll bar is slow for repeaters](http://forum.inductiveautomation.com/t/scroll-bar-is-slow-for-repeaters/9724/2):
>
> Try this: [code]from javax.swing import SwingUtilities from javax.swing import JScrollPane scrollPane = SwingUtilities.getAncestorOfClass(JScrollPane, event.source.parent.getComponent(‘Template Repeater’).getComponents()[1].getComponents()[2]) scrollPane.getVerticalScrollBar().setUnitIncrement(30) #scroll amount for wheel and arrows scrollPane.getVerticalScrollBar().setBlockIncrement(30) #scroll amount clicking on scrollbar itself [/code]
