Commit graph

6115 commits

Author SHA1 Message Date
Andrea Catania
277696d6c5 Fixed IK rotation issue 2020-03-24 10:06:24 +01:00
Rémi Verschelde
cfd84625f0 Move DocData and Collada out of their subfolders
Now that the unused DocDump was removed, the `editor/doc` subfolder is
redundant.

Similarly, there's no reason for Collada to have a subfolder for itself
when glTF or OBJ don't.
2020-03-24 09:56:04 +01:00
Rémi Verschelde
9d24541597 Remove unused classes and stray headers
Found by reviewing headers with 1 or less matching includes:
```
find -name thirdparty -prune -o -name "*.h" -exec basename {} \; | sort -u > headers
for header in $(cat headers); do echo "$header: "; rg -l "#include \"(.*/)?$header\"" | wc -l; done > list-includes
```
2020-03-24 09:50:51 +01:00
Rémi Verschelde
ed9a0d0484
Merge pull request #37179 from clayjohn/VULKAN-sky-shader
Implement Sky Shaders
2020-03-22 20:03:35 +01:00
clayjohn
61a74739ca Working sky shader implementation 2020-03-21 20:43:44 -07:00
Rémi Verschelde
7ed9da0a54
Merge pull request #37161 from simpuid/positon-gizmo-fix
Fixes transform gizmo position when node has default transform
2020-03-21 15:31:47 +01:00
simpuid
19825436d4 Fixes transform gizmo position when node has default transform
Changes made:
* Added dirty bit for SpatialEditorSelectedItem's last_xform
* SpatialEditorViewport checks that dirt bit too before skipping the selection
2020-03-21 18:31:46 +05:30
Rémi Verschelde
aca1971a12 i18n: Add header strings to translation catalog 2020-03-20 12:35:22 +01:00
Rémi Verschelde
4857648a16 i18n: Add support for translating the class reference
- Parse `.po` files from `doc/translations/*.po` like already done
  with `editor/translations/*.po`.
- Add logic to register a doc translation mapping in `TranslationServer`
  and `EditorSettings`.
- Add `DTR()` to lookup the doc translation mapping (similar to `TTR()`).
  Strings are automatically dedented and stripped of whitespace to ensure
  that they would match the translation catalog.
- Use `DTR()` to translate relevant strings in `EditorHelp`,
  `EditorInspector`, `CreateDialog`, `ConnectionsDialog`.
- Small simplification to `TranslationLoaderPO`, the path argument was
  not really meaningful.
2020-03-20 08:48:11 +01:00
Fabio Alessandrelli
10dd73c868
Merge pull request #37159 from ThakeeNathees/f8-stop-process-crash-fix
Fix editor crash when stopping game with F8.
2020-03-19 16:51:41 +01:00
Rémi Verschelde
500086587a
Merge pull request #35712 from KoBeWi/theheme_spy
Show theme property descriptions in the inspector
2020-03-19 14:50:59 +01:00
Thakee Nathees
76fd073f58 stop game process with KEY_F8 crash fixed
Fix: #37121
2020-03-19 19:13:19 +05:30
johan
1c02906a6f Editor 2D: Change pixel alignment strategy, fix jittering in high zoom
Alignment of scene pixels on screen pixel ensure a crisp rendering of small features (such as text). Unfortunately, alignment of top left pixel on screen adds a lot of jittering when zooming at high zoom factor.

This change allow to snap the top left scene pixel on the closest screen pixel (not only the top-left most), and we do so only when the scale factor is an integer.
2020-03-18 12:37:14 -04:00
Rémi Verschelde
194d2ccb72
Merge pull request #37116 from neikeq/issue-12917
Sync csproj when files are changed from the Godot FileSystem dock
2020-03-18 16:07:49 +01:00
Ignacio Etcheverry
fe0b783e70 Expose FileSystemDock to the scripting API and fixed signals
Fixed FileSystemDock's `file_removed` and `folder_removed` signals not being
emitted because the emitted was using the wrong signal name.
2020-03-18 15:06:07 +01:00
Rémi Verschelde
faca5bafe8
Merge pull request #36993 from van800/editor_metadata
For third-party tools - editor_path is stored in project's editor settings
2020-03-18 10:39:06 +01:00
Rémi Verschelde
b8577ecce1
Merge pull request #37106 from akien-mga/clang-format-cpp11
Style: Set clang-format Standard to Cpp11
2020-03-17 08:42:39 +01:00
Rémi Verschelde
cb282c6ef0 Style: Set clang-format Standard to Cpp11
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`.
2020-03-17 07:36:24 +01:00
alvaroHernandez
e47d5691e4 prevent joypad button input dropdown going out of dialog 2020-03-16 21:44:50 -03:00
Rémi Verschelde
2aa832f415 i18n: Sync translations with Weblate
(cherry picked from commit 0e36b11f9d)
2020-03-16 10:49:03 +01:00
Rémi Verschelde
47eb28a919
Merge pull request #36184 from volzhs/plugins-checkbox
Use checkbox for plugin status instead of option list
2020-03-16 10:47:32 +01:00
Rémi Verschelde
2a49798c7b
Merge pull request #36970 from JFonS/fix_viewports_update
Update all editor viewports after settings changes
2020-03-14 23:46:58 +01:00
JFonS
55b478afd9 Update all editor viewports after settings changes 2020-03-14 20:47:12 +01:00
Pedro J. Estébanez
98326d88bb Fix bad uses of mutex causing deadlocks 2020-03-13 11:13:58 +01:00
Rémi Verschelde
951ecc4f79
Merge pull request #36518 from Janglee123/no-underlined-keywords
Removed underlining of not clickable symbols
2020-03-12 22:24:43 +01:00
Rémi Verschelde
36a414eb03
Merge pull request #36994 from akien-mga/typedefs-cleanup
typedefs: Cleanup unused macros and unnecessary checks
2020-03-12 22:02:18 +01:00
Ivan.Shakhov
2f151068b5 for third-party tools - editor_path is stored in project's editor settings 2020-03-12 13:59:48 +01:00
Rémi Verschelde
676fcca988
Merge pull request #36963 from JFonS/fix_rotation_gizmo_update
Fix rotation gizmo for empty Spatials
2020-03-12 12:35:18 +01:00
Rémi Verschelde
1c2f2a805d typedefs: Cleanup unused macros and unnecessary checks
We now require a compiler with C++17 support, so we don't need to
check for features added to GCC 5 or Clang 3.2.

Clang builtin availability checks were unused anyway as Clang defines
`__GNUC__` as it's also a GNU C implementation.

Fixes #36986.
2020-03-11 21:44:56 +01:00
luz.paz
7bf6e5f773 Fix various typos
Found via `codespell`
2020-03-11 13:59:18 -04:00
janglee
50a570c9c1 Removed underlining for not clickable symbols 2020-03-11 08:57:21 +00:00
JFonS
a0af3094b4 Fix rotation gizmo for empty Spatials
The AABB for an empty Spatial has 0 size, since the stored and
compared Transform was scaled by the AABB size, it would completely
destroy the rotation information. If there is no rotation
information, the gizmo doesn't update when the rotation changes.
2020-03-10 16:23:22 +01:00
Rémi Verschelde
1500e40ccf
Merge pull request #36887 from MCrafterzz/relativeSnap
Made snap relative work on rotation as well
2020-03-10 10:17:42 +01:00
Fabio Alessandrelli
95c4ba80c5 Fix "deploy with remote debug" editor option.
The line to update the option was missing (rendering it useless).
Of course the only one I didn't know how to test was broken.
2020-03-10 04:06:19 +01:00
Rémi Verschelde
478337c412
Merge pull request #36751 from Faless/debugger/threads_and_profilers
ScriptDebugger refactor, threading, profilers.
2020-03-09 19:08:07 +01:00
Marcus Elg
97a07bada7 Made snap relative work on rotation as well 2020-03-09 17:00:47 +01:00
Rémi Verschelde
af015f79d3
Merge pull request #36917 from volzhs/cancel-snap-setting
Update snap setting only with OK
2020-03-09 12:19:56 +01:00
Rémi Verschelde
1f37c8e048
Merge pull request #36914 from guilhermefelipecgs/fix_check_view_information
Fix the VIEW_INFORMATION checkbox not being selected (visually)
2020-03-09 12:17:07 +01:00
Rémi Verschelde
e162c07af9
Merge pull request #36920 from Faless/debugger/more_instances
Move Debug menu logic to DebuggerEditorPlugin, allow 4 debug instances
2020-03-09 12:01:14 +01:00
Rémi Verschelde
a4318281d3
Merge pull request #36929 from timothyqiu/keep-filename
Keeps the filename when marking scene as unsaved
2020-03-09 11:43:11 +01:00
Rémi Verschelde
788765709d DocData: Fix serialization of Variant default values
Co-authored-by: Bojidar Marinov <bojidar.marinov.bg@gmail.com>
2020-03-09 10:52:44 +01:00
Rémi Verschelde
e629b4bc8a i18n: Sync translations with Weblate
(cherry picked from commit 18e021b7cd)
2020-03-09 10:13:45 +01:00
Fabio Alessandrelli
bfc1b76803 Allow running/debugging up to 4 instances. 2020-03-09 09:43:54 +01:00
Haoyu Qiu
9ed61a70cc Keeps the filename when marking scene as unsaved 2020-03-09 10:26:57 +08:00
jfons
7055a926ff Add rotation widget to 3D viewport 2020-03-08 23:38:29 +01:00
Fabio Alessandrelli
4d623b70d7 Move Debug menu logic to DebuggerEditorPlugin 2020-03-08 22:57:48 +01:00
volzhs
667a981d4d Update snap setting only with OK
restore previous values with cancel
2020-03-09 04:31:11 +09:00
Guilherme Felipe
126cec41e6 Fix the VIEW_INFORMATION checkbox not being selected
Generated id of "Display Advanced..." was in conflict with "View Information"
2020-03-08 15:34:41 -03:00
Fabio Alessandrelli
3b47eb51e4 Update editor debugger to new remote debugger.
Shared RemoteDebuggerPeer code between client and server.
Move editor profilers inside editor/debugger folder.
2020-03-08 12:36:39 +01:00
Fabio Alessandrelli
540ca05a80 Threaded networking for editor debugger. 2020-03-08 12:16:09 +01:00
Mateo Miccino
86b48093eb Signals: filter_changed from ProjectListFilter now is emitted when it's on scene tree to avoid unexpected call 2020-03-07 18:34:10 -03:00
fhuya
f097defba1 Re-architecture of the Godot Android plugin. 2020-03-05 10:00:19 -08:00
Rémi Verschelde
42595085a5
Merge pull request #36752 from RandomShaper/rework_semaphore
Drop old semaphore implementation
2020-03-05 16:33:45 +01:00
Rémi Verschelde
fdda39a506 Signals: Don't pass default binds to EditorProperty property_changed
This was done by mistake in #36758, but it's not necessary and actual
causes a bug.

`property_changed` is only emitted via `emit_changed()`, which already
has default values for `p_field` and `p_changing`.

Also reverted to using `String` for now to be on the safe side, even if
it's inconsistent with `emit_changed()`. I had only changed it
partially in #36758 so it was inconsistent. It probably does make sense
to port `EditorInspector` and related property editors to use
`StringName` where relevant, but that's for a dedicated PR.

Fixes #36799.
2020-03-05 15:35:44 +01:00
Rémi Verschelde
54a8bad8fe
Merge pull request #36700 from ThakeeNathees/scene-tab-bug-fix
Fix possible EditorFolding crash when switching scenes
2020-03-05 14:23:43 +01:00
Thakee Nathees
3275e8488b Fix EditorFolding crash when switching scenes 2020-03-05 18:19:58 +05:30
Fabio Alessandrelli
e5ec499a92 Fix some bugs spotted by asan in editor debugger.
EditorDebuggerInspector is in tree, so it gets automatically deleted,
when clearing errors the debugger should not fake a process
notification.
2020-03-05 12:28:22 +01:00
Rémi Verschelde
85ffc5ec97
Merge pull request #36746 from aaronfranke/plugin-icon-docs
Document EditorPlugin get_plugin_icon and get_plugin_name
2020-03-05 09:46:41 +01:00
Rémi Verschelde
0c53f1f7db
Merge pull request #36743 from Calinou/tweak-giprobe-gizmo
Tweak the GIProbe gizmo to be more subtle
2020-03-04 22:44:44 +01:00
Rémi Verschelde
7c9e15238e
Merge pull request #36739 from Calinou/improve-giprobe-editor-label
Improve the GIProbe editor contextual label
2020-03-04 22:41:25 +01:00
Aaron Franke
68d73ecf60
Document EditorPlugin get_plugin_icon and get_plugin_name
The return value's type hint is now accurate.
2020-03-04 15:49:20 -05:00
Rémi Verschelde
f83f1d7c9b
Merge pull request #36069 from RandomShaper/imvu/improve_drives_ux
Improve UX of drive letters
2020-03-04 13:19:55 +01:00
Rémi Verschelde
c90ec71bcd
Merge pull request #36699 from dreamsComeTrue/fix-extension-file-dialog
Take correct part of extension with File Dialog
2020-03-04 10:36:20 +01:00
Gil Arasa Verge
e060e0992a Double click on a folder didn't open it (editor)
Same behavior as #36684.
Removed by mistake in #36426.

Fixes #36757.
2020-03-03 19:43:37 +01:00
Pedro J. Estébanez
9a3a2b03b8 Drop old semaphore implementation
- Removed platform-specific implementations.
- Now all semaphores are in-object, unless they need to be conditionally created.
- Similarly to `Mutex`, provided a dummy implementation for when `NO_THREADS` is defined.
- Similarly to `Mutex`, methods are made `const` for easy use in such contexts.
- Language bindings updated: `wait()` and `post()` are now `void`.
- Language bindings updated: `try_wait()` added.

Bonus:
- Rewritten the `#ifdef` in `mutex.h` to meet the code style.
2020-03-03 13:20:42 +01:00
Rémi Verschelde
48ed841dd0 Signals: Fix some regressions from #36426
- Fix `callable_mp` bindings to methods which used to have default
  arguments passed to `bind_method`. We now have to re-specify them
  manually when connecting.
- Re-add `GroupsEditor::update_tree` binding.
- Misc code quality changes along the way.
2020-03-03 11:44:06 +01:00
Pedro J. Estébanez
aee586553a Improve UX of drive letters
Namely, move the drive dropdown to just the left of the path text box and don't include the former
in the latter.

This improves the UX on Windows.

In the UNIX case, since its concept of drives is (ab)used to provide shortcuts to useful paths, its
dropdown is kept at the original location.
2020-03-03 10:38:34 +01:00
Hugo Locurcio
fda2558ff7
Tweak the GIProbe gizmo to be more subtle 2020-03-02 23:22:50 +01:00
Hugo Locurcio
46bc1a7c3f
Improve the GIProbe editor contextual label
- Change the label color depending on the estimated performance
  (green = fast, yellow = average, red = slow).
- Use the Unicode multiplication symbol.
- Make the label translatable.
2020-03-02 22:09:38 +01:00
fhuya
5b80dc9a2a Fix android template install validation. 2020-03-02 10:53:05 -05:00
Rémi Verschelde
e2b66cacf7
Merge pull request #18020 from bruvzg/input_fix_non_latin_and_add_hw_scancodes
Fix non-latin layout scancodes on Linux, adds access to physical scancodes.
2020-03-01 23:00:42 +01:00
Rémi Verschelde
55396d6e06
Merge pull request #36621 from WizardOhio24/fix-wrong-selection-on-line-clone-down
Fix wrong selection on cloning a line down in the editor
2020-03-01 15:53:55 +01:00
Dominik 'dreamsComeTrue' Jasiński
319840bad1 Take correct part of extension with File Dialog
Fixes #36697
2020-03-01 09:44:48 +01:00
Richard Menzies
28f74327be Fix wrong selection on cloning a line down in the editor 2020-02-29 16:29:48 +00:00
Rémi Verschelde
1399747532
Merge pull request #36667 from simpuid/paste-params-undo-feature
Implement undo-redo feature for Parameter Paste in the Inspector
2020-02-29 14:12:54 +01:00
simpuid
f817ba8379 Implement undo-redo feature for Parameter Paste in the Inspector
EditorData::undo_redo.add_do_property and EditorData::undo_redo.add_undo_property is used in EditorData::paste_object_params to implement this feature. It's action name is set to "Paste Params"

Changes made
* Removed the call for clearing the history on paste params case.
* Instead of directly setting the properties value, EditorData::undo_redo is used.
2020-02-29 16:52:12 +05:30
Rémi Verschelde
cb91f8d971
Merge pull request #36406 from nathanwfranke/revert-fix-signal-errors
Partial revert "Fix two signal errors"
2020-02-29 12:11:53 +01:00
Rémi Verschelde
cafa4ae3bd
Merge pull request #36653 from YeldhamDev/icons_for_the_icon_god
Add more missing icons (and adjust a few)
2020-02-28 22:07:50 +01:00
Michael Alexsander
687f72ba28 Add more missing icons (and adjust a few) 2020-02-28 15:00:10 -03:00
Rémi Verschelde
32ccf306f9 ConnectionsDock: Fix error when parsing CustomCallable connections 2020-02-28 14:32:36 +01:00
Rémi Verschelde
09a6a2d8f8 Signals: Port more uses of connect_compat
Those were problematic as they call a method of their parent class,
but callable_mp does not allow that unless it's public.

To solve it, we declare a local class that calls the parent class'
method, which now needs to be protected to be accessible in the
derived class.
2020-02-28 14:24:09 +01:00
Mateo Dev .59
b8f08b42e7 Signals: Fix signals error prints for the new signal system 2020-02-28 14:24:09 +01:00
Rémi Verschelde
f742dabafe Signals: Manually port most of remaining connect_compat uses
It's tedious work...

Some can't be ported as they depend on private or protected methods
of different classes, which is not supported by callable_mp (even if
it's a class inherited by the current one).
2020-02-28 14:24:09 +01:00
Rémi Verschelde
01afc442c7 Signals: Port connect calls to use callable_mp
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.)
2020-02-28 14:24:09 +01:00
Tomasz Chabora
225622e5e3 Add unique icon to Polygon2D 2020-02-28 12:01:39 +01:00
Rémi Verschelde
42ffcaa4f7
Merge pull request #36630 from YeldhamDev/import_dock_checking_preset
Fix import changing disabling checking on multiple files
2020-02-28 10:13:22 +01:00
Rémi Verschelde
4f64f3401a
Merge pull request #36388 from AndreaCatania/some_renames
Rename Navigation{Mesh,Polygon}Instance and PlaneShape for clarity
2020-02-28 09:15:38 +01:00
Andrea Catania
483994601d Renamed NavigationPolygonInstance to NavigationRegion2D 2020-02-28 08:28:53 +01:00
Michael Alexsander
d35386263f Fix import changing disabling checking on multiple files 2020-02-28 00:03:55 -03:00
Rémi Verschelde
b7b3978684
Merge pull request #36556 from RandomShaper/rework_mutex
Reimplement `Mutex` with C++'s `<mutex>` (plus more)
2020-02-28 00:26:01 +01:00
Rémi Verschelde
2d904d2f80
Merge pull request #36232 from Calinou/add-soft-line-length-guideline
Add a soft line length guideline to the script editor
2020-02-27 21:10:42 +01:00
Rémi Verschelde
eaf909dcf9
Merge pull request #36490 from Calinou/assetlib-error-version-compatibility
Mention version compatibility when there are no results in the assetlib
2020-02-27 21:08:39 +01:00
Rémi Verschelde
38c78a9ab6
Merge pull request #36333 from Calinou/decrease-script-editor-split-width
Decrease the script editor's default split width to 70
2020-02-27 20:54:23 +01:00
Rémi Verschelde
fec9a76aba
Merge pull request #36546 from YeldhamDev/inspector_tooltip_no_doubles
Don't show a copy of the property's name in the inspector's tooltip if there's no description
2020-02-27 20:53:51 +01:00
Rémi Verschelde
eced623c57 Fix build after merge of #36077 2020-02-27 20:51:43 +01:00
Rémi Verschelde
7530824cc4
Merge pull request #36077 from pycbouh/repeat-search-in-files
Add a button to quickly repeat last search in files
2020-02-27 20:19:55 +01:00
Andrea Catania
2e0fb66c6f Renamed PlaneShape to WorldMarginShape 2020-02-27 17:45:16 +01:00
Andrea Catania
3b64ecbc4b Renamed NavigationMeshInstance to NavigationRegion 2020-02-27 17:42:53 +01:00
Rémi Verschelde
ac446570d6
Merge pull request #36545 from nathanwfranke/syntax-highlight-int-types
Fix autocomplete and highlighting for new integer types
2020-02-27 14:20:10 +01:00
Rémi Verschelde
e0e4610ace
Merge pull request #36591 from aaronfranke/key-order
Make internal editor key order consistent
2020-02-27 14:17:29 +01:00