GUILayoutUtility.GetAspectRect 获取宽高比的矩形
static function GetAspectRect (aspect : float) : Rect
static function GetAspectRect (aspect : float, style : GUIStyle) : Rect
static function GetAspectRect (aspect : float, params options : GUILayoutOption[]) : Rect
static function GetAspectRect (aspect : float, style : GUIStyle, params options : GUILayoutOption[]) : Rect
-
aspectThe aspect ratio of the element (width / height)
该元素的宽高比(width / height) -
styleAn optional style.If specified, the style's padding value will be added to your sizes & its margin value will be used for spacing.
可选样式,如果指定,该style的padding值将加到你的大小,并且margin值将用于外边距。 -
optionsAn optional list of layout options that specify extra layouting properties. Any values passed in here will override settings defined by the style.
布局选项的一个可选列表,指定额外的布局属性。这里传递任意值将覆盖由style定义的设置。
参见: GUILayout.Width, GUILayout.Height, GUILayout.MinWidth, GUILayout.MaxWidth, GUILayout.MinHeight, GUILayout.MaxHeight, GUILayout.ExpandWidth, GUILayout.ExpandHeight.
Rect - the rect for the control.
返回Rect类型,这个控件的矩形。
Description描述
Reserve layout space for a rectangle with a specific aspect ratio.
为指定了宽高比的矩形,保留布局空间。就是说,获取一个指定了宽高比的矩形。
最后修改:2011年1月3日 Monday 20:00