android layout like this one -


i make layout 1 displayed on this link. image , 2 simple buttons on button of screen, trying using code:

<merge xmlns:android="http://schemas.android.com/apk/res/android">  <relativelayout xmlns:android="http://schemas.android.com/apk/res/android"     android:layout_width="fill_parent" android:layout_height="fill_parent">      <imageview android:id="@+id/maxsapimg" android:layout_width="fill_parent"         android:layout_height="wrap_content" android:layout_alignparenttop="true"         android:scaletype="center" android:src="@drawable/golden_gate">     </imageview>      <relativelayout android:id="@+id/innerrelativelayout"         android:layout_width="wrap_content" android:layout_height="wrap_content"         android:layout_alignparentbottom="true">          <button android:text="@string/camera" android:id="@+id/camerbtn"             android:layout_alignparentbottom="true" android:layout_width="wrap_content"             android:layout_height="wrap_content">         </button>          <button android:text="@string/local" android:id="@+id/localbtn" android:layout_width="wrap_content"             android:layout_toleftof="@+id/camerbtn" android:layout_height="wrap_content">         </button>      </relativelayout>  </relativelayout></merge> 

but no luck far ideas?

i added android:orientation="horizontal" relativelayout tag , changed toleftof android:layout_torightof="@+id/camerbtn" in second button tag

            <relativelayout                     android:id="@+id/innerrelativelayout"                     android:orientation="horizontal"                     android:layout_width="wrap_content"                     android:layout_height="wrap_content"                     android:layout_alignparentbottom="true"                     android:layout_centerhorizontal="true">                     <button                             android:text="@string/camera"                             android:id="@+id/camerbtn"                             android:layout_width="wrap_content"                             android:layout_height="wrap_content" />                     <button                             android:text="@string/local"                             android:id="@+id/localbtn"                             android:layout_width="wrap_content"                             android:layout_torightof="@+id/camerbtn"                             android:layout_height="wrap_content" />             </relativelayout> 

this works me


Comments

Popular posts from this blog

unicode - Are email addresses allowed to contain non-alphanumeric characters? -

c++ - Convert big endian to little endian when reading from a binary file -

C#: Application without a window or taskbar item (background app) that can still use Console.WriteLine() -