I have an issue regarding design 'Setting screen' for my app. In this screen I need to design circular menu options in a triangular shape and I need to set OnClickListener
only on the triangular area, which is only visible option border area. I can't understand what approach I need to use to achieve this design as well as set OnClickListener
.
Asked
Active
Viewed 67 times
0

belwood
- 3,320
- 11
- 38
- 45

Davinder Goel
- 763
- 2
- 8
- 22
-
can you share xml file for this for better understanding – Pranita Jun 17 '19 at 07:21
-
@Pranita i haven't design it yet, because i'm not understand how it will design? – Davinder Goel Jun 17 '19 at 08:25
-
You asked a question which has another question i.e. Did you manage to design it? Clicklistener is easy once you design it. Try to divide a linear layout into parts and then create a triangle layout like this https://stackoverflow.com/a/43738456/5339829 – Aman Verma Jun 17 '19 at 12:00
-
there are many ways how to do this. My first approach would be to create a custom View that contains the whole menu. In this view you can intercept touch events with their x and y coordinate and use this to match the touch to one of the menu items. – muetzenflo Jun 17 '19 at 12:15