Gridlayout with borders

I am a new Android developer, and I'm just trying to improve my skills by reading some samples, I want to create a new interface using GridLayout, I checked a lot of samples, but I can't seem to draw borders between GridLayout cells. What can I lose?

Here is the link I went through, but the borders did not appear!

http://developer.samsung.com/android/technical-docs/GridLayout-in-Android#

I appreciate your concern in advance.

+4
source share
1 answer

Android Layout containers have no boundaries. Nonetheless:

  • You can set the background of each type of cell to the Drawable xml resource, which describes a transparent rectangle with borders.

  • Give the background color to the parent view of the GridView and set the color of each GridView element to a different color.

Both can also be applied as a style.

+2
source

All Articles