godot/doc/classes/ScriptCreateDialog.xml
Hugo Locurcio b087538119
Add an XML schema for documentation
This makes it easier to spot syntax errors when editing the
class reference. The schema is referenced locally so validation
can still work offline.

Each class XML's schema conformance is also checked on GitHub Actions.
2022-03-16 23:01:02 +01:00

47 lines
2.2 KiB
XML

<?xml version="1.0" encoding="UTF-8" ?>
<class name="ScriptCreateDialog" inherits="ConfirmationDialog" version="3.5" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../class.xsd">
<brief_description>
The Editor's popup dialog for creating new [Script] files.
</brief_description>
<description>
The [ScriptCreateDialog] creates script files according to a given template for a given scripting language. The standard use is to configure its fields prior to calling one of the [method Popup.popup] methods.
[codeblock]
func _ready():
dialog.config("Node", "res://new_node.gd") # For in-engine types
dialog.config("\"res://base_node.gd\"", "res://derived_node.gd") # For script types
dialog.popup_centered()
[/codeblock]
</description>
<tutorials>
</tutorials>
<methods>
<method name="config">
<return type="void" />
<argument index="0" name="inherits" type="String" />
<argument index="1" name="path" type="String" />
<argument index="2" name="built_in_enabled" type="bool" default="true" />
<argument index="3" name="load_enabled" type="bool" default="true" />
<description>
Prefills required fields to configure the ScriptCreateDialog for use.
</description>
</method>
</methods>
<members>
<member name="dialog_hide_on_ok" type="bool" setter="set_hide_on_ok" getter="get_hide_on_ok" overrides="AcceptDialog" default="false" />
<member name="margin_bottom" type="float" setter="set_margin" getter="get_margin" overrides="Control" default="258.0" />
<member name="margin_right" type="float" setter="set_margin" getter="get_margin" overrides="Control" default="366.0" />
<member name="rect_size" type="Vector2" setter="_set_size" getter="get_size" overrides="Control" default="Vector2( 366, 258 )" />
<member name="window_title" type="String" setter="set_title" getter="get_title" overrides="WindowDialog" default="&quot;Attach Node Script&quot;" />
</members>
<signals>
<signal name="script_created">
<argument index="0" name="script" type="Script" />
<description>
Emitted when the user clicks the OK button.
</description>
</signal>
</signals>
<constants>
</constants>
</class>