Documentation

Unity Engine


User Manual

Script Reference

Unity Engine


SetTitle(string)

Sets the title of the window.
Read time 1 minuteLast updated 7 days ago

Definition

public AsyncOperation SetTitle(string title)

Parameters

title

The new title for the window.

Returns

Type

Description

AsyncOperationAn AsyncOperation that represents the asynchronous operation.

Examples

using UnityEngine;using UnityEngine.Windowing;public class SetWindowTitleExample : MonoBehaviour{ AsyncOperation asyncOperation = null; void Start() { var window = GameWindow.Main; asyncOperation = window.SetTitle("My Game Window"); } void Update() { if (asyncOperation != null && asyncOperation.isDone) { Debug.Log("Window title set successfully."); asyncOperation = null; } }}