Commit graph

6027 commits

Author SHA1 Message Date
K. S. Ernest (iFire) Lee f189d0e1f3 Allow gltf2 morph targets with no default values. Changes for bug 38751
(cherry picked from commit 71ae0ff46d)
2020-07-24 09:37:43 +02:00
Hugo Locurcio 3bdb39bec4 Add a margin to EditorSpinSlider to visually line up the edited number
This means clicking on an EditorSpinSlider to edit its value will
no longer cause the number to be visually offset while it's
being edited.

(cherry picked from commit cc615fee5f)
2020-07-24 09:34:58 +02:00
Rémi Verschelde a06ee5e763 PO loader: Fix unclosed files and error messages
Fixes #40324.

(cherry picked from commit 47cc202972)

Also removes empty `p_path` as done in 4857648a16.
2020-07-15 12:48:18 +02:00
Jitesh f6479786c0 change minimum horizontal size from 200 to 240
(cherry picked from commit a8905b2a4e)
2020-07-15 12:11:31 +02:00
Michael Alexsander e7e022b3ee Prefer the highlight version of the "GuiTabIcon" icon for buttons, and make their width/height equal
(cherry picked from commit 26381265b8)
2020-07-15 12:11:31 +02:00
Zae ac3ff49ae5 fix item_edited behavior on Asset Installer.
(cherry picked from commit b0fbde6abd)
2020-07-13 15:11:33 +02:00
coldragon a0f0aa1741 Fix crash on editor without a feature profile
(cherry picked from commit f2a01b0c6b)
2020-07-10 11:01:31 +02:00
Chistpohe LY 130ad08d47 auto re-import atlas, fixes #40047
(cherry picked from commit f34f00bccc)
2020-07-10 11:00:10 +02:00
Daniel Ting c55e68d311 Do not try to save internal scripts
Fixes #40175

(cherry picked from commit d6c979d91b)
2020-07-10 10:37:33 +02:00
PouleyKetchoupp fe0adc4f77 Keep debug & verbose options after loading project from project manager
(cherry picked from commit b2d27214aa)
2020-07-10 08:51:21 +02:00
Yuri Sizov 3f57cb12b4 Improve null check in FindReplaceBar
(cherry picked from commit e94b8a6acc)
2020-07-08 09:01:57 +02:00
Yuri Sizov bd90f236d3 Improve scene preview generation for empty scenes and disabled features
(cherry picked from commit 6c8a9b7690)
2020-07-08 09:01:57 +02:00
bruvzg e9ab41b71d
[macOS, 3.2] Implement seamless display scaling. 2020-07-07 22:54:33 +03:00
Yuri Sizov 2b4773f0cf Expose methods to play scene from plugin code
(cherry picked from commit 49f6dc5004)
2020-07-06 19:00:56 +02:00
Andrii Doroshenko (Xrayez) 41f99c8f53 Provide warning when using polygon shapes in CollisionShape2D node
`ConvexPolygonShape2D` and `ConcavePolygonShape2D` are only meant to be
used directly in code and not in the editor for physics-based use cases
specifically.

Developers are advised to use `CollisionPolygon2D` instead, which does
generate those shapes under the hood, handling polygon convexivity,
proper orientation etc.

(cherry picked from commit dc446203be)
2020-07-06 14:16:28 +02:00
Maganty Rushyendra 68526da5f2 Fix undo/redo for bone painting in Polygon2D UV Editor
Fix to ensure that undo/redo works when painting bones in the Polygon2D
UV editor. Previously, bone painting would continue silently in the
background, because a mouse click signalling the end of an edit would
not be appropriately dealt with.

(cherry picked from commit 6e60aa3876)
2020-07-06 14:13:58 +02:00
Riley Lyman 157e810b2e Make Resource properties accept SE plugin scripts
(cherry picked from commit ab0fe13efb)
2020-07-03 15:34:30 +02:00
Michael Alexsander 0924a3ac55 Fix timeline cursor not updating on zoom change in the Bezier editor
(cherry picked from commit eee9d053a3)
2020-07-03 15:34:30 +02:00
Michael Alexsander a9ef40b388 Remove oversized margins in the AnimationTree editor
(cherry picked from commit 4f00ac7003)
2020-07-03 15:34:30 +02:00
Michael Alexsander f2fe197398 Make timeline cursor in the Bezier editor just as thick as the Animation editor
(cherry picked from commit 20c1196bb0)
2020-07-03 15:34:30 +02:00
Daniel Ting 35523a46c0 Make "Close and save changes?" actually save
This fixes issue #39844, where the confirmation dialog when a user
attempts to close an unsaved script did not actually save it even after
clicking "Save."

(cherry picked from commit d2a5b92e9b)
2020-07-03 13:17:57 +02:00
follower 9388237e2d Revert "Adds fuzzy search for help search dialog"
This reverts commit 481dbceed0.

Current fuzzy search implementation results in too many
non-useful results.

Could be re-added after result sort/filter/score functionality
is added. See #30072 for example existing implementation.

Fixes: #39128

Reverts: #32043

Fixed format style conflicts:
	editor/editor_help_search.cpp

(cherry picked from commit 55d706c352)
2020-07-03 13:17:57 +02:00
Stijn Hinlopen cdb9b51ed1 Add Control to preferred types
(cherry picked from commit ec86d32684)

Fix crash by calculating wrong size of array.

(cherry picked from commit 81b6000812)
2020-07-03 13:17:57 +02:00
lordkettune c68ef4d754 Fix issues with custom tracks on reimport
(cherry picked from commit 4313a7bdc8)
2020-07-03 13:17:57 +02:00
Stijn Hinlopen 4c54f39dbe Deleting multiple nodes displays correct message.
(cherry picked from commit 8b046ed477)
2020-07-03 13:17:57 +02:00
Haoyu Qiu 38509f1a89 Prevent dragging from SceneTree buttons
(cherry picked from commit 45d0799b5b)
2020-07-03 13:17:57 +02:00
PouleyKetchoupp 83e376e731 Format remote printerr properly in script debugger output
Fixes #33324
2020-07-02 17:43:37 +02:00
Maganty Rushyendra 6bd7fd0a00 Fix accidental duplication of Polygon2D start point
Ensures that closure of Polygon2D in the editor takes into account
Grid Snap if enabled. Does this by comparing the polygon start with
grid snap applied to mouse click location. Note: transformation is
applied in order to deal with different editor zoom levels.

(cherry picked from commit b8d55b244a)
2020-06-29 10:59:04 +02:00
Tomasz Chabora 7bd101b5c5 Generate inspector preview for Image resources
(cherry picked from commit eb6a367cb7)
2020-06-29 10:57:00 +02:00
Stijn Hinlopen c029a03bc3 Remove directory search results
(cherry picked from commit c33707e9b4)
2020-06-29 10:56:32 +02:00
Rémi Verschelde 636b1e4518 CanvasItemEditor: Fix losing position for drag'n'dropped scenes
Fixes #26549.
Supersedes #36309.

(cherry picked from commit a403131a25)
2020-06-29 10:48:07 +02:00
Hugo Locurcio 8cc3d4bda6 Keep the bottom panel visible when enabling the distraction-free mode
- Document the `EditorInterface.distraction_free_mode` property.

This closes https://github.com/godotengine/godot-proposals/issues/951.

(cherry picked from commit e6352d1daa)
2020-06-29 10:46:05 +02:00
Andrii Doroshenko (Xrayez) 63523e56e1 Don't use arbitrary theme editor icons for scripts with the same name
The existing theme editor icon could be unintentionally set for any
global class with matching name (`Group` icon, `Group` class_name etc),
which would only show up in the "Create Dialog" context, but not the
scene tree dock.

This change prevents this behavior, and ensures that the icon can be
actually overidden by explicit icon path in `class_name`, if there's any
custom icon to begin with.

The correct built-in type's icon is fetched for child classes if there
are no custom icons detected throughout base classes as well, so it
isn't left empty for those cases.

(cherry picked from commit c177308f80)
2020-06-26 08:10:24 +02:00
Rémi Verschelde 76fa1724b3
Merge pull request #39395 from asmaloney/fix-macos-scrollwheel-zoom
[3.2][macOS] Control key + scroll wheel should zoom not pan
2020-06-25 11:22:24 +02:00
Rémi Verschelde a84f081160 i18n: Sync translations with Weblate 2020-06-25 10:42:19 +02:00
Andrii Doroshenko (Xrayez) 6dee6477dd Optimize class icon loading
`get_global_class_name` for `GDScriptLanguage` is slow because
it forces to parse an entire script each time. This patch ensures
that the icon is actually fetched from the EditorData where they
are loaded beforehand.

This change also makes the behavior consistent with the existing
`get_object_icon` method in EditorNode.

(cherry picked from commit 4a86e2bb76)
2020-06-24 22:52:05 +02:00
Bill d4a1bc475a Fix overlapping hotkey designations for save all scenes and save all scripts
(cherry picked from commit acdcda9033)
2020-06-24 22:52:05 +02:00
Yuri Roubinsky 5be4e10f4e Fix error label clicking in status bar for shader editor
(cherry picked from commit 25cb5a42e0)
2020-06-24 22:52:05 +02:00
Maganty Rushyendra 0f30fa8fbd Enable finer grained control when creating polygon with UV Editor
Modifies polygon auto-completion based on UV editor scale, in order
to enable finer grained control for the user. Enables selection of
points closer than the current threshold of 8 pixels.

(cherry picked from commit 69d0d89214)
2020-06-24 22:52:05 +02:00
Hugo Locurcio 0867fc2c4c Draw horizontal lines and labels in the editor performance monitors
This partially addresses
https://github.com/godotengine/godot-proposals/issues/1014.

(cherry picked from commit a593786d09)
2020-06-24 22:52:05 +02:00
Aaron Franke 44c3908c7b Avoid errors when the editor camera is inside the focused object
Prevent the gizmo distance from being zero by MAX-ing it with CMP_EPSILON

(cherry picked from commit ed2bbdbbef)
2020-06-22 12:04:52 +02:00
Rémi Verschelde 000db65d40 i18n: Sync translations with Weblate 2020-06-22 08:43:14 +02:00
Vorblen 4c638f98ab Fix "Fully Axis-Locked" Freelook Navigation Scheme
Co-authored-by: Aaron Franke <arnfranke@yahoo.com>
(cherry picked from commit 29e901c342)
2020-06-21 21:48:12 +02:00
Maganty Rushyendra 7e3d7417e3 Fix overwrite of manual changes in export_presets.cfg when export dialog is opened
Ensures that behavior when export_presets.cfg file is edited manually
while editor is running remains identical to before commit 44094b0.

(cherry picked from commit 4a7c19e719)
2020-06-21 21:41:39 +02:00
Hugo Locurcio 371f1e951e Replace the AssetLib tab icon with a less confusing design
This closes https://github.com/godotengine/godot-proposals/issues/818.

(cherry picked from commit ebabedc615)
2020-06-21 21:40:39 +02:00
Hugo Locurcio c5d70fc6a6 Scroll horizontally when holding Shift with Scroll to Pan enabled
This closes https://github.com/godotengine/godot-proposals/issues/1077.

(cherry picked from commit 84e1c5e4c3)
2020-06-21 21:40:10 +02:00
Sl3dge78 6e835a4820 Autofilled path gets set properly on animation subresources
(cherry picked from commit d731f43794)
2020-06-21 21:39:23 +02:00
Dominik 'dreamsComeTrue' Jasiński af43748dd5 Prevent having spaces in signal's method in Connect Dialog
Fixes: #39647
(cherry picked from commit 79f46da1a3)
2020-06-21 21:38:17 +02:00
Sl3dge78 d99f6c4d5c Fix #20467. The "Anim imported" warning gets displayed properly when working on imported anims.
(cherry picked from commit 95cd74fc4b)
2020-06-21 21:36:12 +02:00
Tomasz Chabora 8f3eec930b Add unique icon to Polygon2D
(cherry picked from commit 225622e5e3)
2020-06-21 21:33:23 +02:00
Maganty Rushyendra ae59e22cdd Fix editor texture preview for certain specific dimensions
Ensures no error is issued when attempting to preview a resource that
may be scaled down to <1 pixel when resizing to fit the thumbnail.

(cherry picked from commit c7a8dc7bb9)
2020-06-18 12:00:05 +02:00
Bojidar Marinov 1c801dd044 Fix a random crash in the TileSet editor
Occurred when selecting polygon collision mode, then drawing a single point, then selecting rectangle mode, and finally trying to select a rectangle.

(cherry picked from commit 7850d0316f)
2020-06-18 11:29:28 +02:00
Hugo Locurcio d4dd80afe7 Restore previous mouse position when leaving the editor freelook mode
- Remove the crosshair as it no longer serves a purpose (the cursor will
  now appear where the user "expects" it to).

This closes https://github.com/godotengine/godot-proposals/issues/1076.

(cherry picked from commit 4a542e0007)
2020-06-18 11:29:28 +02:00
Rémi Verschelde bf913d6917 DocData: Skip language-specific ClassDoc without methods/constants
Removes the useless `@C#`, `@NativeScript` and `@VisualScript` entries.

(cherry picked from commit ba0db95909)
2020-06-18 11:29:28 +02:00
Stijn Hinlopen dc7f555783 Search result highlights follow font size
(cherry picked from commit a86521d0bd)
2020-06-18 11:29:28 +02:00
Maganty Rushyendra 3b52ea4b43 Fix code editor Replace tool to work with 'Selection Only' option
Ensures that when the `Selection Only` option is selected, the Replace
tool replaces occurrences of the search phrase only within the selected
region, and in order of occurrence.

(cherry picked from commit 2be3a33cc3)
2020-06-18 11:29:28 +02:00
Hugo Locurcio 5200ff03d2 Display freelook speed and zoom in units in the 3D editor viewport
Now that the 3D editor grid is infinite and adjusts its step automatically,
this helps people get a better sense of scale when moving around in the
3D viewport.

This also fixes the indicator bar drawing on hiDPI displays.

(cherry picked from commit eaae50fe4a)
2020-06-18 11:29:28 +02:00
Tomasz Chabora d46ab53b41 Allow duplicating files when holding Control
(cherry picked from commit b426d11d86)
2020-06-18 11:29:27 +02:00
Tomasz Chabora 202ca3ce7f Link exposed set/getters in property descriptions
(cherry picked from commit ea07acb877)
2020-06-18 10:51:45 +02:00
Andy Maloney f4640af9c1 [3.2][macOS] Control key + scroll wheel should zoom not pan
Fixes godotengine/godot#32520
2020-06-15 10:23:11 -04:00
Rémi Verschelde 35a5ebb44d i18n: Sync translations with Weblate
Remove 'de_CH' translation (4% complete) to default to the 100%
complete 'de' one.

Fixes #32625.
2020-06-15 14:34:35 +02:00
Maganty Rushyendra ffb423bc76 Fix match count for whole word search in editor
Check if a match borders a new line char when incrementing match counts.

(cherry picked from commit 91bdc77d47)
2020-06-15 14:34:35 +02:00
Tomasz Chabora 157c89aa2d Delete bus effect with Delete key
(cherry picked from commit 05656f2b29)
2020-06-15 14:34:35 +02:00
Maganty Rushyendra be0eba0f75 Fix whole word search slowdown in editor
Reduce repeated iteration through the full text
when counting the number of occurrences of whole
words while searching a file in the editor.

(cherry picked from commit 2433287871)
2020-06-15 14:34:35 +02:00
Tomasz Chabora 355868a5db Fix custom types in node list search
(cherry picked from commit 22f0de8a83)
2020-06-15 14:34:34 +02:00
Rémi Verschelde ba47cdf815
Merge pull request #39501 from hilfazer/favourite-project-button
Fixed 'Favourite' button in Project Manager
2020-06-15 09:28:43 +02:00
hilfazer 14fcd20e86 Fixed "Favourite Project" button in Project Manager 2020-06-13 11:38:29 +02:00
Rémi Verschelde 6c9b7c27d5
Merge pull request #39428 from fire/gltf-lights
[3.2] Add GLTF light import
2020-06-11 22:40:47 +02:00
Rémi Verschelde d68e631566 i18n: Sync translations with Weblate 2020-06-11 10:00:07 +02:00
Maganty Rushyendra 0efa59bfdc Account for file deletion and renaming in Export Presets
Ensure that presets are updated with the latest files when
starting up or opening the Project Export dialog. Fixes the
error where Godot would attempt to export deleted files that
were previously selected.

(cherry picked from commit 44094b082d)
2020-06-11 10:00:06 +02:00
SaviHex fda49b74a1 Added a "title" attribute for the link tag in the docs xml
(cherry picked from commit 18c08f65d6)
2020-06-11 09:44:14 +02:00
Aaron Franke e3cf64a7d8
[3.2] Add GLTF light import
Co-authored-by: K.S. Ernest (iFire) Lee <ernest.lee@chibifire.com>
2020-06-10 23:51:34 -04:00
Rémi Verschelde 7bf9787921 SCons: Format buildsystem files with psf/black
Configured for a max line length of 120 characters.

psf/black is very opinionated and purposely doesn't leave much room for
configuration. The output is mostly OK so that should be fine for us,
but some things worth noting:

- Manually wrapped strings will be reflowed, so by using a line length
  of 120 for the sake of preserving readability for our long command
  calls, it also means that some manually wrapped strings are back on
  the same line and should be manually merged again.

- Code generators using string concatenation extensively look awful,
  since black puts each operand on a single line. We need to refactor
  these generators to use more pythonic string formatting, for which
  many options are available (`%`, `format` or f-strings).

- CI checks and a pre-commit hook will be added to ensure that future
  buildsystem changes are well-formatted.

(cherry picked from commit cd4e46ee65)
2020-06-10 15:30:52 +02:00
Michael Alexsander 5495bbdd47 Fix scene tree showing up when the root selection is present
(cherry picked from commit f30e4dbf54)
2020-06-10 15:30:52 +02:00
Phischermen 12786bcbdb Fix crash when creating new text file with no name
(cherry picked from commit cdb29447b4)
2020-06-10 15:30:52 +02:00
Hugo Locurcio 317c9b5fe9 Tweak the invalid preset error message to mention export_presets.cfg
(cherry picked from commit a7b2f3d41a)
2020-06-10 15:30:52 +02:00
Rémi Verschelde f3fcdfbdd0 PackedScene: Prevent crash when root node has parent attribute
The crash happens further down when setting an invalid owner in
`Node::_set_owner_nocheck` but I couldn't figure out how to fix it.

But here the proper fix is to catch the invalid scene file early on
and fail loading it.

Part of #17372.

(cherry picked from commit c080ec5da2)
2020-06-10 15:30:52 +02:00
Aaron Franke 0b6a410890 Change the default editor camera rotation to position it in +X +Y +Z
(cherry picked from commit 6c2df6792b)
2020-06-10 15:30:52 +02:00
Hugo Locurcio eb6c7ec09c Add an editor tooltip to document gizmo visibility options
See discussion in
https://github.com/godotengine/godot-proposals/issues/716.

(cherry picked from commit 138a4eecb3)
2020-06-10 15:30:52 +02:00
PouleyKetchoupp c63c902c74 Fix dialog spam when inspecting MeshInstance from model file
Avoid load_scene for built-in resources to make sure we don't
open a scene tab and prompt for model file editing.

Load scene as regular resource instead and store the reference to keep
the dependency until the remote inspector cache is cleared.

(cherry picked from commit 01802074a0)
2020-06-10 15:30:51 +02:00
Hugo Locurcio 6e8b5aff66 Add visual feedback when hovering layer checkboxes in the Inspector
This also changes how checkboxes are selected, which makes it possible
to click in the small area between two checkboxes and
still toggle a value successfully (which is arguably less frustrating).

(cherry picked from commit bbc435624f)
2020-06-10 15:30:51 +02:00
Rémi Verschelde e891fae52b
Merge pull request #39134 from abustin/fbx_mesh_compression_fix
Respect 'mesh compression' editor import option in Assimp and glTF importers
2020-06-08 13:16:39 +02:00
Marcus Brummer f8463df11a Re-apply basis of newly added node (via drag-n-drop) in editor viewport 2020-06-07 19:34:17 +02:00
Tomasz Chabora 24872bffce Make sure built-in script warning fits in dialog 2020-06-05 14:40:08 +02:00
Marcus Brummer 6ef0de3f23 Enable text selection in execute output of EditorNode
(cherry picked from commit 85175c67b8)
2020-06-05 12:46:16 +02:00
johan 48a4f7e3a7 2D Editor: modified zoom increment to the twelveth root of two
- properly visit power of 2 factors (50%, 100%, 200%...)
- index based zoom values to prevent floating point issues
- Fix 2d editor not able to reach min and max zoom values

(cherry picked from commit fea6ca20c9)
2020-06-05 12:44:45 +02:00
Michael Alexsander 2ba67d94e8 Add fallback icons and make custom ones appear in the recent/favorites list in the "Create New" dialog
(cherry picked from commit 84d7492b2d)
2020-06-04 12:16:40 +02:00
Hugo Locurcio b0fe8cab14 Tweak the import compression property hint for clarity
(cherry picked from commit 1439447071)
2020-06-04 12:16:39 +02:00
Pedro J. Estébanez b2a64b144f Fix excessive bottom cropping in atlas generation
(cherry picked from commit fb7ae73045)
2020-06-04 12:16:39 +02:00
Aaron Franke 7021991cd9 Change OK text in snap dialog to OK
(cherry picked from commit 8f85858224)
2020-06-04 12:16:39 +02:00
Eric M f911ebc328 Improved warning shown when autoload cannot be added.
(cherry picked from commit 58caa2c453)
2020-06-04 12:16:39 +02:00
Hugo Locurcio 9e01a0cd28 Add a getter and property for the editor distraction-free mode
(cherry picked from commit cc1859efed)
2020-06-04 12:16:39 +02:00
Andrii Doroshenko (Xrayez) 3649c61e46 Prevent crash attaching a script with no languages registered
(cherry picked from commit 52f3cfca6f)
2020-06-04 12:09:40 +02:00
Hugo Locurcio 6ea9ca14f0 Allow mouse zooming without hovering the texture in the TileSet editor
This partially addresses
https://github.com/godotengine/godot-proposals/issues/968.

(cherry picked from commit d10a5b2928)
2020-06-04 12:09:40 +02:00
Hugo Locurcio 6bbfed6400 Implement zooming using Ctrl + Mouse wheel in the TileMap editor
This was previously implemented in the GridMap editor. This makes
the same feature available in the TileMap editor.

(cherry picked from commit def2059d67)
2020-06-04 12:09:40 +02:00
Dominik 'dreamsComeTrue' Jasiński fdf64b1898 Preserving "Sync Scene Changes' and "Sync Script Changes" with Project Settings
Fixes: #38739
(cherry picked from commit 72501ae104)
2020-06-04 12:09:40 +02:00
Dominik 'dreamsComeTrue' Jasiński 982ab51f2f Grabbing focus on ProjectList after clicking an item.
Fixes: #39012
(cherry picked from commit 1ec8f59397)
2020-06-04 12:09:40 +02:00
Rémi Verschelde fa0cf25e19 Add shortcut for Pan Mode (G)
And change TileMap Bucket Fill shortcut to (B).

Fixes #8582.

(cherry picked from commit 28b33718b0)
2020-06-04 12:09:39 +02:00
Hugo Locurcio e226947e21 Improve the text appearance in the script editor warnings panel
- Make the Ignore button's position identical across all warnings
  by moving it to the left.
- Change the Ignore button's text and color to make it more obvious
  that it can be clicked.
- Use the editor font instead of the default project font to match
  the rest of the editor.

(cherry picked from commit 0c0ee427d2)
2020-06-04 12:09:38 +02:00
Alex Bustin 8a024ca294 Respect 'mesh compression' editor import option in Assimp (ie. FBX) and glTF importers 2020-05-28 15:28:47 -07:00