From c03e474d11625e978b993049559c9e7c7bbe5984 Mon Sep 17 00:00:00 2001 From: Michael Alexsander Date: Mon, 16 Jan 2023 12:34:56 -0300 Subject: [PATCH] Make `DisplayServer` docs tell users to change some window values in the `Window` node --- doc/classes/DisplayServer.xml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/doc/classes/DisplayServer.xml b/doc/classes/DisplayServer.xml index 1dc4dd3ff07..6d362c91d99 100644 --- a/doc/classes/DisplayServer.xml +++ b/doc/classes/DisplayServer.xml @@ -1315,6 +1315,7 @@ Sets the maximum size of the window specified by [param window_id] in pixels. Normally, the user will not be able to drag the window to make it smaller than the specified size. See also [method window_get_max_size]. + [b]Note:[/b] It's recommended to change this value using [member Window.max_size] instead. [b]Note:[/b] Using third-party tools, it is possible for users to disable window geometry restrictions and therefore bypass this limit. @@ -1324,6 +1325,7 @@ Sets the minimum size for the given window to [param min_size] (in pixels). Normally, the user will not be able to drag the window to make it larger than the specified size. See also [method window_get_min_size]. + [b]Note:[/b] It's recommended to change this value using [member Window.min_size] instead. [b]Note:[/b] By default, the main window has a minimum size of [code]Vector2i(64, 64)[/code]. This prevents issues that can arise when the window is resized to a near-zero size. [b]Note:[/b] Using third-party tools, it is possible for users to disable window geometry restrictions and therefore bypass this limit. @@ -1393,6 +1395,7 @@ +-------------+ +-------+ [/codeblock] See also [method window_get_position] and [method window_set_size]. + [b]Note:[/b] It's recommended to change this value using [member Window.position] instead. @@ -1409,6 +1412,7 @@ Sets the size of the given window to [param size] (in pixels). See also [method window_get_size] and [method window_get_position]. + [b]Note:[/b] It's recommended to change this value using [member Window.size] instead. @@ -1417,6 +1421,7 @@ Sets the title of the given window to [param title]. + [b]Note:[/b] It's recommended to change this value using [member Window.title] instead. [b]Note:[/b] Avoid changing the window title every frame, as this can cause performance issues on certain window managers. Try to change the window title only a few times per second at most. @@ -1426,7 +1431,8 @@ Sets window transient parent. Transient window is will be destroyed with its transient parent and will return focus to their parent when closed. The transient window is displayed on top of a non-exclusive full-screen parent window. Transient windows can't enter full-screen mode. - Note that behavior might be different depending on the platform. + [b]Note:[/b] It's recommended to change this value using [member Window.transient] instead. + [b]Note:[/b] The behavior might be different depending on the platform.