Version: 2021.2
public GUIStyle button ;

描述

GUI.Button 控件默认使用的样式。

using UnityEngine;

public class Example : MonoBehaviour { // Modifies only the button style of the current GUISkin

GUIStyle style;

void OnGUI() { GUI.skin.box = style; GUILayout.Button("This is a button."); } }