i want something like this:
i palyed with android relativelayout and it's tag like : android:layout_centerHorizontal="true" , and this give me this:
i player with other tags and combine them, but no success.
so is there any way to do this?
Try this:
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent" >
<LinearLayout
android:id="@+id/linearLayout1"
android:layout_width="20dp"
android:layout_height="match_parent"
android:layout_centerHorizontal="true"
android:background="@android:color/black" >
</LinearLayout>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_toRightOf="@+id/linearLayout1"
android:text="YOUR TEXT" />
</RelativeLayout>
try this
<RelativeLayout
android:layout_width="fill_parent"
android:background="#FFFFFF"
android:layout_height="wrap_content">
<View
android:layout_width="10dp"
android:layout_height="1dp"
android:layout_centerInParent="true"
android:id="@+id/dummy"
/>
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="SDADASd"
android:layout_centerVertical="true"
android:layout_toRightOf="@id/dummy"
android:textColor="#000000"
/>
</RelativeLayout>
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With