I'm designing an android application with multiple tabs for viewing different lists. In one of the tabs, the items of the list can be removed; maybe using swipe to delete option, but the problem is swiping can also result in changing to the adjacent tab according to material design guidelines. What should be done? Shall I not provide the option to swipe to delete here? and if so, how can a user delete an item in the list with ease?
Users can only remember so much
This is a known usability problem in gesture-based UIs. There are only so many gestures users will discover and use proficiently. When you factor in the number of apps that each have solve interaction in their own way, the user's memory load becomes staggering. With the small selection of available, usable, and learnable gestures, confusing areas of overlap are inevitable.
Expanding the toolkit
Samsung and Apple tried to expand the gesture repertoire with hover detection and pressure levels, respectively. That didn't turn out well because users were constantly surprised by the behavior and the adoption curve never grew (I kinda liked both, TBH).
There are a few options to address the limited usable gestures without totally giving up on gesture-based UI.
- Object-level gesture rules: Detect the location of the gesture and change behavior based on proximity to UI objects, eg list items, actions, notifications, and navigation. This can be tricky in a dense UI where one type of object (eg list items) dominate the real estate.
- Spatial gesture rules: Gestures within the main areas of the UI can trigger different actions than gestures from the edge of the viewing area. This requires dexterity on the user's part and, given the edge area, is error prone.
- Gesture duration rules: Detecting a fast gesture vs an extended gesture. This is most often used for tap vs tap-and-hold. It could be repurposed for swipe vs tap-hold-swipe.
Real world answers
If you get creative with gestures, you might stumble on some great solutions. Tap, swipe, and hold provide a reasonable toolkit. Get creative and think about the repetitive tasks your users need to complete.
Real answers to nuanced questions like this come from your users.
- Do your homework
- Develop prototypes
- Test with your users
I don't mind here to solve it by just deciding whether the swipe gesture is exactly at only one of the
list item or not.
As user swipes, the swipe can be checked with its position and then decision can be made within a function to decide if tab change or the deletion of the list item would be executed/intended.
If swiping changes tabs on Android, then press and hold provides options to delete. If the question is about consistent Android experience, there should no be no arguments here. Just follow the usual. Swipe and delete is from iOS point of view. There is no reason to mix and no question of overlap.