diff options
Diffstat (limited to 'doc/classes/GraphEdit.xml')
-rw-r--r-- | doc/classes/GraphEdit.xml | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/doc/classes/GraphEdit.xml b/doc/classes/GraphEdit.xml index c432410d3b..575697f20d 100644 --- a/doc/classes/GraphEdit.xml +++ b/doc/classes/GraphEdit.xml @@ -109,6 +109,14 @@ Removes the connection between the [code]from_port[/code] slot of the [code]from[/code] GraphNode and the [code]to_port[/code] slot of the [code]to[/code] GraphNode. If the connection does not exist, no connection is removed. </description> </method> + <method name="force_connection_drag_end"> + <return type="void" /> + <description> + Ends the creation of the current connection. In other words, if you are dragging a connection you can use this method to abort the process and remove the line that followed your cursor. + This is best used together with [signal connection_drag_started] and [signal connection_drag_ended] to add custom behavior like node addition through shortcuts. + [b]Note:[/b] This method suppresses any other connection request signals apart from [signal connection_drag_ended]. + </description> + </method> <method name="get_connection_line"> <return type="PackedVector2Array" /> <argument index="0" name="from" type="Vector2" /> @@ -206,6 +214,9 @@ <member name="minimap_size" type="Vector2" setter="set_minimap_size" getter="get_minimap_size" default="Vector2(240, 160)"> The size of the minimap rectangle. The map itself is based on the size of the grid area and is scaled to fit this rectangle. </member> + <member name="panning_scheme" type="int" setter="set_panning_scheme" getter="get_panning_scheme" enum="GraphEdit.PanningScheme" default="0"> + Defines the control scheme for panning with mouse wheel. + </member> <member name="rect_clip_content" type="bool" setter="set_clip_contents" getter="is_clipping_contents" overrides="Control" default="true" /> <member name="right_disconnects" type="bool" setter="set_right_disconnects" getter="is_right_disconnects_enabled" default="false"> If [code]true[/code], enables disconnection of existing connections in the GraphEdit by dragging the right end. @@ -241,6 +252,19 @@ Emitted at the beginning of a GraphNode movement. </description> </signal> + <signal name="connection_drag_ended"> + <description> + Emitted at the end of a connection drag. + </description> + </signal> + <signal name="connection_drag_started"> + <argument index="0" name="from" type="String" /> + <argument index="1" name="slot" type="String" /> + <argument index="2" name="is_output" type="bool" /> + <description> + Emitted at the beginning of a connection drag. + </description> + </signal> <signal name="connection_from_empty"> <argument index="0" name="to" type="StringName" /> <argument index="1" name="to_slot" type="int" /> @@ -324,6 +348,14 @@ </description> </signal> </signals> + <constants> + <constant name="SCROLL_ZOOMS" value="0" enum="PanningScheme"> + [kbd]Mouse Wheel[/kbd] will zoom, [kbd]Ctrl + Mouse Wheel[/kbd] will move the view. + </constant> + <constant name="SCROLL_PANS" value="1" enum="PanningScheme"> + [kbd]Mouse Wheel[/kbd] will move the view, [kbd]Ctrl + Mouse Wheel[/kbd] will zoom. + </constant> + </constants> <theme_items> <theme_item name="activity" data_type="color" type="Color" default="Color(1, 1, 1, 1)"> </theme_item> @@ -346,7 +378,7 @@ <theme_item name="port_grab_distance_horizontal" data_type="constant" type="int" default="24"> The horizontal range within which a port can be grabbed (on both sides). </theme_item> - <theme_item name="port_grab_distance_vertical" data_type="constant" type="int" default="6"> + <theme_item name="port_grab_distance_vertical" data_type="constant" type="int" default="26"> The vertical range within which a port can be grabbed (on both sides). </theme_item> <theme_item name="layout" data_type="icon" type="Texture2D"> |