Reputation: 5642
I am fairly new to Android UI design. I'm attempting to mimic the UI design of the following Living Social screen shot:
What is the best way to structure the UI elements here? How can this be implemented in XML? I'm trying to use the Android Eclipse UI editor to drag and drop UI elements, but it seems that I'll need to dynamically program the UI. What is the recommended way to approaching a problem like this?
So far, I have the following:
<LinearLayout
android:id="@+id/LinearLayout1"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical"
android:paddingBottom="@dimen/activity_vertical_margin">
<ScrollView
android:id="@+id/scrollView1"
android:layout_width="fill_parent"
android:layout_height="wrap_content" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:orientation="vertical"
>
<ImageView
android:id="@+id/imageViewBackground"
android:layout_width="fill_parent"
android:layout_height="match_parent"
android:layout_gravity="fill"
android:scaleType="fitXY"
android:src="@android:drawable/dialog_holo_dark_frame" />
<View
android:id="@+id/view1"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<View
android:id="@+id/view2"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
<View
android:id="@+id/view3"
android:layout_width="wrap_content"
android:layout_height="wrap_content" />
</LinearLayout>
</ScrollView>
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_gravity="bottom"
android:backgroundTint="@color/abc_search_url_text_normal"
android:gravity="bottom|end"
android:orientation="vertical" >
<Button
android:id="@+id/buttonBUY"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="BUY!" />
</LinearLayout>
</LinearLayout>
Questions:
Thank you
Upvotes: 0
Views: 156
Reputation: 9461
Probably, you need Parallax effect and CardView controls inside linear layout control. In order to add bottom button you can use Relative layout. As for parallax, please, take a look at the following thread : How to do the new PlayStore parallax effect
Upvotes: 1