![](/img/trans.png)
[英]Is it possible to align a child of a relative layout centered on top of another child?
[英]Align a layout top of a image that is centered
我有一个相对的布局,它的内部是一个以父视图为中心的ImageView。
我要向图像添加共享。 如果我将此属性设置为android:layout_alignTop="@+id/myImage"
则按钮将显示在图像上方。 我想超越这个。
采用
android:layout_below="@+id/shareId"
在您的<ImageView>
标记中。 要么
android:layout_above="@+id/myImage"
在您共享的“ View
标签中,具体取决于哪种方法更适合您。 如果仍不能解决问题,请发布xml和您想要的图片。
RelativeLayout文档显示了可以使用的不同属性。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.