[英]I want to create this UI
I want to create this UI. 我想创建这个UI。
I have done this work. 我已经完成了这项工作。
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="274dp"
android:layout_marginTop="40dp"
android:background="@drawable/car"
android:orientation="vertical">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentTop="true"
android:text="PP AUTOMATIVES"
android:textSize="18dp"
android:textStyle="bold" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:src="@drawable/ratingimage"
/>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentStart="true"
android:src="@drawable/offersimage"
/>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:src="@drawable/heartimage"
/>
</RelativeLayout>
</RelativeLayout>
I am not able to set alignment of images and set background color, margin and style of TextView according to "OFFICEWork" UI. 我无法根据“ OFFICEWork” UI设置图像的对齐方式,也无法设置TextView的背景颜色,边距和样式。
<RelativeLayout
android:layout_width="match_parent"
android:layout_height="220dp"
android:layout_marginTop="40dp"
android:background="@drawable/car">
<RelativeLayout
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:background="#f7f7f8"
android:padding="2dp">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_centerVertical="true"
android:layout_margin="10dp"
android:text="PP AUTOMATIVES"
android:textColor="@color/white"
android:textSize="20sp"
android:textStyle="bold" />
</RelativeLayout>
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:padding="2dp"
android:src="@drawable/ratingimage" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentRight="true"
android:src="@drawable/offersimage" />
<ImageView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_alignParentBottom="true"
android:layout_alignParentRight="true"
android:padding="5dp"
android:src="@drawable/heartimage" />
</RelativeLayout>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.