public void setLayoutParams (ViewGroup.LayoutParams params)Since: API Level 1 Set the layout parameters associated with this view. These supply parameters to the parent of this view specifying how it should be arranged. There are many subclasses of ViewGroup.LayoutParams, and these correspond to the different subclasses of ViewGroup that are responsible for arranging their children. Parametersparams The layout parameters for this view, cannot be null http://developer.android.com/reference/android/view/View.html#setLayoutParams(android.view.ViewGroup.LayoutParams) RelativeLayout.LayoutParams rlp = new RelativeLayout.LayoutParams(300,400); rlayout.setLayoutParams(rlp);
Set the layout parameters associated with this view. These supply parameters to the parent of this view specifying how it should be arranged. There are many subclasses of ViewGroup.LayoutParams, and these correspond to the different subclasses of ViewGroup that are responsible for arranging their children.
Parametersparams The layout parameters for this view, cannot be null
http://developer.android.com/reference/android/view/View.html#setLayoutParams(android.view.ViewGroup.LayoutParams)
RelativeLayout.LayoutParams rlp = new RelativeLayout.LayoutParams(300,400);
rlayout.setLayoutParams(rlp);
1.如果我想重新制定 这个 RelativeLayout 位于另外一个 RelativeLayout之下,有什么方法吗?
原因是我在重新制定大小之后,显示的布局 覆盖了上面的RelativeLayout了
.如果我想重新制定 这个 RelativeLayout 位于另外一个 RelativeLayout之下,有什么方法吗?
原因是我在重新制定大小之后,显示的布局 覆盖了上面的RelativeLayout了