Skip to content

Commit af5deac

Browse files
authored
multiple_resolutions.rst: Clear up confusing use of terms window and viewport
Clear up a potential misunderstanding for new users. When I first read this documentation, it left me with the impression that there's a `/root` viewport which lives inside of the window object. This false lesson was reinforced by the existing of both `get_window()` and `get_viewport()` in the API.
1 parent 515d22d commit af5deac

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

tutorials/rendering/multiple_resolutions.rst

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,14 @@ that are different from this base size. Godot offers many ways to
7272
control how the viewport will be resized and stretched to different
7373
screen sizes.
7474

75+
.. note::
76+
77+
On this page, *window* refers to the screen area alloted to your game
78+
by the system, while *viewport* refers to the root object (accessible
79+
from ``get_tree().root``) which the game controls to fill this screen area.
80+
This viewport is a :ref:`Window <class_Window>` instance. Recall from the
81+
:ref:`introduction <doc_viewports>` that *all* Window objects are viewports.
82+
7583
To configure the stretch base size at runtime from a script, use the
7684
``get_tree().root.content_scale_size`` property (see
7785
:ref:`Window.content_scale_size <class_Window_property_content_scale_size>`).

0 commit comments

Comments
 (0)