Commit graph

197 commits

Author SHA1 Message Date
Rémi Verschelde 7f6b283212
Merge pull request #74264 from timothyqiu/self-awareness
Allow EditorInspector to change its property name style when necessary
2023-05-08 13:52:23 +02:00
Juan Linietsky 273a6eeb66 Redo how the remote filesystem works
Instead of reading files over the network, the new version uses a local file cache and only updates files when it changes.

The original remote filesystem was created 14 years ago, when ethernet was faster than hard drives or even flash. Also, mobile devices have a very small amount of storage.
Nowadays, this is no longer the case so the approach is changed to using a persistent cache in the target device.

Co-authored-by: m4gr3d
2023-05-08 11:57:54 +02:00
David Snopek 61f03daeeb Explicitly mark inherited export mode when making a dedicated server export 2023-05-03 09:47:33 -05:00
Haoyu Qiu d24ee551ec Allow EditorInspector to change its property name style when necessary
Previously, an EditorInspector's property name can only be set from
outside. Inspectors used for settings needs to respond to changes in
editor settings. So a few boilerplate code is almost always needed,
including watching for a certain editor setting in `_notification()`.

This commit adds a `set_use_settings_style()` function to tell the
inspector to watch for editor settings changes on its own.
2023-04-29 10:51:00 +08:00
Rémi Verschelde 8f7b09916d
Merge pull request #76026 from YuriSizov/editor-running-up-that-gui
Extract editor run toolbar into its own component
2023-04-26 12:15:29 +02:00
Daylily-Zeleen b12ced0a26 Implement and expose OS::shell_show_in_file_manager() 2023-04-25 11:29:32 +08:00
Daylily-Zeleen 5afc311783 Provide ability to override _export_end() in cpp. 2023-04-22 13:34:07 +08:00
Yuri Sizov 8a74d8438f Extract editor run toolbar into its own component
- Simplify and update its logic.
- Simplify EditorScript.
- Improve EditorNode and other relevant includes.
- Fix scene-based path in the movie writer when
reloading a scene.
2023-04-19 17:12:28 +02:00
bruvzg 0088981c40
[Export] Add readable descriptions and validation warnings to the export options. 2023-04-19 08:35:59 +03:00
Rémi Verschelde 96cc100246
Merge pull request #72895 from RedworkDE/editor-export-plugin-settings
Allow EditorExportPlugins to provide export options
2023-04-17 20:13:53 +02:00
kobewi a3799208c0 Rename console script to wrapper 2023-04-12 15:14:51 +02:00
RedworkDE 6963e84b58 Allow EditorExportPlugins to provide export options 2023-04-07 19:18:00 +02:00
Yuri Sizov 4154039832 Improve includes of EditorNode (and everything else)
Also start organizing editor-specific GUI components
into a dedicated folder, `editor/gui`.
Also move `editor_file_server` next to the rest of debugger classes.
2023-04-07 18:59:49 +02:00
Yuri Sizov f818d2b98f
Merge pull request #75141 from rcorre/rrc/dialog-pos 2023-03-28 10:54:37 +02:00
Ryan Roden-Corrent 894ce41180
Apply clamp_to_embedder on parent resize and popup.
Fixes #75084.

The clamp_to_embedder setting was added in 8be16e0704,
but was not set on any of the in-editor dialogs.

This patch sets `clamp_to_embedder` on editor dialogs so they cannot be dragged out of the frame.
This also modifies `clamp_to_embedder` so a window is clamped to the bounds of an embedder when
it pops up and when the parent is resized.
2023-03-27 07:08:29 -04:00
Rémi Verschelde 7752b52aa3
Merge pull request #74684 from clayjohn/export-tex
Delete unused compression formats from .import files when exporting
2023-03-19 00:06:04 -07:00
Yuri Sizov 3596443de1
Merge pull request #74727 from AThousandShips/project_settings
Exposing more project settings for documentation
2023-03-15 15:59:10 +01:00
Ninni Pipping bd30847e59 Exposing more project settings for documentation 2023-03-15 14:25:40 +01:00
kobewi 551b6965ec Remember directory when installing templates file 2023-03-10 18:18:30 +01:00
clayjohn dec86164e1 Delete unused compression formats from .imoprt files when exporting 2023-03-09 13:20:38 -08:00
Rémi Verschelde 0885e4b931
Merge pull request #73365 from bruvzg/no_transient_children
Automatically reparent editor message dialogs to avoid error spam.
2023-03-02 11:41:17 +01:00
Rémi Verschelde e10a15fc19
Export: Default to exporting S3TC + BPTC for PC platforms
This is now required after #72031 when using HDRs.

Could have further cleanup as I think these import options may not be needed
at all anymore, and etc/etc2 support doesn't seem to make much sense.
Likewise, the hardcoded "s3tc" in `get_platform_features` could maybe be
removed. But this is material for after 4.1.

Fixes #73789.
2023-02-23 18:42:28 +01:00
bruvzg 921f3b7589
Automatically reparent editor message dialogs to avoid error spam. 2023-02-21 12:32:11 +02:00
Rémi Verschelde b2584629c8
Merge pull request #73195 from timothyqiu/weblate-comments
Improvements and fixes based on Weblate comments
2023-02-17 09:55:39 +01:00
RedworkDE 1fb2b662e1 Fix texture_format/bptc export option 2023-02-14 13:51:42 +01:00
Pedro J. Estébanez cc9c43a631 Reword misleading error messages in PCK export 2023-02-14 12:04:31 +01:00
Haoyu Qiu 84aee17901 Improvements and fixes based on Weblate comments
* Description of `ui_text_submit` action should be "Submit Text" instead of "Text Submitted".
* Spell out "Animation" instead of using "Anim.".
* Treat "Max" as regular word instead of writing "Max.".
* Use generic "Set %s" for action name instead of a dedicated "Set target_position".
* Add translator comment for:
    * "Inclusive" and "Self" in the profiler.
    * Places where it needs the context about being an editor progress label.
    * "Duplicated Animation Name" since it's refering to the new name of a duplicated animation.
    * Disambiguation of "View Plane Transform", "Paste Selects" and "Display Normal".
* Fix wrong undo action name for renaming an input action.
* Fix missing end quote in a shader error message.
* In class reference:
    * Fix duplicated "if" in the description of `signf()`.
    * Fix mismatched example output in `String.operator %()`.
    * Fix typo in the description of `Decal.texture_emission`.
    * Unify description of `String.match()` and `StringName.match()`.
2023-02-13 15:22:18 +08:00
RedworkDE 2e167ca943 Bind EditorExportPlugin::_get_export_features 2023-02-07 23:14:20 +01:00
Rémi Verschelde b395512fdb
Merge pull request #72412 from dsnopek/dedicated-server-export-ui-improvement
Make it clearer that file modes propagate to children in the dedicated server export
2023-02-01 07:53:07 +01:00
Juan Linietsky 79897dd5bc Restore script class cache if removed
I have no idea why anyone would do this, but this fixes it.

Fixes #72154. Depends on #72444 being merged to function properly.
2023-01-31 11:28:21 +01:00
David Snopek 0e2af4b73d Make it clearer that file modes propagate to children in the dedicated server export 2023-01-30 15:10:44 -06:00
Rémi Verschelde e9de988020
Merge pull request #72031 from reduz/change-high-quality-texture-import
Refactor high quality texture import
2023-01-30 20:41:01 +01:00
David Snopek 0461cc5ba2 Only customize resources during export if there are any export plugins in use 2023-01-30 12:57:50 -06:00
Juan Linietsky 28f51ba547 Refactor high quality texture import
* Only two texture import modes for low/high quality now:
  * S3TC/BPTC
  * ETC2/ASTC
* Makes sense given this is the general preferred and most compatible combination in most platforms.
* Removed lossy_quality from VRAM texture compression options. It was unused everywhere.
* Added a new "high_quality" option to texture import. When enabled, it uses BPTC/ASTC (BC7/ASTC4x4) instead of S3TC/ETC2 (DXT1-5/ETC2,ETCA).
* Changed MacOS export settings so required texture formats depend on the architecture selected.

This solves the following problems:

* Makes it simpler to import textures as high quality, without having to worry about the specific format used.
* As the editor can now run on platforms such as web, Mac OS with Apple Silicion and Android, it should no longer be assumed that S3TC/BPTC is available by default for it.
2023-01-30 15:53:23 +01:00
bruvzg 4f1c2fce3a
[SSH deploy] Run ssh/scp in non interactive mode, and suppress banner display. 2023-01-27 10:24:15 +02:00
Rémi Verschelde 1dfd236f15
Merge pull request #70377 from dsnopek/server-export-mk2
Add "dedicated server" export mode which can strip unneeded visual resources
2023-01-23 22:13:28 +01:00
David Snopek 74458b6e9b Add "dedicated server" export mode which can strip unneeded visual resources 2023-01-23 13:24:54 -06:00
bruvzg 15dafc49d3
[TextServer] Fix ICU data loading and exporting with internationalization/locale/include_text_server_data setting. 2023-01-23 21:13:32 +02:00
kobewi 615c517034 Use range iterators in LocalVector loops 2023-01-21 18:44:42 +01:00
Mikael Hermansson 760d3ea085 Remove redundant definition of convert_text_resources_to_binary 2023-01-21 15:22:37 +01:00
George Marques 7e5c2f945d
Remove references to compiled GDScript in export
This feature was removed from GDScript so it should not be present on
the interface nor in the saved export presets.
2023-01-20 15:09:07 -03:00
Rémi Verschelde bcaf048f33
Merge pull request #71379 from KoBeWi/destruction_of_compatibility_function
Remove set_drag_forwarding_compat()
2023-01-18 17:40:13 +01:00
kobewi 6444c7d127 Move global script class cache to separate file 2023-01-16 10:16:30 +01:00
Yuri Sizov 4c1f11944e Update all outdated online documentation links 2023-01-14 19:38:00 +03:00
kobewi 59ea36b87c Remove set_drag_forwarding_compat() 2023-01-14 15:16:51 +01:00
Rémi Verschelde 3dffe0b967
Merge pull request #63312 from bruvzg/one_click
[Export] Add one-click deploy over SSH for the desktop exports.
2023-01-13 18:00:18 +01:00
Fabio Alessandrelli 9a59c0a47c [Editor] Fix missing "debug"/"release" export presets feature tags.
So the same code can be used in editor and debug exports ("release" is
kept for consistency).
2023-01-12 15:18:45 +01:00
Juan Linietsky e6a4debede Change set_drag_forwarding() to use callables.
* This solution is much cleaner than the one in 3.x thanks to the use of callables.
* Works without issues in any language (no need to worry about camel or snake case).
* Editor code uses a compatibility function (too much work to redo).

Fixes #59899
2023-01-10 14:09:24 +01:00
Rémi Verschelde d95794ec8a
One Copyright Update to rule them all
As many open source projects have started doing it, we're removing the
current year from the copyright notice, so that we don't need to bump
it every year.

It seems like only the first year of publication is technically
relevant for copyright notices, and even that seems to be something
that many companies stopped listing altogether (in a version controlled
codebase, the commits are a much better source of date of publication
than a hardcoded copyright statement).

We also now list Godot Engine contributors first as we're collectively
the current maintainers of the project, and we clarify that the
"exclusive" copyright of the co-founders covers the timespan before
opensourcing (their further contributions are included as part of Godot
Engine contributors).

Also fixed "cf." Frenchism - it's meant as "refer to / see".
2023-01-05 13:25:55 +01:00
bruvzg cebefc9f5d
[Export] Add one-click deploy over SSH for the desktop exports.
Add one-click deploy over SSH for the desktop exports.
Add ZIP export option for Linux and Windows.
Change export plugin icons to SVG format.
2022-12-29 09:42:00 +02:00
Rémi Verschelde f1edd03d4c
Merge pull request #69718 from groud/finally_rename_gdnative_to_gdextension
Rename all gdnative occurences to gdextension
2022-12-12 11:43:59 +01:00
Gilles Roudière be1c9d677d Rename all gdnative occurences to gdextension
Non-exhaustive list of case-sensitive renames:

GDExtension -> GDNative
GDNATIVE -> GDEXTENSION
gdextension -> gdnative
ExtensionExtension ->Extension (for where there was GDNativeExtension)
EXTENSION_EXTENSION ->EXTENSION (for where there was GDNATIVE_EXTENSION)
gdnlib -> gdextension
gdn_interface -> gde_interface
gdni -> gde_interface
2022-12-12 11:04:57 +01:00
Rémi Verschelde dc1a3fb952
Editor: Fix regression fetching Windows/Linux export templates
Regression from #67906.
2022-12-09 14:20:18 +01:00
Rémi Verschelde 83b426bca5
Merge pull request #67906 from groud/simpler_gdextension_config
Remove unnecessary checks when exporting gdextension binaries and allow using a prefix to auto-detect files
2022-12-06 11:01:09 +01:00
bruvzg ecec415988
Use system fonts as fallback and improve system font handling.
Add support for font weight and stretch selection when using system fonts.
Add function to get system fallback font from a font name, style, text, and language code.
Implement system font support for Android.
Use system fonts as a last resort fallback.
2022-12-04 18:44:20 +02:00
Gilles Roudière fa4143cdeb Allow specifying a prefix to automatically detect library files for gdextension exports 2022-12-01 18:20:40 +01:00
kobewi 9a3960daa5 Simplify GDVIRTUAL_REQUIRED_CALL calls 2022-11-30 18:36:57 +01:00
trollodel c90d0bd84f Use forward-declarations in big editor classes 2022-11-29 09:59:43 +01:00
bruvzg 9a33c97c2a
Add console wrapper app to handle console i/o redirection on Windows. 2022-10-31 14:37:49 +02:00
Rémi Verschelde 5947f22be9
Merge pull request #67578 from KoBeWi/GEDITOR
Unify usage of GLOBAL/EDITOR_GET
2022-10-31 13:15:58 +01:00
kobewi d06a8320e5 Simplify GDVIRTUAL_CALL calls 2022-10-19 00:05:48 +02:00
kobewi e48c5daddf Unify usage of GLOBAL/EDITOR_GET 2022-10-18 19:01:48 +02:00
Rémi Verschelde f2248969db
Merge pull request #66952 from bruvzg/macos_net_export
Fix macOS .NET export.
2022-10-12 22:52:59 +02:00
Rémi Verschelde 8017827144 SCons: Re-enable treating #warning as error with werror
Replace all TODO uses of `#warning` by proper TODO comments, and will open
matching bug reports to keep track of them.

We don't have a great track record fixing TODOs, but I'd wager we're even
worse for fixing these "TODO #warning" so we should prohibit this usage.
2022-10-10 16:12:26 +02:00
bruvzg 6daf4c6593
[.NET Export] Improve .NET export process.
[macOS export] Fix incorrect file placement, search paths and architecture detection.
[macOS export] Automatically detect executable files and set +x flag.
[macOS export] Automatically apply "Disable Library Validation" entitlements when required.
[macOS export] Remove old Mono export code.
Fix folder tree creation for shared objects export.
Add arch suffix to the exported .NET "data" folder name.
Remove old Mono code from .NET "data" folder lookup.
2022-10-07 13:33:06 +03:00
bruvzg 0103af1ddd
Fix MSVC warnings, rename shadowed variables, fix uninitialized values, change warnings=all to use /W4. 2022-10-07 11:32:33 +03:00
Rémi Verschelde 166df0896c Fix typos with codespell
Using codespell 2.3-dev from current git.

And fix typo in `methods.py` for `vsproj=yes` option (still won't work
though).
2022-09-30 14:23:36 +02:00
danboo eba8be6e45 Fix typo - "collison" -> "collision" 2022-09-29 13:56:26 -08:00
Rindbee 6973abd458 Fix sub-scene root nodes not getting the correct inheritance chain when exporting 2022-09-23 18:34:07 +08:00
Tomasz Chabora 882a4f8906 Port remaining connections to callable_mp 2022-09-18 13:08:54 +02:00
Fredia Huya-Kouadio 9d5e48f873 Disable menus and functionality that are not relevant on the Android Editor port 2022-09-13 20:48:33 -07:00
Fabio Alessandrelli a95d792420 [Net] Rename "ssl" references to "tls" in methods and members. 2022-09-08 03:24:23 +02:00
Yuri Sizov 1459507ed2 Rename EditorInterface.get_editor_main_control to get_editor_main_screen 2022-09-07 03:01:58 +03:00
Juan Linietsky ef17c4668a Add support for scene/resource customization in export plugins
EditorExportPlugin adds a set of callbacks to allow customizing scenes, resources or subresources in all files exported:
* Can take scene files, resource files and subresources in all of them.
* Uses a cache for the converted files if nothing changes, so this work only happens if a file is modified.
* Uses hashing to differentiate export configuration caches.
* Removed the previous conversion code to binary, as this one uses existing stuff.

This API is useful in several scenarios:
* Needed by the "server" export platform to get rid of textures, meshes, audio, etc.
* Needed by text to binary converters.
* Needed by eventual optimizations such as shader precompiling on export, mesh merging and optimization, etc.

This is a draft, feedback is very welcome.
2022-09-01 11:16:00 +02:00
Aaron Franke 10a56981dc
Rename String plus_file to path_join 2022-08-29 19:38:13 -05:00
Rémi Verschelde fd6453c45e Revert "Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED"
This reverts commit 4b817a565c.

Fixes #64988.
Fixes #64997.

This caused several regressions (#64988, #64997,
https://github.com/godotengine/godot/issues/64997#issuecomment-1229970605)
which point at a flaw in the current logic:

- `Control::NOTIFICATION_ENTER_TREE` triggers a *deferred* notification with
  `NOTIFCATION_THEME_CHANGED` as introduced in #62845.
- Some classes use their `THEME_CHANGED` to cache theme items in
  member variables (e.g. `style_normal`, etc.), and use those member
  variables in `ENTER_TREE`, `READY`, `DRAW`, etc. Since the `THEME_CHANGE`
  notification is now deferred, they end up accessing invalid state and this
  can lead to not applying theme properly (e.g. for EditorHelp) or crashing
  (e.g. for EditorLog or CodeEdit).

So we need to go back to the drawing board and see if `THEME_CHANGED` can be
called earlier so that the previous logic still works?

Or can we refactor all engine code to make sure that:
- `ENTER_TREE` and similar do not depend on theme properties cached in member
  variables.
- Or `THEME_CHANGE` does trigger a general UI update to make sure that any
  bad theme handling in `ENTER_TREE` and co. gets fixed when `THEME_CHANGE`
  does arrive for the first time. But that means having a temporary invalid
  (and possibly still crashing) state, and doing some computations twice
  which might be heavy (e.g. `EditorHelp::_update_doc()`).
2022-08-29 11:11:29 +02:00
Rémi Verschelde f7f8af232c
Merge pull request #64885 from Mickeon/rename-tooltip-hint
Rename `hint_tooltip` to `tooltip_text` & setter getter
2022-08-28 17:43:01 +02:00
Aaron Record 4b817a565c Remove NOTIFICATION_ENTER_TREE when paired with NOTIFICATION_THEME_CHANGED 2022-08-27 11:52:29 -06:00
Micky ef5b9a06a9 Rename hint_tooltip to tooltip_text & setget
`hint_tooltip` -> `tooltip_text`
`set_tooltip` -> `set_tooltip_text`
`_get_tooltip` -> `get_tooltip_text`

Updates documentation, too.
2022-08-27 01:35:01 +02:00
bruvzg d91cb1d5d5
[macOS export] Simplify code signing options, add support for rcodesign tool for signing and notarization. 2022-08-26 14:23:31 +03:00
Fredia Huya-Kouadio 45c7377556 Refactor the export checking logic to improve separation of concerns 2022-08-14 09:12:04 -07:00
Rémi Verschelde 15f918a111
Merge pull request #62925 from aaronfranke/pck-export 2022-08-10 14:09:42 +02:00
Aaron Franke 8d81ce9561
Allow exporting PCK files without export templates installed 2022-08-09 13:08:58 -05:00
Aaron Franke 28d1bc34d7
Remove duplicate data structure for export features 2022-08-09 13:02:56 -05:00
Yuri Sizov 1c9ba5ef3e Remove excessive editor/property_editor.h includes 2022-08-01 17:19:11 +03:00
Yuri Sizov 9f55bd971e Extract EditorResourceConversionPlugin into its own source files and clean up editor includes 2022-07-31 21:14:15 +03:00
Rémi Verschelde 3e5ad8213f
Merge pull request #63563 from aaronfranke/export-arch 2022-07-30 11:22:25 +02:00
bruvzg ea00cf7270
Improve some export error messages. 2022-07-29 22:44:59 +03:00
Rémi Verschelde ba3734e69a
Merge pull request #63603 from aaronfranke/editor-paths
Move editor paths into the EditorPaths class
2022-07-29 19:31:59 +02:00
Rémi Verschelde 7199314eb3
Merge pull request #63595 from reduz/remove-signal-connect-binds
Remove Signal connect binds
2022-07-29 18:10:39 +02:00
Aaron Franke ac870ab1c8
Move editor paths into the EditorPaths class 2022-07-29 11:07:30 -05:00
Aaron Franke 17c4cd6412
Update export dialog to handle many architectures 2022-07-29 10:24:58 -05:00
Aaron Franke a0072ba39f
Make some editor export methods const 2022-07-29 10:24:13 -05:00
Juan Linietsky d4433ae6d3 Remove Signal connect binds
Remove the optional argument p_binds from `Object::connect` since it was deprecated by Callable.bind().
Changed all uses of it to Callable.bind()
2022-07-29 16:26:13 +02:00
Rémi Verschelde af054f1003 Export: Fix template path for PC (Windows, Linux)
Regression after #63096.
2022-07-29 11:03:18 +02:00
Aaron Franke 006e5f28d5
Move project export and export template manager into export folder 2022-07-26 08:28:29 -05:00
Aaron Franke e53ae13178
Split up editor export code into multiple files 2022-07-26 08:28:19 -05:00