summaryrefslogtreecommitdiffstats
path: root/modules/visual_script/visual_script_editor.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Rename AcceptDialog get_ok() to get_ok_button()Marcel Admiraal2020-12-141-5/+5
| | | | | | Also renames: - AcceptDialog add_cancel() to add_cancel_button() - ConfirmationDiaglog get_cancel() to get_cancel_button()
* Merge pull request #42109 from EricEzaM/PR/input-and-shortcuts-reworkRémi Verschelde2020-11-281-1/+1
|\ | | | | Shortcuts rework - fixed issues with input propagation and triggering of unwanted shortcuts.
| * Implement new shortcuts system.Eric M2020-11-231-1/+1
| | | | | | | | unhandled_key_input changed to unhandled_button_input. Controls can set a 'shortcut_context' which they can then use to determine if their shortcuts should be triggered or not, based on if the viewport's focused GUI control is a child of their 'shortcut context'.
* | [Complex Text Layouts] Refactor Font class, default themes and controls to ↵bruvzg2020-11-261-0/+1
|/ | | | | | | | use Text Server interface. Implement interface mirroring. Add TextLine and TextParagraph classes. Handle UTF-16 input on macOS and Windows.
* Variant: Rename Type::_RID to Type::RIDRémi Verschelde2020-11-091-2/+2
| | | | | | | | The underscore prefix was used to avoid the conflict between the `RID` class name and the matching enum value in `Variant::Type`. This can be fixed differently by prefixing uses of the `RID` class in `Variant` with the scope resolution operator, as done already for `AABB`.
* Refactored variant constructor logicreduz2020-11-091-4/+7
|
* Reorganized core/ directory, it was too fatty alreadyreduz2020-11-071-3/+3
| | | | | | -Removed FuncRef, since Callable makes it obsolete -Removed int_types.h as its obsolete in c++11+ -Changed color names code
* Removed underscore from GraphEdit begin/end_node_move signalsYuri Roubinsky2020-10-201-2/+2
|
* Refactor MethodBind to use variadic templatesreduz2020-10-181-1/+1
| | | | Removed make_binders and the old style generated binders.
* Merge pull request #41861 from Razoric480/fix-vscript-value-by-typeRémi Verschelde2020-09-181-2/+14
|\ | | | | Add a function to sanitize variant values in visual script
| * Add a VScript func to sanitize variant valuesFrancois Belair2020-09-181-2/+14
| | | | | | | | Fixes #27611
* | Add main_gutter (breakpoints, bookmarks, execution lines) to code_editPaulb232020-09-101-2/+4
|/
* Make unsaved scripts in the script editor more user-friendlyAndrii Doroshenko (Xrayez)2020-07-261-1/+8
| | | | | | | | | | | | | | | Unsaved scripts were previously displayed with blank tabs, which are mostly a result of deleted or improperly moved scripts. This patch makes sure that those kind of scripts are displayed as "[unsaved]" now, and ensures that scripts are removed from the list while deleting scripts from the filesystem dock preventing the unsaved tabs to appear in the first place (a user is already prompted with "no undo" warning while deleting any file). A user is always prompted to save those "[unsaved]" scripts if they attempt to close them without saving in any case except as described above.
* Optimized ScriptEditor initialization when many scripts are loadedPouleyKetchoupp2020-07-171-0/+5
| | | | | | | | | | | | | | This change avoids the editor to freeze for several seconds when a project with lots of scripts is loaded in the editor. It focuses on a few heavy operations previously executed on all previously loaded scripts: - Initialize script resource (script validation/parsing) only on focus - ScriptTextEditor: code editor and edit menu are added to the scene only on focus - Add to recent scripts only when opening new scripts (load/save scene metadata)
* Extract Syntax highlighting from TextEdit and add EditorSyntaxHighlighterPaulb232020-07-111-2/+2
| | | | | | | | - Extacted all syntax highlighting code from text edit - Removed enable syntax highlighting from text edit - Added line_edited_from signal to text_edit - Renamed get/set_syntax_highlighting to get/set_syntax_highlighter - Added EditorSyntaxHighligher
* Expose Syntax highlighter for editor pluginsPaulb232020-07-111-0/+2
|
* Convert syntax highlighters into a resourcePaulb232020-07-111-2/+2
|
* Fix crashing of VisualScript due to...Swarnim Arun2020-05-251-0/+6
| | | | | Attempting to move the function node to another function whose data connection is a dependency of the node the specific node being moved to a different function during changes to sequence connections. By skipping, if the from_node is a function_node during the data connection dependencies scan. Should fix #37991
* Style: Enforce braces around if blocks and loopsRémi Verschelde2020-05-141-107/+201
| | | | | Using clang-tidy's `readability-braces-around-statements`. https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html
* Style: Enforce separation line between function definitionsRémi Verschelde2020-05-141-0/+1
| | | | | | | | | | | | | | | | | | | | | | | I couldn't find a tool that enforces it, so I went the manual route: ``` find -name "thirdparty" -prune \ -o -name "*.cpp" -o -name "*.h" -o -name "*.m" -o -name "*.mm" \ -o -name "*.glsl" > files perl -0777 -pi -e 's/\n}\n([^#])/\n}\n\n\1/g' $(cat files) misc/scripts/fix_style.sh -c ``` This adds a newline after all `}` on the first column, unless they are followed by `#` (typically `#endif`). This leads to having lots of places with two lines between function/class definitions, but clang-format then fixes it as we enforce max one line of separation. This doesn't fix potential occurrences of function definitions which are indented (e.g. for a helper class defined in a .cpp), but it's better than nothing. Also can't be made to run easily on CI/hooks so we'll have to be careful with new code. Part of #33027.
* Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocksRémi Verschelde2020-05-141-200/+0
| | | | | | | | | | | | | | Which means that reduz' beloved style which we all became used to will now be changed automatically to remove the first empty line. This makes us lean closer to 1TBS (the one true brace style) instead of hybridating it with some Allman-inspired spacing. There's still the case of braces around single-statement blocks that needs to be addressed (but clang-format can't help with that, but clang-tidy may if we agree about it). Part of #33027.
* Style: clang-format: Disable AllowShortCaseLabelsOnASingleLineRémi Verschelde2020-05-101-72/+200
| | | | Part of #33027.
* Rename InputFilter back to InputRémi Verschelde2020-04-281-14/+14
| | | | | | | | | | | | | | | | It changed name as part of the DisplayServer and input refactoring in #37317, with the rationale that input no longer goes through the main loop, so the previous Input singleton now only does filtering. But the gains in consistency are quite limited in the renaming, and it breaks compatibility for all scripts and tutorials that access the Input singleton via the scripting language. A temporary option was suggested to keep the scripting singleton named `Input` even if its type is `InputFilter`, but that adds inconsistency and breaks C#. Fixes godotengine/godot-proposals#639. Fixes #37319. Fixes #37690.
* Merge pull request #37542 from swarnimarun/patch_vs_02Rémi Verschelde2020-04-121-0/+5
|\ | | | | Update visualscript graph nodes on visual script variable edit
| * Update vsnodes on editing vs variablesSwarnim Arun2020-04-031-0/+5
| |
* | Merge pull request #37530 from swarnimarun/patch_vs_01Rémi Verschelde2020-04-101-0/+16
|\ \ | | | | | | VisualScript support for newly added Variant types
| * | VisualScript styling for new Variant TypesSwarnim Arun2020-04-031-0/+16
| |/
* / Remove Node.get_position_in_parent()Tomasz Chabora2020-04-061-1/+1
|/
* Replace NULL with nullptrlupoDharkael2020-04-021-11/+11
|
* Popups are now windows also (broken!)Juan Linietsky2020-03-261-83/+83
|
* Working multiple window support, including editorJuan Linietsky2020-03-261-6/+3
|
* Refactored input, goes all via windows now.Juan Linietsky2020-03-261-14/+14
| | | | Also renamed Input to InputFilter because all it does is filter events.
* Added a Window node, and made it the scene root.Juan Linietsky2020-03-261-1/+1
| | | | Still a lot of work to do.
* Refactored Input, create DisplayServer and DisplayServerX11Juan Linietsky2020-03-261-1/+1
|
* Style: Set clang-format Standard to Cpp11Rémi Verschelde2020-03-171-18/+18
| | | | | | | | | | For us, it practically only changes the fact that `A<A<int>>` is now used instead of the C++03 compatible `A<A<int> >`. Note: clang-format 10+ changed the `Standard` arguments to fully specified `c++11`, `c++14`, etc. versions, but we can't use `c++17` now if we want to preserve compatibility with clang-format 8 and 9. `Cpp11` is still supported as deprecated alias for `Latest`.
* Merge pull request #18020 from bruvzg/input_fix_non_latin_and_add_hw_scancodesRémi Verschelde2020-03-011-1/+1
|\ | | | | Fix non-latin layout scancodes on Linux, adds access to physical scancodes.
| * Rename `scancode` to `keycode`.bruvzg2020-02-251-1/+1
| | | | | | | | | | Add `physical_keycode` (keyboard layout independent keycodes) to InputEventKey and InputMap. Fix non-latin keyboard layout keycodes on Linux/X11 (fallback to physical keycodes).
* | Signals: Port connect calls to use callable_mpRémi Verschelde2020-02-281-108/+54
| | | | | | | | | | | | | | | | | | Remove now unnecessary bindings of signal callbacks in the public API. There might be some false positives that need rebinding if they were meant to be public. No regular expressions were harmed in the making of this commit. (Nah, just kidding.)
* | Fix resizer icon color in VisualScripts/Shaders when graph headers is onYuri Roubinsky2020-02-261-2/+10
| |
* | Variant: Added 64-bit packed arrays, renamed Variant::REAL to FLOAT.Juan Linietsky2020-02-251-12/+16
|/ | | | | | | | | | | | | | | | | | | | | - Renames PackedIntArray to PackedInt32Array. - Renames PackedFloatArray to PackedFloat32Array. - Adds PackedInt64Array and PackedFloat64Array. - Renames Variant::REAL to Variant::FLOAT for consistency. Packed arrays are for storing large amount of data and creating stuff like meshes, buffers. textures, etc. Forcing them to be 64 is a huge waste of memory. That said, many users requested the ability to have 64 bits packed arrays for their games, so this is just an optional added type. For Variant, the float datatype is always 64 bits, and exposed as `float`. We still have `real_t` which is the datatype that can change from 32 to 64 bits depending on a compile flag (not entirely working right now, but that's the idea). It affects math related datatypes and code only. Neither Variant nor PackedArray make use of real_t, which is only intended for math precision, so the term is removed from there to keep only float.
* Replace FALLTHROUGH macro by C++17 [[fallthrough]]Rémi Verschelde2020-02-231-1/+1
| | | | | | | | | | This attribute is now part of the standard we target so we no longer need compiler-specific hacks. Also enables -Wimplicit-fallthrough for Clang now that we can properly support it. It's already on by default for GCC's -Wextra. Fixes new warnings raised by Clang's -Wimplicit-fallthrough.
* Reworked signal connection system, added support for Callable and Signal ↵Juan Linietsky2020-02-201-55/+55
| | | | objects and made them default.
* PoolVector is gone, replaced by VectorJuan Linietsky2020-02-181-29/+29
| | | | | Typed `PoolTypeArray` types are now renamed `PackedTypeArray` and are sugar for `Vector<Type>`.
* Changed logic and optimized ObjectID in ObjectDB and Variant, removed RefPtr.Juan Linietsky2020-02-151-2/+2
|
* Texture refactorJuan Linietsky2020-02-111-10/+10
| | | | | | | | -Texture renamed to Texture2D -TextureLayered as base now inherits 2Darray, cubemap and cubemap array -Removed all references to flags in textures (they will go in the shader) -Texture3D gone for now (will come back later done properly) -Create base rasterizer for RenderDevice, RasterizerRD
* Makes adding port in Visual Script nodes deferredHaoyu Qiu2020-01-141-2/+2
|
* Update copyright statements to 2020Rémi Verschelde2020-01-011-2/+2
| | | | | | | | | | | Happy new year to the wonderful Godot community! We're starting a new decade with a well-established, non-profit, free and open source game engine, and tons of further improvements in the pipeline from hundreds of contributors. Godot will keep getting better, and we're looking forward to all the games that the community will keep developing and releasing with it.
* Cleans up headers included in editor_node.hHaoyu Qiu2019-12-241-0/+1
|
* Makes more editor strings translatableHaoyu Qiu2019-12-211-2/+2
| | | | | | | | | | * "Add" button text in Groups Editor * "Receiver Method" in Connect Signal Dialog * "Play Mode" in Animation State Machine Editor * "Mesh Library" button text in Mesh Library editor plugin * Compose Array node button texts in Visual Script * Various button texts in TileSet Editor * Various Run Script errors
* Fixes size of create function dialogHaoyu Qiu2019-12-171-1/+1
|