summaryrefslogtreecommitdiff
path: root/editor/editor_inspector.h
AgeCommit message (Collapse)Author
2022-09-01Improve the editor's Add Metadata dialogHugo Locurcio
- Mention the node name in the dialog title. - Improve error messages to be more descriptive.
2022-08-26Remove Inspector tooltip hack that never actually workedYuri Sizov
2022-08-22Add per-scene UndoRedokobewi
2022-08-08Merge pull request #62868 from fire-forge/array-resize-sizeRémi Verschelde
Use a SpinBox in the inspector array resize dialog
2022-08-06Merge pull request #63712 from object71/fix-export-issuesRémi Verschelde
2022-08-03Removed faulty function update after get_property_list.Hristo Stamenov
The function tried to rearrange properties but that lead to problems with duplication or deleted properties. Implemented the logic that that function did inside the get_property_list both for tool scripts and non-tool scripts.
2022-08-02Clean-up array editingreduz
2022-07-30Improve usability of non-default values in the property inspectorPedro J. Estébanez
- Provide a visual indication that a (sub)group contains non-default (revertable) values when it's collapsed. - Add a new option to the inspector's tools menu for expanding only (sub)groups containing properties with non-default values.
2022-07-25Code quality: Fix header guards consistencyRémi Verschelde
Adds `header_guards.sh` bash script, used in CI to validate future changes. Can be run locally to fix invalid header guards.
2022-07-11Add "Open Documentation" button to EditorProperty context menuFireForge
2022-07-10Use a SpinBox in the inspector array resize dialogFireForge
2022-06-25Add ability to export Node pointers as NodePathsreduz
This PR implements: * A new hint: PROPERTY_HINT_NODE_TYPE for variant type OBJECT, which can take specific node types as hint string. * The editor will show it as a node path, but will set it as a pointer to a node from the current scene if you select a path. * When scene is saved, the node path is saved, then restored as a pointer. NOTE: This is a proof of concept and this approach will most likely not work. The reason if that, if the node referenced is deleted, then when trying to edit this the node will become invalid. Potential workarounds: Since this uses the Variant API, it should obtain the pointer from the Variant object ID. Yet, this would either only really work in GDScript or it would need to be implemented with workarounds in every language. Alternative ways to make this work: Nodes could export an additional property with a node path (like for which_node, it could be which_node_path). Another alternative: Path editing could happen as a hidden metadata (ignoring the pointer).
2022-05-25Improve style of inspector buttonskobewi
2022-05-24Reorganize Region Rect Editorreduz
Problem: * Region rect was pretty much a hidden editor. Because it was annoying for it to pop up automatically, it did not. * Because it did not, most users have no idea it even exists. * But because it is a transient editor, it would steal focus of other editor and annoy users. Solution: * Editor has been moved to a window. * Regions that can be edited add a button below the region which can be pressed to open the editor. This required a slight change in EditorInspectorPlugin to allow custom editors to be below others.
2022-05-20Add a new HashSet templatereduz
* Intended to replace RBSet in most cases. * Optimized for iteration speed
2022-05-16Replace most uses of Map by HashMapreduz
* Map is unnecessary and inefficient in almost every case. * Replaced by the new HashMap. * Renamed Map to RBMap and Set to RBSet for cases that still make sense (order matters) but use is discouraged. There were very few cases where replacing by HashMap was undesired because keeping the key order was intended. I tried to keep those (as RBMap) as much as possible, but might have missed some. Review appreciated!
2022-05-03Remove `RES` and `REF` typedefs in favor of spelled out `Ref<>`Hugo Locurcio
These typedefs don't save much typing compared to the full `Ref<Resource>` and `Ref<RefCounted>`, yet they sometimes introduce confusion among new contributors.
2022-04-05[Input] Add extra `shortcut_input` input processing step to process Unicode ↵bruvzg
character input with Alt / Ctrl modifiers, after processing of shortcuts.
2022-04-04Zero initialize all pointer class and struct membersRémi Verschelde
This prevents the pitfall of UB when checking if they have been assigned something valid by comparing to nullptr.
2022-03-28Add property name style toggle to InspectorHaoyu Qiu
2022-03-24Refactor Object metadatareduz
* API kept the same (Although functions could be renamed to set_metadata/get_metadata in a later PR), so not much should change. * Metadata now exposed as individual properties. * Properties are editable in inspector (unless metadata name begins with _) under the metadata/ namespace. * Added the ability to Add/Remove metadata properties to the inspector. This is a functionality that was requested very often, that makes metadata work a bit more similar to custom properties in Blender.
2022-03-13Merge pull request #59102 from rcorre/copy-project-configRémi Verschelde
2022-03-13Copy full project setting path from dialog.Ryan Roden-Corrent
The EditorProperty UI elements for project settings are created from SectionedInspector, which has a prefix added to each property path. Each EditorProperty needs to be made aware of this path so copy_property_path copies the full path, and not just the suffix. Fixes #59020.
2022-03-12Initialize bools in the headers in editorAaron Franke
2022-02-10Reorganize inspector layout workflow for Control nodesYuri Sizov
2022-02-09Unify array, dictionary, and inspector array editorsFireForge
2022-01-03Update copyright statements to 2022Rémi Verschelde
Happy new year to the wonderful Godot community!
2021-12-11Stop asuming a default value of NIL means there's no defaultPedro J. Estébanez
2021-11-10Fix EditorInspectorPlugin virtual bindings and add parse_group callbackYuri Sizov
2021-11-08Add property value pinningPedro J. Estébanez
2021-11-07Unify determination of default property valuesPedro J. Estébanez
2021-10-21Remove unimplemented methodsMarcel Admiraal
2021-10-05Use a yellow color for editable children properties instead of redHugo Locurcio
This matches the usual "Changes may be lost!" warning color. - Remove a duplicate editor theme color setting declaration.
2021-09-15Merge pull request #32068 from aaronfranke/transform-editorRémi Verschelde
Reformat Transform(2D) matrix display in the inspector
2021-09-07Fix undo/redo for properties set as PROPERTY_USAGE_UPDATE_ALL_IF_MODIFIEDPouleyKetchoupp
Full inspector update was triggered only on property changed, but not on undo/redo actions, which can cause inspector discrepancies when some properties are supposed to be shown or hidden. Now update all flag is passed into _edit_set() method which already has logic to handle this case properly (it still triggers update_tree() down the line).
2021-09-07Implement properties arrays in the Inspector.Gilles Roudière
2021-09-05Apply set_read_only() to child classes of EditorProperty elementsSilc 'Tokage' Renew
2021-08-31Reformat Transform(2D) inspector menusAaron Franke
Move, rename, recolor, and fix the inspector for these in the inspector. Coloring is now done by a helper method in "editor_inspector.cpp".
2021-08-23Copy/Paste property paths/values in inspector.Ryan Roden-Corrent
Resolves godotengine/godot-proposals#106. Adds the following property menu options with default bindings: - Copy Property (ctrl+c) - Paste Property (ctrl+v) - Copy Property Path (ctrl+shift+c) If you hover over a property label in the inspector dock, you can copy either the property value or the property path to the system clipboard using the shortcuts above This is especially useful for the `AnimationTree`, where code might reference properties like "parameters/state/aim/move/blend_position". One issue is that if you click a property, then click on the node you currently have selected in the node tree, then press ctrl+shift+c, it will still copy the selected property path rather than the node path. If you click on a different node in the nodetree, however, ctrl+shift+c will return to copying the nodepath. The property value copy/paste was implemented by @KoBeWi at #39398 and merged into this PR due to their similarity.
2021-08-23Entirely removes BIND_VMETHOD in favor of GDVIRTUALreduz
* `_gui_input`, `_input`, `_unhandled_input` and `_unhandled_key_input` are now regular C++ virutal functions. * Everything else converted to GDVIRTUAL * BIND_VMETHOD is gone, always use the new syntax from now on. Creating `_gui_input` method and using the binder to register events will no longer work, simply override the virtual function now.
2021-08-22Replace BIND_VMETHOD by new GDVIRTUAL syntaxreduz
* New syntax is type safe. * New syntax allows for type safe virtuals in native extensions. * New syntax permits extremely fast calling. Note: Everything was replaced where possible except for `_gui_input` `_input` and `_unhandled_input`. These will require API rework on a separate PR as they work different than the rest of the functions. Added a new method flag METHOD_FLAG_OBJECT_CORE, used internally. Allows to not dump the core virtuals like `_notification` to the json API, since each language will implement those as it is best fits.
2021-08-02Fix up property reversionPedro J. Estébanez
2021-07-30Rationalize property reversionPedro J. Estébanez
2021-07-01Use PROPERTY_USAGE_NONE instead of 0 for no property usageAaron Franke
Also use const more often.
2021-06-19Rename `instance()`->`instantiate()` when it's a verbLightning_A
2021-06-11Rename Reference to RefCountedPedro J. Estébanez
2021-06-02Use bold fonts in editorreduz
* Labels are now bold * Categories in trees are bold * Main editor buttons are bold * Fixed section folding arrows in inspector
2021-02-18Reorganize Project Settingsreduz
-Advanced Settings toggle also hides advanced properties when disabled -Simplified Advanced Bar (errors were just plain redundant) -Reorganized rendering quality settings. -Reorganized miscelaneous settings for clean up.
2021-02-12Improved Inspector Sub-Resource Editingreduz
-Better margins -Colors to delimit subresources better.
2021-02-10Removed _change_notifyreduz
-For inspector refresh, the inspector now detects if a property change by polling a few times per second and then does update the control if so. This process is very cheap. -For property list refresh, a new signal (property_list_changed) was added to Object. _change_notify() is replaced by notify_property_list_changed() -Changed all objects using the old method to the signal, or just deleted the calls to _change_notify(<property>) since they are unnecesary now.