Can you please tell me how to align textView
around imageview
like this
_____
| |
|_____| Some Dummy text,Some Dummy text,
Some Dummy text,Some Dummy text,S...more
I want to restrict my TextView only for 2 lines and at the end I will have one TextView or Button called more for more text which will open in pop up.
Is it possible to create something like this.?
It is definitely possible. You need to use RelativeLayout under which you can place each of these views and align them as required.
<HorizontalScrollView xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="wrap_content">
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent">
<LinearLayout
xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<ImageButton
android:id="@+id/imageButton1"
android:layout_width="wrap_content"
android:layout_height="100dp"
android:src="@drawable/pic7"
android:text="image1" />
<TextView
android:id="@+id/text"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:gravity="center"
android:text="Textview1" />
</LinearLayout>
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.