Version: 5.3 (switch to 5.4b)
言語English
  • C#
  • JS

スクリプト言語

好きな言語を選択してください。選択した言語でスクリプトコードが表示されます。

GUILayoutUtility.GetAspectRect

マニュアルに切り替える
public static Rect GetAspectRect(float aspect);
public static Rect GetAspectRect(float aspect, GUIStyle style);
public static Rect GetAspectRect(float aspect, params GUILayoutOption[] options);
public static Rect GetAspectRect(float aspect, GUIStyle style, params GUILayoutOption[] options);

パラメーター

aspect エレメントのアスペクト比 (幅/高さ)
style オプションのスタイル。指定した場合、スタイルの padding 値を返される矩形のサイズに追加されされ、スペースを空ける margin 値が使用されます。
options 特別なレイアウト対応をするためのレイアウトオプションリスト。ここに渡された値は style で定義された設定を上書きします。
See Also: GUILayout.Width, GUILayout.Height, GUILayout.MinWidth, GUILayout.MaxWidth, GUILayout.MinHeight, GUILayout.MaxHeight, GUILayout.ExpandWidth, GUILayout.ExpandHeight.

戻り値

Rect コントロールの Rect

説明

指定したアスペクト比の矩形のレイアウト空間を予約します。