Control.UpdateBounds 方法

定义

更新控件的边界。Updates the bounds of the control.

重载

UpdateBounds(Int32, Int32, Int32, Int32, Int32, Int32)

用指定大小、位置和工作区的大小更新控件的边界。Updates the bounds of the control with the specified size, location, and client size.

UpdateBounds(Int32, Int32, Int32, Int32)

用指定大小和位置更新控件的边界。Updates the bounds of the control with the specified size and location.

UpdateBounds()

用当前大小和位置更新控件的边界。Updates the bounds of the control with the current size and location.

UpdateBounds(Int32, Int32, Int32, Int32, Int32, Int32)

用指定大小、位置和工作区的大小更新控件的边界。Updates the bounds of the control with the specified size, location, and client size.

protected:
 void UpdateBounds(int x, int y, int width, int height, int clientWidth, int clientHeight);
protected void UpdateBounds (int x, int y, int width, int height, int clientWidth, int clientHeight);
member this.UpdateBounds : int * int * int * int * int * int -> unit
Protected Sub UpdateBounds (x As Integer, y As Integer, width As Integer, height As Integer, clientWidth As Integer, clientHeight As Integer)

参数

x
Int32

控件的 X 坐标。The X coordinate of the control.

y
Int32

控件的 Y 坐标。The Y coordinate of the control.

width
Int32

控件的 WidthThe Width of the control.

height
Int32

控件的 HeightThe Height of the control.

clientWidth
Int32

控件的工作区的 WidthThe client Width of the control.

clientHeight
Int32

控件的工作区的 HeightThe client Height of the control.

注解

如果控件的新 Size 与以前的 Size不同,则会引发 SizeChanged 事件。If the new Size of the control is different from the previous Size, the SizeChanged event is raised. 同样,如果控件 Location 发生更改,则会引发 LocationChanged 事件。Likewise, if the Location of the control changes, the LocationChanged event is raised.

另请参阅

UpdateBounds(Int32, Int32, Int32, Int32)

用指定大小和位置更新控件的边界。Updates the bounds of the control with the specified size and location.

protected:
 void UpdateBounds(int x, int y, int width, int height);
protected void UpdateBounds (int x, int y, int width, int height);
member this.UpdateBounds : int * int * int * int -> unit
Protected Sub UpdateBounds (x As Integer, y As Integer, width As Integer, height As Integer)

参数

x
Int32

控件的 X 坐标。The X coordinate of the control.

y
Int32

控件的 Y 坐标。The Y coordinate of the control.

width
Int32

控件的 WidthThe Width of the control.

height
Int32

控件的 HeightThe Height of the control.

注解

如果控件的新 Size 与先前 Size不同,则会引发 SizeChanged 事件。If the new Size of the control if different from the previous Size, the SizeChanged event is raised. 同样,Location 控件更改,则会引发 LocationChanged 事件。Likewise, is the Location of the control changes, the LocationChanged event is raised.

另请参阅

UpdateBounds()

用当前大小和位置更新控件的边界。Updates the bounds of the control with the current size and location.

protected:
 void UpdateBounds();
protected void UpdateBounds ();
member this.UpdateBounds : unit -> unit
Protected Sub UpdateBounds ()

注解

如果控件的新 Size 与以前的 Size不同,则会引发 SizeChanged 事件。If the new Size of the control is different from the previous Size, the SizeChanged event is raised. 同样,如果控件 Location 发生更改,则会引发 LocationChanged 事件。Likewise, if the Location of the control changes, the LocationChanged event is raised.

另请参阅

适用于