Question

I am trying to create a keypad using Android Grid Layout. I would like one button that spans columns and rows in a 'L' Shape, for the Enter key.

Keypad with L shaped Enter button

See diagram. I have created a keypad and added the numeric buttons using Grid layout ok, but am struggling to work out if it is possible to span the rows and columns as I want to create the Enter Key. Is this possible? any hints tips or example code would be appreciated

Was it helpful?

Solution

A more elegant solution would be to create your buttons dynamically drawing filled touchable polygons on a canvas.

Take a look at "ImageMap for Android" (http://catchthecows.com/?p=113). It is really powerful, you can even create touchable charts.

OTHER TIPS

Quick and dirty workaround: create a button (return) which is as big as 4 (2*2) of the regular ones.

Then put button 9 over it, top lef aligned.

It will work just fine

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top