diff options
Diffstat (limited to 'doc')
32 files changed, 450 insertions, 29 deletions
diff --git a/doc/classes/@GlobalScope.xml b/doc/classes/@GlobalScope.xml index a86f41cd9c..55d00b6cf9 100644 --- a/doc/classes/@GlobalScope.xml +++ b/doc/classes/@GlobalScope.xml @@ -1209,7 +1209,7 @@ <return type="int" /> <param index="0" name="x" type="int" /> <description> - Returns [code]-1[/code] if [param x] is negative, [code]1[/code] if [param x] is positive, and [code]0[/code] if if [param x] is zero. + Returns [code]-1[/code] if [param x] is negative, [code]1[/code] if [param x] is positive, and [code]0[/code] if [param x] is zero. [codeblock] signi(-6) # Returns -1 signi(0) # Returns 0 @@ -2933,7 +2933,15 @@ <constant name="PROPERTY_HINT_PASSWORD" value="36" enum="PropertyHint"> Hints that a string property is a password, and every character is replaced with the secret character. </constant> - <constant name="PROPERTY_HINT_MAX" value="39" enum="PropertyHint"> + <constant name="PROPERTY_HINT_TOOL_BUTTON" value="39" enum="PropertyHint"> + Hints that a [Callable] property should be displayed as a clickable button. When the button is pressed, the callable is called. The hint string specifies the button text and optionally an icon from the [code]"EditorIcons"[/code] theme type. + [codeblock lang=text] + "Click me!" - A button with the text "Click me!" and the default "Callable" icon. + "Click me!,ColorRect" - A button with the text "Click me!" and the "ColorRect" icon. + [/codeblock] + [b]Note:[/b] A [Callable] cannot be properly serialized and stored in a file, so it is recommended to use [constant PROPERTY_USAGE_EDITOR] instead of [constant PROPERTY_USAGE_DEFAULT]. + </constant> + <constant name="PROPERTY_HINT_MAX" value="40" enum="PropertyHint"> Represents the size of the [enum PropertyHint] enum. </constant> <constant name="PROPERTY_USAGE_NONE" value="0" enum="PropertyUsageFlags" is_bitfield="true"> diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml index 887e9cda81..609d7eff39 100644 --- a/doc/classes/Animation.xml +++ b/doc/classes/Animation.xml @@ -34,6 +34,14 @@ <link title="Animation documentation index">$DOCS_URL/tutorials/animation/index.html</link> </tutorials> <methods> + <method name="add_marker"> + <return type="void" /> + <param index="0" name="name" type="StringName" /> + <param index="1" name="time" type="float" /> + <description> + Adds a marker to this Animation. + </description> + </method> <method name="add_track"> <return type="int" /> <param index="0" name="type" type="int" enum="Animation.TrackType" /> @@ -271,12 +279,60 @@ Returns the index of the specified track. If the track is not found, return -1. </description> </method> + <method name="get_marker_at_time" qualifiers="const"> + <return type="StringName" /> + <param index="0" name="time" type="float" /> + <description> + Returns the name of the marker located at the given time. + </description> + </method> + <method name="get_marker_color" qualifiers="const"> + <return type="Color" /> + <param index="0" name="name" type="StringName" /> + <description> + Returns the given marker's color. + </description> + </method> + <method name="get_marker_names" qualifiers="const"> + <return type="PackedStringArray" /> + <description> + Returns every marker in this Animation, sorted ascending by time. + </description> + </method> + <method name="get_marker_time" qualifiers="const"> + <return type="float" /> + <param index="0" name="name" type="StringName" /> + <description> + Returns the given marker's time. + </description> + </method> + <method name="get_next_marker" qualifiers="const"> + <return type="StringName" /> + <param index="0" name="time" type="float" /> + <description> + Returns the closest marker that comes after the given time. If no such marker exists, an empty string is returned. + </description> + </method> + <method name="get_prev_marker" qualifiers="const"> + <return type="StringName" /> + <param index="0" name="time" type="float" /> + <description> + Returns the closest marker that comes before the given time. If no such marker exists, an empty string is returned. + </description> + </method> <method name="get_track_count" qualifiers="const"> <return type="int" /> <description> Returns the amount of tracks in the animation. </description> </method> + <method name="has_marker" qualifiers="const"> + <return type="bool" /> + <param index="0" name="name" type="StringName" /> + <description> + Returns [code]true[/code] if this Animation contains a marker with the given name. + </description> + </method> <method name="method_track_get_name" qualifiers="const"> <return type="StringName" /> <param index="0" name="track_idx" type="int" /> @@ -320,6 +376,13 @@ Returns the interpolated position value at the given time (in seconds). The [param track_idx] must be the index of a 3D position track. </description> </method> + <method name="remove_marker"> + <return type="void" /> + <param index="0" name="name" type="StringName" /> + <description> + Removes the marker with the given name from this Animation. + </description> + </method> <method name="remove_track"> <return type="void" /> <param index="0" name="track_idx" type="int" /> @@ -363,6 +426,14 @@ Returns the interpolated scale value at the given time (in seconds). The [param track_idx] must be the index of a 3D scale track. </description> </method> + <method name="set_marker_color"> + <return type="void" /> + <param index="0" name="name" type="StringName" /> + <param index="1" name="color" type="Color" /> + <description> + Sets the given marker's color. + </description> + </method> <method name="track_find_key" qualifiers="const"> <return type="int" /> <param index="0" name="track_idx" type="int" /> diff --git a/doc/classes/AnimationPlayer.xml b/doc/classes/AnimationPlayer.xml index 1ca8ac2fa5..9aeb4b7162 100644 --- a/doc/classes/AnimationPlayer.xml +++ b/doc/classes/AnimationPlayer.xml @@ -75,6 +75,24 @@ Returns the node which node path references will travel from. </description> </method> + <method name="get_section_end_time" qualifiers="const"> + <return type="float" /> + <description> + Returns the end time of the section currently being played. + </description> + </method> + <method name="get_section_start_time" qualifiers="const"> + <return type="float" /> + <description> + Returns the start time of the section currently being played. + </description> + </method> + <method name="has_section" qualifiers="const"> + <return type="bool" /> + <description> + Returns [code]true[/code] if an animation is currently playing with section. + </description> + </method> <method name="is_playing" qualifiers="const"> <return type="bool" /> <description> @@ -110,6 +128,54 @@ This method is a shorthand for [method play] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], so see its description for more information. </description> </method> + <method name="play_section"> + <return type="void" /> + <param index="0" name="name" type="StringName" default="&""" /> + <param index="1" name="start_time" type="float" default="-1" /> + <param index="2" name="end_time" type="float" default="-1" /> + <param index="3" name="custom_blend" type="float" default="-1" /> + <param index="4" name="custom_speed" type="float" default="1.0" /> + <param index="5" name="from_end" type="bool" default="false" /> + <description> + Plays the animation with key [param name] and the section starting from [param start_time] and ending on [param end_time]. See also [method play]. + Setting [param start_time] to a value outside the range of the animation means the start of the animation will be used instead, and setting [param end_time] to a value outside the range of the animation means the end of the animation will be used instead. [param start_time] cannot be equal to [param end_time]. + </description> + </method> + <method name="play_section_backwards"> + <return type="void" /> + <param index="0" name="name" type="StringName" default="&""" /> + <param index="1" name="start_time" type="float" default="-1" /> + <param index="2" name="end_time" type="float" default="-1" /> + <param index="3" name="custom_blend" type="float" default="-1" /> + <description> + Plays the animation with key [param name] and the section starting from [param start_time] and ending on [param end_time] in reverse. + This method is a shorthand for [method play_section] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], see its description for more information. + </description> + </method> + <method name="play_section_with_markers"> + <return type="void" /> + <param index="0" name="name" type="StringName" default="&""" /> + <param index="1" name="start_marker" type="StringName" default="&""" /> + <param index="2" name="end_marker" type="StringName" default="&""" /> + <param index="3" name="custom_blend" type="float" default="-1" /> + <param index="4" name="custom_speed" type="float" default="1.0" /> + <param index="5" name="from_end" type="bool" default="false" /> + <description> + Plays the animation with key [param name] and the section starting from [param start_marker] and ending on [param end_marker]. + If the start marker is empty, the section starts from the beginning of the animation. If the end marker is empty, the section ends on the end of the animation. See also [method play]. + </description> + </method> + <method name="play_section_with_markers_backwards"> + <return type="void" /> + <param index="0" name="name" type="StringName" default="&""" /> + <param index="1" name="start_marker" type="StringName" default="&""" /> + <param index="2" name="end_marker" type="StringName" default="&""" /> + <param index="3" name="custom_blend" type="float" default="-1" /> + <description> + Plays the animation with key [param name] and the section starting from [param start_marker] and ending on [param end_marker] in reverse. + This method is a shorthand for [method play_section_with_markers] with [code]custom_speed = -1.0[/code] and [code]from_end = true[/code], see its description for more information. + </description> + </method> <method name="play_with_capture"> <return type="void" /> <param index="0" name="name" type="StringName" default="&""" /> @@ -139,6 +205,12 @@ [b]Note:[/b] If a looped animation is currently playing, the queued animation will never play unless the looped animation is stopped somehow. </description> </method> + <method name="reset_section"> + <return type="void" /> + <description> + Resets the current section if section is set. + </description> + </method> <method name="seek"> <return type="void" /> <param index="0" name="seconds" type="float" /> @@ -180,6 +252,23 @@ Sets the node which node path references will travel from. </description> </method> + <method name="set_section"> + <return type="void" /> + <param index="0" name="start_time" type="float" default="-1" /> + <param index="1" name="end_time" type="float" default="-1" /> + <description> + Changes the start and end times of the section being played. The current playback position will be clamped within the new section. See also [method play_section]. + </description> + </method> + <method name="set_section_with_markers"> + <return type="void" /> + <param index="0" name="start_marker" type="StringName" default="&""" /> + <param index="1" name="end_marker" type="StringName" default="&""" /> + <description> + Changes the start and end markers of the section being played. The current playback position will be clamped within the new section. See also [method play_section_with_markers]. + If the argument is empty, the section uses the beginning or end of the animation. If both are empty, it means that the section is not set. + </description> + </method> <method name="stop"> <return type="void" /> <param index="0" name="keep_state" type="bool" default="false" /> diff --git a/doc/classes/CPUParticles3D.xml b/doc/classes/CPUParticles3D.xml index d7770f2cd5..04ee95457c 100644 --- a/doc/classes/CPUParticles3D.xml +++ b/doc/classes/CPUParticles3D.xml @@ -11,6 +11,12 @@ <link title="Particle systems (3D)">$DOCS_URL/tutorials/3d/particles/index.html</link> </tutorials> <methods> + <method name="capture_aabb" qualifiers="const"> + <return type="AABB" /> + <description> + Returns the axis-aligned bounding box that contains all the particles that are active in the current frame. + </description> + </method> <method name="convert_from_particles"> <return type="void" /> <param index="0" name="particles" type="Node" /> diff --git a/doc/classes/CameraAttributesPhysical.xml b/doc/classes/CameraAttributesPhysical.xml index faedfee712..e2036162c7 100644 --- a/doc/classes/CameraAttributesPhysical.xml +++ b/doc/classes/CameraAttributesPhysical.xml @@ -25,7 +25,7 @@ The maximum luminance (in EV100) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing below a certain brightness, resulting in a cut off point where the scene will remain bright. </member> <member name="auto_exposure_min_exposure_value" type="float" setter="set_auto_exposure_min_exposure_value" getter="get_auto_exposure_min_exposure_value" default="-8.0"> - The minimum luminance luminance (in EV100) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing above a certain brightness, resulting in a cut off point where the scene will remain dark. + The minimum luminance (in EV100) used when calculating auto exposure. When calculating scene average luminance, color values will be clamped to at least this value. This limits the auto-exposure from exposing above a certain brightness, resulting in a cut off point where the scene will remain dark. </member> <member name="exposure_aperture" type="float" setter="set_aperture" getter="get_aperture" default="16.0"> Size of the aperture of the camera, measured in f-stops. An f-stop is a unitless ratio between the focal length of the camera and the diameter of the aperture. A high aperture setting will result in a smaller aperture which leads to a dimmer image and sharper focus. A low aperture results in a wide aperture which lets in more light resulting in a brighter, less-focused image. Default is appropriate for outdoors at daytime (i.e. for use with a default [DirectionalLight3D]), for indoor lighting, a value between 2 and 4 is more appropriate. diff --git a/doc/classes/CameraFeed.xml b/doc/classes/CameraFeed.xml index 8033c0880b..2b6db13906 100644 --- a/doc/classes/CameraFeed.xml +++ b/doc/classes/CameraFeed.xml @@ -45,6 +45,34 @@ [code]copy[/code] will result in FEED_YCBCR </description> </method> + <method name="set_name"> + <return type="void" /> + <param index="0" name="name" type="String" /> + <description> + Sets the camera's name. + </description> + </method> + <method name="set_position"> + <return type="void" /> + <param index="0" name="position" type="int" enum="CameraFeed.FeedPosition" /> + <description> + Sets the position of this camera. + </description> + </method> + <method name="set_rgb_image"> + <return type="void" /> + <param index="0" name="rgb_image" type="Image" /> + <description> + Sets RGB image for this feed. + </description> + </method> + <method name="set_ycbcr_image"> + <return type="void" /> + <param index="0" name="ycbcr_image" type="Image" /> + <description> + Sets YCbCr image for this feed. + </description> + </method> </methods> <members> <member name="feed_is_active" type="bool" setter="set_active" getter="is_active" default="false"> diff --git a/doc/classes/Dictionary.xml b/doc/classes/Dictionary.xml index 4441c3cb79..5c9b22fe4a 100644 --- a/doc/classes/Dictionary.xml +++ b/doc/classes/Dictionary.xml @@ -474,6 +474,12 @@ Returns the number of entries in the dictionary. Empty dictionaries ([code]{ }[/code]) always return [code]0[/code]. See also [method is_empty]. </description> </method> + <method name="sort"> + <return type="void" /> + <description> + Sorts the dictionary in-place by key. This can be used to ensure dictionaries with the same contents produce equivalent results when getting the [method keys], getting the [method values], and converting to a string. This is also useful when wanting a JSON representation consistent with what is in memory, and useful for storing on a database that requires dictionaries to be sorted. + </description> + </method> <method name="values" qualifiers="const"> <return type="Array" /> <description> diff --git a/doc/classes/DisplayServer.xml b/doc/classes/DisplayServer.xml index 79064a88ba..37bf265d20 100644 --- a/doc/classes/DisplayServer.xml +++ b/doc/classes/DisplayServer.xml @@ -893,6 +893,13 @@ Returns [code]true[/code] if the specified [param feature] is supported by the current [DisplayServer], [code]false[/code] otherwise. </description> </method> + <method name="has_hardware_keyboard" qualifiers="const"> + <return type="bool" /> + <description> + Returns [code]true[/code] if hardware keyboard is connected. + [b]Note:[/b] This method is implemented on Android and iOS, on other platforms this method always returns [code]true[/code]. + </description> + </method> <method name="help_set_search_callbacks"> <return type="void" /> <param index="0" name="search_callback" type="Callable" /> diff --git a/doc/classes/EditorContextMenuPlugin.xml b/doc/classes/EditorContextMenuPlugin.xml index 71c4ca0f9b..fb90a2a5cd 100644 --- a/doc/classes/EditorContextMenuPlugin.xml +++ b/doc/classes/EditorContextMenuPlugin.xml @@ -47,6 +47,24 @@ [/codeblock] </description> </method> + <method name="add_context_submenu_item"> + <return type="void" /> + <param index="0" name="name" type="String" /> + <param index="1" name="menu" type="PopupMenu" /> + <param index="2" name="icon" type="Texture2D" default="null" /> + <description> + Add a submenu to the context menu of the plugin's specified slot. The submenu is not automatically handled, you need to connect to its signals yourself. Also the submenu is freed on every popup, so provide a new [PopupMenu] every time. + [codeblock] + func _popup_menu(paths): + var popup_menu = PopupMenu.new() + popup_menu.add_item("Blue") + popup_menu.add_item("White") + popup_menu.id_pressed.connect(_on_color_submenu_option) + + add_context_menu_item("Set Node Color", popup_menu) + [/codeblock] + </description> + </method> <method name="add_menu_shortcut"> <return type="void" /> <param index="0" name="shortcut" type="Shortcut" /> diff --git a/doc/classes/EditorExportPlugin.xml b/doc/classes/EditorExportPlugin.xml index 42e1968eb0..aa8e4b3d56 100644 --- a/doc/classes/EditorExportPlugin.xml +++ b/doc/classes/EditorExportPlugin.xml @@ -159,6 +159,15 @@ Return a [PackedStringArray] of additional features this preset, for the given [param platform], should have. </description> </method> + <method name="_get_export_option_visibility" qualifiers="virtual const"> + <return type="bool" /> + <param index="0" name="platform" type="EditorExportPlatform" /> + <param index="1" name="option" type="String" /> + <description> + [b]Optional.[/b] + Validates [param option] and returns the visibility for the specified [param platform]. The default implementation returns [code]true[/code] for all options. + </description> + </method> <method name="_get_export_option_warning" qualifiers="virtual const"> <return type="String" /> <param index="0" name="platform" type="EditorExportPlatform" /> diff --git a/doc/classes/EditorInspector.xml b/doc/classes/EditorInspector.xml index cfdc172fd1..6b25be490e 100644 --- a/doc/classes/EditorInspector.xml +++ b/doc/classes/EditorInspector.xml @@ -28,6 +28,7 @@ </method> </methods> <members> + <member name="follow_focus" type="bool" setter="set_follow_focus" getter="is_following_focus" overrides="ScrollContainer" default="true" /> <member name="horizontal_scroll_mode" type="int" setter="set_horizontal_scroll_mode" getter="get_horizontal_scroll_mode" overrides="ScrollContainer" enum="ScrollContainer.ScrollMode" default="0" /> </members> <signals> diff --git a/doc/classes/EditorInterface.xml b/doc/classes/EditorInterface.xml index 795c5c1c2f..43059db8b2 100644 --- a/doc/classes/EditorInterface.xml +++ b/doc/classes/EditorInterface.xml @@ -343,6 +343,14 @@ [/codeblock] </description> </method> + <method name="popup_quick_open"> + <return type="void" /> + <param index="0" name="callback" type="Callable" /> + <param index="1" name="base_types" type="StringName[]" default="[]" /> + <description> + Pops up an editor dialog for quick selecting a resource file. The [param callback] must take a single argument of type [String] which will contain the path of the selected resource or be empty if the dialog is canceled. If [param base_types] is provided, the dialog will only show resources that match these types. Only types deriving from [Resource] are supported. + </description> + </method> <method name="reload_scene_from_path"> <return type="void" /> <param index="0" name="scene_filepath" type="String" /> diff --git a/doc/classes/EditorSettings.xml b/doc/classes/EditorSettings.xml index 5eb8ac6199..a5097521dc 100644 --- a/doc/classes/EditorSettings.xml +++ b/doc/classes/EditorSettings.xml @@ -714,6 +714,12 @@ If [code]true[/code], when saving a file, the editor will rename the old file to a different name, save a new file, then only remove the old file once the new file has been saved. This makes loss of data less likely to happen if the editor or operating system exits unexpectedly while saving (e.g. due to a crash or power outage). [b]Note:[/b] On Windows, this feature can interact negatively with certain antivirus programs. In this case, you may have to set this to [code]false[/code] to prevent file locking issues. </member> + <member name="filesystem/quick_open_dialog/default_display_mode" type="int" setter="" getter=""> + If set to [code]Adaptive[/code], the dialog opens in list view or grid view depending on the requested type. If set to [code]Last Used[/code], the display mode will always open the way you last used it. + </member> + <member name="filesystem/quick_open_dialog/include_addons" type="bool" setter="" getter=""> + If [code]true[/code], results will include files located in the [code]addons[/code] folder. + </member> <member name="filesystem/tools/oidn/oidn_denoise_path" type="String" setter="" getter=""> The path to the directory containing the Open Image Denoise (OIDN) executable, used optionally for denoising lightmaps. It can be downloaded from [url=https://www.openimagedenoise.org/downloads.html]openimagedenoise.org[/url]. To enable this feature for your specific project, use [member ProjectSettings.rendering/lightmapping/denoising/denoiser]. @@ -772,7 +778,7 @@ Translations are provided by the community. If you spot a mistake, [url=$DOCS_URL/contributing/documentation/editor_and_docs_localization.html]contribute to editor translations on Weblate![/url] </member> <member name="interface/editor/editor_screen" type="int" setter="" getter=""> - The preferred monitor to display the editor. + The preferred monitor to display the editor. If [b]Auto[/b], the editor will remember the last screen it was displayed on across restarts. </member> <member name="interface/editor/expand_to_title" type="bool" setter="" getter=""> Expanding main editor window content to the title, if supported by [DisplayServer]. See [constant DisplayServer.WINDOW_FLAG_EXTEND_TO_TITLE]. @@ -826,9 +832,6 @@ <member name="interface/editor/project_manager_screen" type="int" setter="" getter=""> The preferred monitor to display the project manager. </member> - <member name="interface/editor/remember_window_size_and_position" type="bool" setter="" getter=""> - If [code]true[/code], the editor window will remember its size, position, and which screen it was displayed on across restarts. - </member> <member name="interface/editor/save_each_scene_on_quit" type="bool" setter="" getter=""> If [code]false[/code], the editor will save all scenes when confirming the [b]Save[/b] action when quitting the editor or quitting to the project list. If [code]true[/code], the editor will ask to save each scene individually. </member> diff --git a/doc/classes/Environment.xml b/doc/classes/Environment.xml index de3295fbe0..1779408a4d 100644 --- a/doc/classes/Environment.xml +++ b/doc/classes/Environment.xml @@ -81,8 +81,9 @@ The background mode. See [enum BGMode] for possible values. </member> <member name="fog_aerial_perspective" type="float" setter="set_fog_aerial_perspective" getter="get_fog_aerial_perspective" default="0.0"> - If set above [code]0.0[/code] (exclusive), blends between the fog's color and the color of the background [Sky]. This has a small performance cost when set above [code]0.0[/code]. Must have [member background_mode] set to [constant BG_SKY]. + If set above [code]0.0[/code] (exclusive), blends between the fog's color and the color of the background [Sky], as read from the radiance cubemap. This has a small performance cost when set above [code]0.0[/code]. Must have [member background_mode] set to [constant BG_SKY]. This is useful to simulate [url=https://en.wikipedia.org/wiki/Aerial_perspective]aerial perspective[/url] in large scenes with low density fog. However, it is not very useful for high-density fog, as the sky will shine through. When set to [code]1.0[/code], the fog color comes completely from the [Sky]. If set to [code]0.0[/code], aerial perspective is disabled. + Notice that this does not sample the [Sky] directly, but rather the radiance cubemap. The cubemap is sampled at a mipmap level depending on the depth of the rendered pixel; the farther away, the higher the resolution of the sampled mipmap. This results in the actual color being a blurred version of the sky, with more blur closer to the camera. The highest mipmap resolution is used at a depth of [member Camera3D.far]. </member> <member name="fog_density" type="float" setter="set_fog_density" getter="get_fog_density" default="0.01"> The fog density to be used. This is demonstrated in different ways depending on the [member fog_mode] mode chosen: diff --git a/doc/classes/FileDialog.xml b/doc/classes/FileDialog.xml index 1ae889adc1..18b8eb1d39 100644 --- a/doc/classes/FileDialog.xml +++ b/doc/classes/FileDialog.xml @@ -29,6 +29,12 @@ [param default_value_index] should be an index of the value in the [param values]. If [param values] is empty it should be either [code]1[/code] (checked), or [code]0[/code] (unchecked). </description> </method> + <method name="clear_filename_filter"> + <return type="void" /> + <description> + Clear the filter for file names. + </description> + </method> <method name="clear_filters"> <return type="void" /> <description> @@ -134,6 +140,10 @@ <member name="file_mode" type="int" setter="set_file_mode" getter="get_file_mode" enum="FileDialog.FileMode" default="4"> The dialog's open or save mode, which affects the selection behavior. See [enum FileMode]. </member> + <member name="filename_filter" type="String" setter="set_filename_filter" getter="get_filename_filter" default=""""> + The filter for file names (case-insensitive). When set to a non-empty string, only files that contains the substring will be shown. [member filename_filter] can be edited by the user with the filter button at the top of the file dialog. + See also [member filters], which should be used to restrict the file types that can be selected instead of [member filename_filter] which is meant to be set by the user. + </member> <member name="filters" type="PackedStringArray" setter="set_filters" getter="get_filters" default="PackedStringArray()"> The available file type filters. Each filter string in the array should be formatted like this: [code]*.txt,*.doc;Text Files[/code]. The description text of the filter is optional and can be omitted. </member> @@ -154,7 +164,7 @@ <member name="size" type="Vector2i" setter="set_size" getter="get_size" overrides="Window" default="Vector2i(640, 360)" /> <member name="title" type="String" setter="set_title" getter="get_title" overrides="Window" default=""Save a File"" /> <member name="use_native_dialog" type="bool" setter="set_use_native_dialog" getter="get_use_native_dialog" default="false"> - If [code]true[/code], [member access] is set to [constant ACCESS_FILESYSTEM], and it is supported by the current [DisplayServer], OS native dialog will be used instead of custom one. + If [code]true[/code], and if supported by the current [DisplayServer], OS native dialog will be used instead of custom one. [b]Note:[/b] On Linux and macOS, sandboxed apps always use native dialogs to access the host file system. [b]Note:[/b] On macOS, sandboxed apps will save security-scoped bookmarks to retain access to the opened folders across multiple sessions. Use [method OS.get_granted_permissions] to get a list of saved bookmarks. [b]Note:[/b] Native dialogs are isolated from the base process, file dialog properties can't be modified once the dialog is shown. @@ -173,6 +183,12 @@ Emitted when the user selects a file by double-clicking it or pressing the [b]OK[/b] button. </description> </signal> + <signal name="filename_filter_changed"> + <param index="0" name="filter" type="String" /> + <description> + Emitted when the filter for file names changes. + </description> + </signal> <signal name="files_selected"> <param index="0" name="paths" type="PackedStringArray" /> <description> @@ -237,6 +253,9 @@ <theme_item name="reload" data_type="icon" type="Texture2D"> Custom icon for the reload button. </theme_item> + <theme_item name="toggle_filename_filter" data_type="icon" type="Texture2D"> + Custom icon for the toggle button for the filter for file names. + </theme_item> <theme_item name="toggle_hidden" data_type="icon" type="Texture2D"> Custom icon for the toggle hidden button. </theme_item> diff --git a/doc/classes/GraphEdit.xml b/doc/classes/GraphEdit.xml index 670df10a89..3451e427f3 100644 --- a/doc/classes/GraphEdit.xml +++ b/doc/classes/GraphEdit.xml @@ -399,6 +399,11 @@ Emitted when this [GraphEdit] captures a [code]ui_copy[/code] action ([kbd]Ctrl + C[/kbd] by default). In general, this signal indicates that the selected [GraphElement]s should be copied. </description> </signal> + <signal name="cut_nodes_request"> + <description> + Emitted when this [GraphEdit] captures a [code]ui_cut[/code] action ([kbd]Ctrl + X[/kbd] by default). In general, this signal indicates that the selected [GraphElement]s should be cut. + </description> + </signal> <signal name="delete_nodes_request"> <param index="0" name="nodes" type="StringName[]" /> <description> diff --git a/doc/classes/InputMap.xml b/doc/classes/InputMap.xml index ff04040826..0abd7c6974 100644 --- a/doc/classes/InputMap.xml +++ b/doc/classes/InputMap.xml @@ -67,7 +67,7 @@ <method name="add_action"> <return type="void" /> <param index="0" name="action" type="StringName" /> - <param index="1" name="deadzone" type="float" default="0.5" /> + <param index="1" name="deadzone" type="float" default="0.2" /> <description> Adds an empty action to the [InputMap] with a configurable [param deadzone]. An [InputEvent] can then be added to this action with [method action_add_event]. diff --git a/doc/classes/ItemList.xml b/doc/classes/ItemList.xml index c60a2ca887..fdaeb54bdf 100644 --- a/doc/classes/ItemList.xml +++ b/doc/classes/ItemList.xml @@ -73,6 +73,13 @@ [b]Note:[/b] The returned value is unreliable if called right after modifying the [ItemList], before it redraws in the next frame. </description> </method> + <method name="get_item_auto_translate_mode" qualifiers="const"> + <return type="int" enum="Node.AutoTranslateMode" /> + <param index="0" name="idx" type="int" /> + <description> + Returns item's auto translate mode. + </description> + </method> <method name="get_item_custom_bg_color" qualifiers="const"> <return type="Color" /> <param index="0" name="idx" type="int" /> @@ -230,6 +237,15 @@ [b]Note:[/b] This method does not trigger the item selection signal. </description> </method> + <method name="set_item_auto_translate_mode"> + <return type="void" /> + <param index="0" name="idx" type="int" /> + <param index="1" name="mode" type="int" enum="Node.AutoTranslateMode" /> + <description> + Sets the auto translate mode of the item associated with the specified index. + Items use [constant Node.AUTO_TRANSLATE_MODE_INHERIT] by default, which uses the same auto translate mode as the [ItemList] itself. + </description> + </method> <method name="set_item_custom_bg_color"> <return type="void" /> <param index="0" name="idx" type="int" /> @@ -363,6 +379,9 @@ <member name="auto_height" type="bool" setter="set_auto_height" getter="has_auto_height" default="false"> If [code]true[/code], the control will automatically resize the height to fit its content. </member> + <member name="auto_width" type="bool" setter="set_auto_width" getter="has_auto_width" default="false"> + If [code]true[/code], the control will automatically resize the width to fit its content. + </member> <member name="clip_contents" type="bool" setter="set_clip_contents" getter="is_clipping_contents" overrides="Control" default="true" /> <member name="fixed_column_width" type="int" setter="set_fixed_column_width" getter="get_fixed_column_width" default="0"> The width all columns will be adjusted to. diff --git a/doc/classes/LineEdit.xml b/doc/classes/LineEdit.xml index 41f42392de..3e0c328dcb 100644 --- a/doc/classes/LineEdit.xml +++ b/doc/classes/LineEdit.xml @@ -8,7 +8,7 @@ - When the [LineEdit] control is focused using the keyboard arrow keys, it will only gain focus and not enter edit mode. - To enter edit mode, click on the control with the mouse or press the [code]ui_text_submit[/code] action (by default [kbd]Enter[/kbd] or [kbd]Kp Enter[/kbd]). - To exit edit mode, press [code]ui_text_submit[/code] or [code]ui_cancel[/code] (by default [kbd]Escape[/kbd]) actions. - - Check [method is_editing] and [signal editing_toggled] for more information. + - Check [method edit], [method unedit], [method is_editing], and [signal editing_toggled] for more information. [b]Important:[/b] - Focusing the [LineEdit] with [code]ui_focus_next[/code] (by default [kbd]Tab[/kbd]) or [code]ui_focus_prev[/code] (by default [kbd]Shift + Tab[/kbd]) or [method Control.grab_focus] still enters edit mode (for compatibility). [LineEdit] features many built-in shortcuts that are always available ([kbd]Ctrl[/kbd] here maps to [kbd]Cmd[/kbd] on macOS): @@ -75,6 +75,13 @@ Clears the current selection. </description> </method> + <method name="edit"> + <return type="void" /> + <description> + Allows entering edit mode whether the [LineEdit] is focused or not. + Use [method Callable.call_deferred] if you want to enter edit mode on [signal text_submitted]. + </description> + </method> <method name="get_menu" qualifiers="const"> <return type="PopupMenu" /> <description> @@ -223,6 +230,12 @@ Selects the whole [String]. </description> </method> + <method name="unedit"> + <return type="void" /> + <description> + Allows exiting edit mode while preserving focus. + </description> + </method> </methods> <members> <member name="alignment" type="int" setter="set_horizontal_alignment" getter="get_horizontal_alignment" enum="HorizontalAlignment" default="0"> diff --git a/doc/classes/PackedVector2Array.xml b/doc/classes/PackedVector2Array.xml index da41812e0b..4d487b6dc2 100644 --- a/doc/classes/PackedVector2Array.xml +++ b/doc/classes/PackedVector2Array.xml @@ -5,7 +5,7 @@ </brief_description> <description> An array specifically designed to hold [Vector2]. Packs data tightly, so it saves memory for large array sizes. - [b]Differences between packed arrays, typed arrays, and untyped arrays:[/b] Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. [PackedVector3Array] versus [code]Array[Vector2][/code]). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as [method Array.map]. Typed arrays are in turn faster to iterate on and modify than untyped arrays. + [b]Differences between packed arrays, typed arrays, and untyped arrays:[/b] Packed arrays are generally faster to iterate on and modify compared to a typed array of the same type (e.g. [PackedVector2Array] versus [code]Array[Vector2][/code]). Also, packed arrays consume less memory. As a downside, packed arrays are less flexible as they don't offer as many convenience methods such as [method Array.map]. Typed arrays are in turn faster to iterate on and modify than untyped arrays. [b]Note:[/b] Packed arrays are always passed by reference. To get a copy of an array that can be modified independently of the original array, use [method duplicate]. This is [i]not[/i] the case for built-in properties and methods. The returned packed array of these are a copies, and changing it will [i]not[/i] affect the original value. To update a built-in property you need to modify the returned array, and then assign it to the property again. </description> <tutorials> diff --git a/doc/classes/Performance.xml b/doc/classes/Performance.xml index 6bb71932dd..66078d2642 100644 --- a/doc/classes/Performance.xml +++ b/doc/classes/Performance.xml @@ -224,7 +224,22 @@ <constant name="NAVIGATION_OBSTACLE_COUNT" value="33" enum="Monitor"> Number of active navigation obstacles in the [NavigationServer3D]. </constant> - <constant name="MONITOR_MAX" value="34" enum="Monitor"> + <constant name="PIPELINE_COMPILATIONS_CANVAS" value="34" enum="Monitor"> + Number of pipeline compilations that were triggered by the 2D canvas renderer. + </constant> + <constant name="PIPELINE_COMPILATIONS_MESH" value="35" enum="Monitor"> + Number of pipeline compilations that were triggered by loading meshes. These compilations will show up as longer loading times the first time a user runs the game and the pipeline is required. + </constant> + <constant name="PIPELINE_COMPILATIONS_SURFACE" value="36" enum="Monitor"> + Number of pipeline compilations that were triggered by building the surface cache before rendering the scene. These compilations will show up as a stutter when loading an scene the first time a user runs the game and the pipeline is required. + </constant> + <constant name="PIPELINE_COMPILATIONS_DRAW" value="37" enum="Monitor"> + Number of pipeline compilations that were triggered while drawing the scene. These compilations will show up as stutters during gameplay the first time a user runs the game and the pipeline is required. + </constant> + <constant name="PIPELINE_COMPILATIONS_SPECIALIZATION" value="38" enum="Monitor"> + Number of pipeline compilations that were triggered to optimize the current scene. These compilations are done in the background and should not cause any stutters whatsoever. + </constant> + <constant name="MONITOR_MAX" value="39" enum="Monitor"> Represents the size of the [enum Monitor] enum. </constant> </constants> diff --git a/doc/classes/PopupMenu.xml b/doc/classes/PopupMenu.xml index 004bbe2286..d73cda7460 100644 --- a/doc/classes/PopupMenu.xml +++ b/doc/classes/PopupMenu.xml @@ -776,7 +776,7 @@ [StyleBox] for the right side of labeled separator. See [method add_separator]. </theme_item> <theme_item name="panel" data_type="style" type="StyleBox"> - [StyleBox] for the the background panel. + [StyleBox] for the background panel. </theme_item> <theme_item name="separator" data_type="style" type="StyleBox"> [StyleBox] used for the separators. See [method add_separator]. diff --git a/doc/classes/PopupPanel.xml b/doc/classes/PopupPanel.xml index 399e285402..b581f32686 100644 --- a/doc/classes/PopupPanel.xml +++ b/doc/classes/PopupPanel.xml @@ -10,7 +10,7 @@ </tutorials> <theme_items> <theme_item name="panel" data_type="style" type="StyleBox"> - [StyleBox] for the the background panel. + [StyleBox] for the background panel. </theme_item> </theme_items> </class> diff --git a/doc/classes/ProjectSettings.xml b/doc/classes/ProjectSettings.xml index 7b6d8d0cd3..d0f0459193 100644 --- a/doc/classes/ProjectSettings.xml +++ b/doc/classes/ProjectSettings.xml @@ -1369,7 +1369,7 @@ macOS specific override for the shortcut to select the word currently under the caret. </member> <member name="input/ui_text_skip_selection_for_next_occurrence" type="Dictionary" setter="" getter=""> - If no selection is currently active with the last caret in text fields, searches for the next occurrence of the the word currently under the caret and moves the caret to the next occurrence. The action can be performed sequentially for other occurrences of the word under the last caret. + If no selection is currently active with the last caret in text fields, searches for the next occurrence of the word currently under the caret and moves the caret to the next occurrence. The action can be performed sequentially for other occurrences of the word under the last caret. If a selection is currently active with the last caret in text fields, searches for the next occurrence of the selection, adds a caret, selects the next occurrence then deselects the previous selection and its associated caret. The action can be performed sequentially for other occurrences of the selection of the last caret. The viewport is adjusted to the latest newly added caret. [b]Note:[/b] Default [code]ui_*[/code] actions cannot be removed as they are necessary for the internal logic of several [Control]s. The events assigned to the action can however be modified. @@ -2863,11 +2863,6 @@ </member> <member name="rendering/shading/overrides/force_vertex_shading" type="bool" setter="" getter="" default="false"> If [code]true[/code], forces vertex shading for all rendering. This can increase performance a lot, but also reduces quality immensely. Can be used to optimize performance on low-end mobile devices. - [b]Note:[/b] This setting currently has no effect, as vertex shading is not implemented yet. - </member> - <member name="rendering/shading/overrides/force_vertex_shading.mobile" type="bool" setter="" getter="" default="true"> - Lower-end override for [member rendering/shading/overrides/force_vertex_shading] on mobile devices, due to performance concerns or driver support. - [b]Note:[/b] This setting currently has no effect, as vertex shading is not implemented yet. </member> <member name="rendering/textures/canvas_textures/default_texture_filter" type="int" setter="" getter="" default="1"> The default texture filtering mode to use on [CanvasItem]s. @@ -2905,8 +2900,8 @@ </member> <member name="rendering/textures/vram_compression/compress_with_gpu" type="bool" setter="" getter="" default="true"> If [code]true[/code], the texture importer will utilize the GPU for compressing textures, improving the import time of large images. - [b]Note:[/b] This setting requires either Vulkan or D3D12 available as a rendering backend. - [b]Note:[/b] Currently this only affects BC1 and BC6H compression, which are used on Desktop and Console for fully opaque and HDR images respectively. + [b]Note:[/b] This only functions on a device which supports either Vulkan, D3D12, or Metal available as a rendering backend. + [b]Note:[/b] Currently this only affects certain compressed formats (BC1, BC4, and BC6), all of which are exclusive to desktop platforms and consoles. </member> <member name="rendering/textures/vram_compression/import_etc2_astc" type="bool" setter="" getter="" default="false"> If [code]true[/code], the texture importer will import VRAM-compressed textures using the Ericsson Texture Compression 2 algorithm for lower quality textures and normal maps and Adaptable Scalable Texture Compression algorithm for high quality textures (in 4×4 block size). diff --git a/doc/classes/RenderingServer.xml b/doc/classes/RenderingServer.xml index a57f6adec8..b73315219b 100644 --- a/doc/classes/RenderingServer.xml +++ b/doc/classes/RenderingServer.xml @@ -913,7 +913,7 @@ <param index="1" name="transform" type="Transform2D" /> <description> Transforms both the current and previous stored transform for a canvas light. - This allows transforming a light without creating a "glitch" in the interpolation, which is is particularly useful for large worlds utilizing a shifting origin. + This allows transforming a light without creating a "glitch" in the interpolation, which is particularly useful for large worlds utilizing a shifting origin. </description> </method> <method name="canvas_occluder_polygon_create"> @@ -5687,6 +5687,39 @@ <constant name="RENDERING_INFO_VIDEO_MEM_USED" value="5" enum="RenderingInfo"> Video memory used (in bytes). When using the Forward+ or mobile rendering backends, this is always greater than the sum of [constant RENDERING_INFO_TEXTURE_MEM_USED] and [constant RENDERING_INFO_BUFFER_MEM_USED], since there is miscellaneous data not accounted for by those two metrics. When using the GL Compatibility backend, this is equal to the sum of [constant RENDERING_INFO_TEXTURE_MEM_USED] and [constant RENDERING_INFO_BUFFER_MEM_USED]. </constant> + <constant name="RENDERING_INFO_PIPELINE_COMPILATIONS_CANVAS" value="6" enum="RenderingInfo"> + Number of pipeline compilations that were triggered by the 2D canvas renderer. + </constant> + <constant name="RENDERING_INFO_PIPELINE_COMPILATIONS_MESH" value="7" enum="RenderingInfo"> + Number of pipeline compilations that were triggered by loading meshes. These compilations will show up as longer loading times the first time a user runs the game and the pipeline is required. + </constant> + <constant name="RENDERING_INFO_PIPELINE_COMPILATIONS_SURFACE" value="8" enum="RenderingInfo"> + Number of pipeline compilations that were triggered by building the surface cache before rendering the scene. These compilations will show up as a stutter when loading an scene the first time a user runs the game and the pipeline is required. + </constant> + <constant name="RENDERING_INFO_PIPELINE_COMPILATIONS_DRAW" value="9" enum="RenderingInfo"> + Number of pipeline compilations that were triggered while drawing the scene. These compilations will show up as stutters during gameplay the first time a user runs the game and the pipeline is required. + </constant> + <constant name="RENDERING_INFO_PIPELINE_COMPILATIONS_SPECIALIZATION" value="10" enum="RenderingInfo"> + Number of pipeline compilations that were triggered to optimize the current scene. These compilations are done in the background and should not cause any stutters whatsoever. + </constant> + <constant name="PIPELINE_SOURCE_CANVAS" value="0" enum="PipelineSource"> + Pipeline compilation that was triggered by the 2D canvas renderer. + </constant> + <constant name="PIPELINE_SOURCE_MESH" value="1" enum="PipelineSource"> + Pipeline compilation that was triggered by loading a mesh. + </constant> + <constant name="PIPELINE_SOURCE_SURFACE" value="2" enum="PipelineSource"> + Pipeline compilation that was triggered by building the surface cache before rendering the scene. + </constant> + <constant name="PIPELINE_SOURCE_DRAW" value="3" enum="PipelineSource"> + Pipeline compilation that was triggered while drawing the scene. + </constant> + <constant name="PIPELINE_SOURCE_SPECIALIZATION" value="4" enum="PipelineSource"> + Pipeline compilation that was triggered to optimize the current scene. + </constant> + <constant name="PIPELINE_SOURCE_MAX" value="5" enum="PipelineSource"> + Represents the size of the [enum PipelineSource] enum. + </constant> <constant name="FEATURE_SHADERS" value="0" enum="Features" deprecated="This constant has not been used since Godot 3.0."> </constant> <constant name="FEATURE_MULTITHREADED" value="1" enum="Features" deprecated="This constant has not been used since Godot 3.0."> diff --git a/doc/classes/Signal.xml b/doc/classes/Signal.xml index c970ccb094..b9ec34956f 100644 --- a/doc/classes/Signal.xml +++ b/doc/classes/Signal.xml @@ -4,7 +4,7 @@ A built-in type representing a signal of an [Object]. </brief_description> <description> - [Signal] is a built-in [Variant] type that represents a signal of an [Object] instance. Like all [Variant] types, it can be stored in variables and passed to functions. Signals allow all connected [Callable]s (and by extension their respective objects) to listen and react to events, without directly referencing one another. This keeps the code flexible and easier to manage. + [Signal] is a built-in [Variant] type that represents a signal of an [Object] instance. Like all [Variant] types, it can be stored in variables and passed to functions. Signals allow all connected [Callable]s (and by extension their respective objects) to listen and react to events, without directly referencing one another. This keeps the code flexible and easier to manage. You can check whether an [Object] has a given signal name using [method Object.has_signal]. In GDScript, signals can be declared with the [code]signal[/code] keyword. In C#, you may use the [code][Signal][/code] attribute on a delegate. [codeblocks] [gdscript] diff --git a/doc/classes/Sprite2D.xml b/doc/classes/Sprite2D.xml index d73cb02d94..239c4dcf09 100644 --- a/doc/classes/Sprite2D.xml +++ b/doc/classes/Sprite2D.xml @@ -76,7 +76,7 @@ If [code]true[/code], texture is cut from a larger atlas texture. See [member region_rect]. </member> <member name="region_filter_clip_enabled" type="bool" setter="set_region_filter_clip_enabled" getter="is_region_filter_clip_enabled" default="false"> - If [code]true[/code], the outermost pixels get blurred out. [member region_enabled] must be [code]true[/code]. + If [code]true[/code], the area outside of the [member region_rect] is clipped to avoid bleeding of the surrounding texture pixels. [member region_enabled] must be [code]true[/code]. </member> <member name="region_rect" type="Rect2" setter="set_region_rect" getter="get_region_rect" default="Rect2(0, 0, 0, 0)"> The region of the atlas texture to display. [member region_enabled] must be [code]true[/code]. diff --git a/doc/classes/TextServer.xml b/doc/classes/TextServer.xml index aed041c5ad..d76e65b618 100644 --- a/doc/classes/TextServer.xml +++ b/doc/classes/TextServer.xml @@ -229,6 +229,11 @@ [code]points[/code] - [PackedVector3Array], containing outline points. [code]x[/code] and [code]y[/code] are point coordinates. [code]z[/code] is the type of the point, using the [enum ContourPointTag] values. [code]contours[/code] - [PackedInt32Array], containing indices the end points of each contour. [code]orientation[/code] - [bool], contour orientation. If [code]true[/code], clockwise contours must be filled. + - Two successive [constant CONTOUR_CURVE_TAG_ON] points indicate a line segment. + - One [constant CONTOUR_CURVE_TAG_OFF_CONIC] point between two [constant CONTOUR_CURVE_TAG_ON] points indicates a single conic (quadratic) Bézier arc. + - Two [constant CONTOUR_CURVE_TAG_OFF_CUBIC] points between two [constant CONTOUR_CURVE_TAG_ON] points indicate a single cubic Bézier arc. + - Two successive [constant CONTOUR_CURVE_TAG_OFF_CONIC] points indicate two successive conic (quadratic) Bézier arcs with a virtual [constant CONTOUR_CURVE_TAG_ON] point at their middle. + - Each contour is closed. The last point of a contour uses the first point of a contour as its next point, and vice versa. The first point can be [constant CONTOUR_CURVE_TAG_OFF_CONIC] point. </description> </method> <method name="font_get_glyph_index" qualifiers="const"> diff --git a/doc/classes/TranslationDomain.xml b/doc/classes/TranslationDomain.xml index da6f2704bf..5045f86260 100644 --- a/doc/classes/TranslationDomain.xml +++ b/doc/classes/TranslationDomain.xml @@ -30,6 +30,13 @@ Returns the [Translation] instance that best matches [param locale]. Returns [code]null[/code] if there are no matches. </description> </method> + <method name="pseudolocalize" qualifiers="const"> + <return type="StringName" /> + <param index="0" name="message" type="StringName" /> + <description> + Returns the pseudolocalized string based on the [param message] passed in. + </description> + </method> <method name="remove_translation"> <return type="void" /> <param index="0" name="translation" type="Translation" /> @@ -57,4 +64,42 @@ </description> </method> </methods> + <members> + <member name="pseudolocalization_accents_enabled" type="bool" setter="set_pseudolocalization_accents_enabled" getter="is_pseudolocalization_accents_enabled" default="true"> + Replace all characters with their accented variants during pseudolocalization. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_double_vowels_enabled" type="bool" setter="set_pseudolocalization_double_vowels_enabled" getter="is_pseudolocalization_double_vowels_enabled" default="false"> + Double vowels in strings during pseudolocalization to simulate the lengthening of text due to localization. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_enabled" type="bool" setter="set_pseudolocalization_enabled" getter="is_pseudolocalization_enabled" default="false"> + If [code]true[/code], enables pseudolocalization for the project. This can be used to spot untranslatable strings or layout issues that may occur once the project is localized to languages that have longer strings than the source language. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_expansion_ratio" type="float" setter="set_pseudolocalization_expansion_ratio" getter="get_pseudolocalization_expansion_ratio" default="0.0"> + The expansion ratio to use during pseudolocalization. A value of [code]0.3[/code] is sufficient for most practical purposes, and will increase the length of each string by 30%. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_fake_bidi_enabled" type="bool" setter="set_pseudolocalization_fake_bidi_enabled" getter="is_pseudolocalization_fake_bidi_enabled" default="false"> + If [code]true[/code], emulate bidirectional (right-to-left) text when pseudolocalization is enabled. This can be used to spot issues with RTL layout and UI mirroring that will crop up if the project is localized to RTL languages such as Arabic or Hebrew. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_override_enabled" type="bool" setter="set_pseudolocalization_override_enabled" getter="is_pseudolocalization_override_enabled" default="false"> + Replace all characters in the string with [code]*[/code]. Useful for finding non-localizable strings. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_prefix" type="String" setter="set_pseudolocalization_prefix" getter="get_pseudolocalization_prefix" default=""[""> + Prefix that will be prepended to the pseudolocalized string. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_skip_placeholders_enabled" type="bool" setter="set_pseudolocalization_skip_placeholders_enabled" getter="is_pseudolocalization_skip_placeholders_enabled" default="true"> + Skip placeholders for string formatting like [code]%s[/code] or [code]%f[/code] during pseudolocalization. Useful to identify strings which need additional control characters to display correctly. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + <member name="pseudolocalization_suffix" type="String" setter="set_pseudolocalization_suffix" getter="get_pseudolocalization_suffix" default=""]""> + Suffix that will be appended to the pseudolocalized string. + [b]Note:[/b] Updating this property does not automatically update texts in the scene tree. Please propagate the [constant MainLoop.NOTIFICATION_TRANSLATION_CHANGED] notification manually after you have finished modifying pseudolocalization related options. + </member> + </members> </class> diff --git a/doc/classes/TranslationServer.xml b/doc/classes/TranslationServer.xml index 0a4965c36c..69ca984f67 100644 --- a/doc/classes/TranslationServer.xml +++ b/doc/classes/TranslationServer.xml @@ -125,12 +125,13 @@ <param index="0" name="message" type="StringName" /> <description> Returns the pseudolocalized string based on the [param message] passed in. + [b]Note:[/b] This method always uses the main translation domain. </description> </method> <method name="reload_pseudolocalization"> <return type="void" /> <description> - Reparses the pseudolocalization options and reloads the translation. + Reparses the pseudolocalization options and reloads the translation for the main translation domain. </description> </method> <method name="remove_domain"> @@ -187,7 +188,7 @@ </methods> <members> <member name="pseudolocalization_enabled" type="bool" setter="set_pseudolocalization_enabled" getter="is_pseudolocalization_enabled" default="false"> - If [code]true[/code], enables the use of pseudolocalization. See [member ProjectSettings.internationalization/pseudolocalization/use_pseudolocalization] for details. + If [code]true[/code], enables the use of pseudolocalization on the main translation domain. See [member ProjectSettings.internationalization/pseudolocalization/use_pseudolocalization] for details. </member> </members> </class> diff --git a/doc/classes/TreeItem.xml b/doc/classes/TreeItem.xml index 861a53aaad..132ecc3f92 100644 --- a/doc/classes/TreeItem.xml +++ b/doc/classes/TreeItem.xml @@ -73,6 +73,13 @@ Removes the button at index [param button_index] in column [param column]. </description> </method> + <method name="get_auto_translate_mode" qualifiers="const"> + <return type="int" enum="Node.AutoTranslateMode" /> + <param index="0" name="column" type="int" /> + <description> + Returns the column's auto translate mode. + </description> + </method> <method name="get_autowrap_mode" qualifiers="const"> <return type="int" enum="TextServer.AutowrapMode" /> <param index="0" name="column" type="int" /> @@ -493,6 +500,15 @@ Selects the given [param column]. </description> </method> + <method name="set_auto_translate_mode"> + <return type="void" /> + <param index="0" name="column" type="int" /> + <param index="1" name="mode" type="int" enum="Node.AutoTranslateMode" /> + <description> + Sets the given column's auto translate mode to [param mode]. + All columns use [constant Node.AUTO_TRANSLATE_MODE_INHERIT] by default, which uses the same auto translate mode as the [Tree] itself. + </description> + </method> <method name="set_autowrap_mode"> <return type="void" /> <param index="0" name="column" type="int" /> diff --git a/doc/classes/Vector4i.xml b/doc/classes/Vector4i.xml index 8f54b767e0..b351f2ccb6 100644 --- a/doc/classes/Vector4i.xml +++ b/doc/classes/Vector4i.xml @@ -216,7 +216,7 @@ <return type="Vector4i" /> <param index="0" name="right" type="int" /> <description> - Gets the remainder of each component of the [Vector4i] with the the given [int]. This operation uses truncated division, which is often not desired as it does not work well with negative numbers. Consider using [method @GlobalScope.posmod] instead if you want to handle negative numbers. + Gets the remainder of each component of the [Vector4i] with the given [int]. This operation uses truncated division, which is often not desired as it does not work well with negative numbers. Consider using [method @GlobalScope.posmod] instead if you want to handle negative numbers. [codeblock] print(Vector4i(10, -20, 30, -40) % 7) # Prints "(3, -6, 2, -5)" [/codeblock] |