4

I want to implement following layout: enter image description here

This works great for fixed margin between Icon(Circle) and Label(Rectangle) but for Height maintenance LinearLayout is not much usable as Icon overlaps above icons' label area

Is there any way to dynamically set this layout dynamically for different screens??

NOTE:Icons and label are same as it is button with drawabletop, so if there will simple idea for arranging simple button will do.....

Hanry
  • 5,481
  • 2
  • 40
  • 53

2 Answers2

3

Here is an exaple to implement: Android 3D Carousel and also layout with buttons in a circle?

Also Check out the existing SO question: creating a Circular view in android

Possible Exact solution (I hope):

From this article i am sure you will get exact idea of designing layout: Android SDK: Creating a Rotating Dialer

enter image description here

Community
  • 1
  • 1
Paresh Mayani
  • 127,700
  • 71
  • 241
  • 295
0

This is what you need to do, no code though just a brief layout.

<LinearLayout orientation=vertical for whole screen>
    <LinearLayout weight=1 gravity=center> <!-- Top -->
    </LinearLayout>
    <LinearLayout weight=1 orientation=horizontal> <!-- Middle -->
        <LinearLayout weight=1 gravity=left/>
        <LinearLayout weight=1 gravity=right/>
    </LinearLayout>
    <LinearLayout weight=1> <!-- Botton -->
        <LinearLayout weight=1 gravity=center/>
        <LinearLayout weight=1 gravity=center/>
    </LinearLayout>
</LinearLayout>

Hope this helps, let me know if you need more clarifications.

PravinCG
  • 7,688
  • 3
  • 30
  • 55
  • I have already mentioned that by using LL the icon in second or third line cannot overlap the half-label area of previous line. – Hanry Dec 23 '11 at 06:02