Bind goto_line function for Script Editor #9153

- added doc for ScriptEditor:goto_line
This commit is contained in:
mawenzy 2019-04-09 22:07:13 +02:00
parent 7a0c086e45
commit d87021de93
2 changed files with 10 additions and 0 deletions

View file

@ -57,6 +57,15 @@
Returns an array with all [Script] objects which are currently open in editor. Returns an array with all [Script] objects which are currently open in editor.
</description> </description>
</method> </method>
<method name="goto_line">
<return type="void">
</return>
<argument index="0" name="line_number" type="int">
</argument>
<description>
Goes to the specified line in the current script.
</description>
</method>
<method name="open_script_create_dialog"> <method name="open_script_create_dialog">
<return type="void"> <return type="void">
</return> </return>

View file

@ -2883,6 +2883,7 @@ void ScriptEditor::_bind_methods() {
ClassDB::bind_method(D_METHOD("can_drop_data_fw", "point", "data", "from"), &ScriptEditor::can_drop_data_fw); ClassDB::bind_method(D_METHOD("can_drop_data_fw", "point", "data", "from"), &ScriptEditor::can_drop_data_fw);
ClassDB::bind_method(D_METHOD("drop_data_fw", "point", "data", "from"), &ScriptEditor::drop_data_fw); ClassDB::bind_method(D_METHOD("drop_data_fw", "point", "data", "from"), &ScriptEditor::drop_data_fw);
ClassDB::bind_method(D_METHOD("goto_line", "line_number"), &ScriptEditor::_goto_script_line2);
ClassDB::bind_method(D_METHOD("get_current_script"), &ScriptEditor::_get_current_script); ClassDB::bind_method(D_METHOD("get_current_script"), &ScriptEditor::_get_current_script);
ClassDB::bind_method(D_METHOD("get_open_scripts"), &ScriptEditor::_get_open_scripts); ClassDB::bind_method(D_METHOD("get_open_scripts"), &ScriptEditor::_get_open_scripts);
ClassDB::bind_method(D_METHOD("open_script_create_dialog", "base_name", "base_path"), &ScriptEditor::open_script_create_dialog); ClassDB::bind_method(D_METHOD("open_script_create_dialog", "base_name", "base_path"), &ScriptEditor::open_script_create_dialog);