Commit graph

265 commits

Author SHA1 Message Date
Rémi Verschelde
a09846e015
Merge pull request #42109 from EricEzaM/PR/input-and-shortcuts-rework
Shortcuts rework - fixed issues with input propagation and triggering of unwanted shortcuts.
2020-11-28 09:04:25 +01:00
bruvzg
99666de00f
[Complex Text Layouts] Refactor Font class, default themes and controls to use Text Server interface.
Implement interface mirroring.
Add TextLine and TextParagraph classes.
Handle UTF-16 input on macOS and Windows.
2020-11-26 14:25:48 +02:00
Eric M
efe5c250d5 Implement new shortcuts system.
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'.
2020-11-23 21:14:26 +10:00
Rafał Mikrut
b20c20a6f7 Allow to open multiple projects when some are not imported or without main scene. 2020-11-18 21:24:27 +01:00
Rémi Verschelde
d191ffe647
Merge pull request #43479 from Calinou/use-low-editor-scale-auto
Use 75% editor scale on small displays automatically
2020-11-16 16:36:10 +01:00
Hugo Locurcio
c1a65e5289
Use 75% editor scale on small displays automatically
This also makes borders always display in the editor theme,
even if the editor scale is below 100%. Otherwise, "focus" outlines
would vanish when using an editor scale below 100%,
which harms usability.
2020-11-16 16:23:15 +01:00
Aaron Franke
46fdca4fae
Allow creating projects in non-empty folders with a confirmation popup 2020-11-10 00:12:07 -05:00
reduz
127458ed17 Reorganized core/ directory, it was too fatty already
-Removed FuncRef, since Callable makes it obsolete
-Removed int_types.h as its obsolete in c++11+
-Changed color names code
2020-11-07 20:17:12 -03:00
Ev1lbl0w
9b1db715fd
Allow Godot to import .ZIP files with non-regular structure 2020-10-19 09:37:04 +01:00
Aaron Franke
5fbcd8f9df
Rename the ".import" folder to ".godot/imported" 2020-09-28 05:23:45 -04:00
Rémi Verschelde
9568bcf166
i18n: Sync translations with Weblate
Add translators comment for the two 'Project Manager' strings,
and fix some of the translations.

(cherry picked from commit c5f6d2097b)
2020-09-08 15:18:17 +02:00
Rémi Verschelde
71833520da
Merge pull request #41589 from sburris0/master
Make blank project name create an error, not a warning
2020-09-03 00:27:57 +02:00
Aaron Franke
0b6326c79a
Change the "remove missing" button to disabled rather than hidden
Also set a minimum size
2020-08-31 11:40:06 -04:00
Stijn Hinlopen
31fdb0fe46 Fix not saving new filter order 2020-08-29 15:39:34 +02:00
Spencer Burris
0e3d938968 Make blank project name create an error, not a warning 2020-08-28 15:57:33 -07:00
Stijn Hinlopen
598447c5bc Refactor project filter in Project Manager
- Reorder search/sort bar
 - Removed ProjectListFilter (unnecessary abstraction)
 - Reorder side bar buttons
 - Removed some unused variables/methods
2020-08-27 22:14:30 +02:00
Raul Santos
f997004ee8
Create default_env.tres with the same format used to save it 2020-08-10 09:51:47 +02:00
Stijn Hinlopen
526e060b73 Resize dialogs (FileDialog, EditorFileDialog, Reparent, SceneTreeDialog and resource depency dialogs). 2020-07-14 14:35:22 +02:00
Marcel Admiraal
26fcf2b04c Add override keywords. 2020-07-10 13:56:54 +01:00
PouleyKetchoupp
b2d27214aa Keep debug & verbose options after loading project from project manager 2020-07-09 09:51:32 +02:00
bruvzg
df968d577a
[macOS] Implement seamless display scaling. 2020-07-04 10:36:33 +03:00
Stijn Hinlopen
929b98d24b Remove String::find_last (same as rfind) 2020-07-03 15:26:22 +02:00
Hugo Locurcio
31b7f02a29
Remove ToolButton in favor of Button
ToolButton has no redeeming differences with Button;
it's just a Button with the Flat property enabled by default.
Removing it avoids some confusion when creating GUIs.

Existing ToolButtons will be converted to Buttons, but the Flat
property won't be enabled automatically.

This closes https://github.com/godotengine/godot-proposals/issues/1081.
2020-06-19 20:49:49 +02:00
hilfazer
512aaf018c Fixed "Favourite Project" button in Project Manager 2020-06-13 12:43:54 +02:00
Dominik 'dreamsComeTrue' Jasiński
1ec8f59397 Grabbing focus on ProjectList after clicking an item.
Fixes: #39012
2020-05-30 21:19:50 +02:00
Rémi Verschelde
0ee0fa42e6 Style: Enforce braces around if blocks and loops
Using clang-tidy's `readability-braces-around-statements`.
https://clang.llvm.org/extra/clang-tidy/checks/readability-braces-around-statements.html
2020-05-14 21:57:34 +02:00
Rémi Verschelde
0be6d925dc Style: clang-format: Disable KeepEmptyLinesAtTheStartOfBlocks
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.
2020-05-14 16:54:55 +02:00
Rémi Verschelde
69de7ce38c Style: clang-format: Disable AllowShortCaseLabelsOnASingleLine
Part of #33027.
2020-05-10 13:13:54 +02:00
Hugo Locurcio
72da1667e0
Improve path search behavior discoverability in the project manager
This closes #38185.
2020-04-25 21:59:38 +02:00
lupoDharkael
95a1400a2a Replace NULL with nullptr 2020-04-02 13:38:00 +02:00
bruvzg
15a9f94346 Add macOS DisplayServer implementation.
Change global menu to use Callable, add support for check items and submenus.
2020-03-26 16:24:05 +01:00
Mateo Kuruk Miccino
f387b9b4f4 Multiple changes to DisplayServerX11
- Travis: Change x11 to linuxbsd
- SCons: Change x11 plataform to linuxbsd
- Plugins: Remove ; to avoid fallthrough warning
- DisplayServerX11: Implement set_icon
- DisplayServerX11: Fix X11 bug when a window was erased from windows
  map, all the changes from that erased windows are sending to the main
  window
- DisplayServerX11: Reorder create_window commands
- DisplayServerX11: Change every Size2 to Size2i and Rect2 to Rect2i
  where it belongs

+ More X11 fixes which have been integrated directly back into reduz's
original commits while rebasing the branch.
2020-03-26 15:49:54 +01:00
Juan Linietsky
441f1a5fe9 Popups are now windows also (broken!) 2020-03-26 15:49:42 +01:00
Juan Linietsky
4758057f20 Working multiple window support, including editor 2020-03-26 15:49:40 +01:00
Juan Linietsky
8e6960a69e Refactored input, goes all via windows now.
Also renamed Input to InputFilter because all it does is filter events.
2020-03-26 15:49:39 +01:00
Juan Linietsky
f8a79a97c7 Effective DisplayServer separation, rename X11 -> LinuxBSD 2020-03-26 15:49:34 +01:00
clayjohn
61a74739ca Working sky shader implementation 2020-03-21 20:43:44 -07: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
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
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
bruvzg
1af06d3d46
Rename scancode to keycode.
Add `physical_keycode` (keyboard layout independent keycodes) to InputEventKey and InputMap.
Fix non-latin keyboard layout keycodes on Linux/X11 (fallback to physical keycodes).
2020-02-25 12:30:33 +02:00
Juan Linietsky
69c95f4b4c Reworked signal connection system, added support for Callable and Signal objects and made them default. 2020-02-20 08:24:50 +01:00
Juan Linietsky
3205a92ad8 PoolVector is gone, replaced by Vector
Typed `PoolTypeArray` types are now renamed `PackedTypeArray` and are
sugar for `Vector<Type>`.
2020-02-18 10:10:36 +01:00
Marcin Zawiejski
dc793bb816 fix Vulkan project description 2020-02-13 21:04:43 +01:00
Rémi Verschelde
386968ea97 Remove obsolete GLES3 backend
Due to the port to Vulkan and complete redesign of the rendering backend,
the `drivers/gles3` code is no longer usable in this state and is not
planned to be ported to the new architecture.

The GLES2 backend is kept (while still disabled and non-working) as it
will eventually be ported to serve as the low-end renderer for Godot 4.0.

Some GLES3 features might be selectively ported to the updated GLES2
backend if there's a need for them, and extensions we can use for that.

So long, OpenGL driver bugs!
2020-02-13 10:36:44 +01:00
Rémi Verschelde
57dca8b8cc
Merge pull request #36152 from Calinou/project-manager-rename-last-modified
Rename the "Last Modified" project list sorting option to "Last Edited"
2020-02-13 09:09:24 +01:00
Hugo Locurcio
bb2fffa10c
Disable the GLES2 renderer option in the Project Manager
It will be re-enabled once the GLES2 renderer is refactored to work
in Godot 4.0.
2020-02-13 00:29:17 +01:00
Hugo Locurcio
e10460e36f
Rename the "Last Modified" project list sorting option to "Last Edited"
The `project.godot` file will always be modified when editing a project,
but not when running it. This effectively makes the option sort by
last edition date, rather than modification as is typically understood
by users.

This closes #36127.
2020-02-12 18:13:32 +01:00
Teashrock
919293b369 Changed in-text driver name to "Vulkan"
But it still requires a change of "driver_name" in backend itself.
2020-02-12 11:07:33 +02:00
Juan Linietsky
3f335ce3d4 Texture refactor
-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
2020-02-11 11:53:26 +01:00
Rémi Verschelde
01d487c4f5 Merge pull request #34027 from Calinou/tweak-project-manager-renderer-selection
Improve the renderer selection display in the project manager
2020-02-10 11:28:32 +01:00
Rémi Verschelde
1ceba5a653 Merge pull request #35260 from Calinou/project-manager-enter-open-first
Select the first project when searching in the project manager
2020-02-10 11:16:47 +01:00
Rémi Verschelde
f5fa2b41df
Merge pull request #35892 from Calinou/project-manager-allow-hidden-files
Allow existing hidden files/directories when creating a new project
2020-02-06 11:21:17 +01:00
Haoyu Qiu
c1011178c0 Centers icon vertically in project list 2020-02-06 10:56:43 +08:00
Hugo Locurcio
34b747bac0
Allow existing hidden files/directories when creating a new project
For instance, this lets users initialize a Git repository
and still be able to create a project in the directory afterwards.

This closes https://github.com/godotengine/godot-proposals/issues/291.
2020-02-03 21:35:00 +01:00
Hugo Locurcio
56aae0e8bc
Use a loading placeholder for project icons in the project manager
Now that projects are loaded asynchronously, some projects in the
list may be displayed before their icon is done loading. This is
especially common on slower hardware.

In such cases, this makes the project manager display a loading
placeholder instead of the default project icon.
2020-01-21 22:56:19 +01:00
Hugo Locurcio
d72f5e0938
Only create the editor theme once
This prevents the editor theme from being created twice.
This speeds up the project editor and editor startup
significantly; startup is now 1.3 times faster on average
(tested on a debug build). RAM usage was also lowered by 7.5 MB
on average.

This partially addresses #35321.
2020-01-19 21:51:21 +01:00
Hugo Locurcio
2897918426
Select the first project when searching in the project manager
This makes the project manager usable for opening existing projects
without ever touching the mouse. Just enter text in the autofocused
search box and press Enter.

This partially addresses #8149.
2020-01-18 00:58:52 +01:00
Haoyu Qiu
047d66cc6f Fixes the New Window option in macOS dock menu 2020-01-13 08:58:12 +08:00
Rémi Verschelde
a7f49ac9a1 Update copyright statements to 2020
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.
2020-01-01 11:16:22 +01:00
Marc Gilleron
4c7d02dea1 Fix wrong project opening in some situations, hidden nodes were not reordered 2019-12-30 17:04:29 +00:00
Rémi Verschelde
45908eebf3 i18n: Sync translation template with current source 2019-12-17 11:47:29 +01:00
Haoyu Qiu
7a9c337dfe Makes more strings in editor translatable
* File type names in file dialogs
* Layout option names
* Visual shader editor UI
2019-12-16 16:41:07 +08:00
Rémi Verschelde
2845e6a21a
Merge pull request #34040 from qarmin/unused_variable_more_precise_numbers
Removed unused variables, add some constants numbers
2019-12-10 08:25:31 +01:00
Rafał Mikrut
ed1c4bc77d Removed unused variables, add some constants numbers 2019-12-10 05:13:02 +01:00
Hugo Locurcio
82c8751e65
Improve the renderer selection display in the project manager
- Format characteristics as a bullet-point list.
- Fade out secondary text to make other fields more prominent.
2019-12-07 23:00:27 +01:00
Haoyu Qiu
22b345c969 Fixes translation for project sort options 2019-12-04 15:17:45 +08:00
bruvzg
2f3db42de8
Update dock menu on project list changes, add favourites separator. 2019-10-24 13:25:21 +03:00
lupoDharkael
4753c51de6 Project Manager: Update template dialog position after window resize 2019-10-01 12:10:58 +02:00
Hugo Locurcio
76dd021a30
Don't open a project in the list if Ctrl is held while double-clicking 2019-09-23 17:25:37 +02:00
Hugo Locurcio
61299dc451
Focus the project manager's search box automatically on startup
This allows the user to search projects as soon as the project manager
opens, without having to click on the search field first.
2019-09-23 02:50:50 +02:00
Hugo Locurcio
9e5f1d6641
Add an "hover" style to items in the project manager
This makes the project manager feel more responsive to user input.
2019-09-13 02:34:05 +02:00
Hugo Locurcio
ef9f234d2b
Tweak the editor window dimming intensity, remove dim fade animation
The fade animation tended to give the editor a "sluggish" feel
when running at lower FPS (which is common in heavy 3D scenes),
so it's probably a good idea to remove it.

This also makes dimming less intense (50% instead of 60%).
2019-08-29 15:54:08 +02:00
Hugo Locurcio
5bd01bf637
Add a project description setting
The description is displayed as a tooltip when hovering the project
in the Project Manager. It can span multiple lines.

This partially addresses #8167.
2019-08-28 22:34:29 +02:00
Emmanuel Barroga
36e3996677 Fixes Keyup Navigation in Project Manager
This PR fixes the issue of navigation via keyup in the project manager not selecting the first item.
2019-08-27 10:15:37 -07:00
bruvzg
db6d4352ea
[macOS] Add methods to modify global and dock menus. Add ability to open multiple editor/project manager instances, recent/favourite project list to project manager dock menu and opened scene list to editor dock menu. 2019-08-26 16:45:49 +03:00
Hugo Locurcio
0271a5f1d8
Improve the display of missing projects in the Project Manager
- Use a "broken file" icon instead of a "folder" icon for missing
  projects
- Fade out the project icon for missing projects
- Use transparent modulate for grayed out projects as it results in
  better-looking text
- Disable the "Edit", "Run" and "Rename" buttons if at least
  one missing project is selected
- Make double-clicking or pressing Enter do nothing when a missing
  project is selected
- Change the "Open in FileSystem" tooltip accordingly for missing
  projects
- Don't connect the "Open in FileSystem" pressed signal to make the
  button ineffective for missing projects
- Name missing projects as "Missing Project" instead of
  "Unnamed Project"
2019-08-22 17:06:02 +02:00
Hugo Locurcio
3ae0306a1f
Tweak a few strings displayed in the editor for consistency 2019-08-21 19:33:29 +02:00
Rémi Verschelde
a4377ca465
Merge pull request #31356 from Calinou/improve-project-manager-ui
Improve the project manager UI
2019-08-20 12:55:15 +02:00
Hugo Locurcio
c0eee235c4
Define a minimum window size in the editor and project manager
This prevents most UI elements from overlapping or being cut off
as a result of the window being too small.

This closes #20669.
2019-08-17 21:56:59 +02:00
Hugo Locurcio
cef7ca4abb
Improve the project manager UI
This incorporates many suggestions from #31342.

This also revises the search behavior to be simpler and more efficient:

- Searching will now search in both the project name and path. A project
  will be displayed if either of these match the search term.
- If the search term contains a "/", the whole path will be used to match
  the search term. Otherwise, only the last path component will be used.
2019-08-17 13:48:25 +02:00
Emmanuel Barroga
1f5dc0ea3b Fixes ProjectManager Buttons Not Updating
Fixes buttons in ProjectManager not updating to disabled after deleting projects.
2019-08-14 18:30:42 -07:00
Tomasz Chabora
bd9a0a3236 Fix Project Manager not remembering sorting option 2019-08-14 13:09:04 +02:00
Hugo Locurcio
8f2bcfd909
Use Lanczos filtering for variable-sized images such as project icons
This results in better-looking icons with less artifacts
induced by downscaling.
2019-08-13 22:08:23 +02:00
Hugo Locurcio
6f6a9d9c09
Simplify editor settings related to window dimming
Only a single checkbox is now exposed to control whether the editor
window should be dimmed when opening a popup. The main use case
for disabling it is picking colors from the editor window while
a popup is open.
2019-07-26 15:29:04 +02:00
Marc Gilleron
d3652887df Project manager improvements
- Faster launch time by loading icons in a coroutine
- Faster sorting, filtering, fav'ing etc
- Refactored project list with a proper structured class
2019-07-21 20:47:25 +01:00
gaisama
f3b95560f4 Set a default value for project name when installing a project.
If I download a template named KewlGame, we should not force the user to have to type that name in order to complete the installation process.  The user can still rename it if they wish to but we should be providing a default value.  This quality of life enhancement will improve the workflow for newcomers to Godot who typically attempt to install a template as their first action within the program.
2019-07-10 18:40:29 -04:00
Tomasz Chabora
39e5c510fc Properly sort projects by name 2019-06-18 15:51:58 +02:00
Hugo Locurcio
bf97247cec
Improve the default project naming in the Project Manager
The Project Manager will now infer a project name from the
project path if the name is empty or equal to the default value.
The project name will also be capitalized automatically.
2019-06-15 00:01:44 +02:00
Hugo Locurcio
c9bc807ce4
Dim the project manager window while it's quitting
This makes it clearer that the project manager window is busy
while it's quitting (which can take a while on slower PCs).
This also makes it feel more responsive to user input.
2019-06-09 22:48:12 +02:00
Hugo Locurcio
dc981d8af7
Display longer Git hashes in engine version dialogs
Due to the high number of commits in the Godot repository,
7-character hashes were starting to become occasionally ambiguous.

In contrast, 9-character hashes are currently unambiguous for
all commits.
2019-06-01 13:52:58 +02:00
Rémi Verschelde
0d3ae2a415
Merge pull request #29198 from NilsIrl/seg_fault
Fix Segmentation fault and reduce memory consumption
2019-05-27 11:59:38 +02:00
Nils ANDRÉ-CHANG
a156b7976d Fix Segmentation fault and reduce memory consumption 2019-05-26 20:32:09 +01:00
Hugo Locurcio
deb7152724
Quit the Project Manager when Command + Q is pressed
This uses the same shortcut as quitting Godot while in the editor.

This partially addresses #27251.
2019-05-13 22:17:16 +02:00
qarmin
d9eaa3e093 Fix Remove Missing Project projects on Windows 2019-05-01 14:36:04 +02:00
Rémi Verschelde
5902e15b9b
Merge pull request #27187 from IronicallySerious/add-new-folder-button
Add 'Create Folder' button in Install Project dialog
2019-04-30 18:32:42 +02:00
Rémi Verschelde
1b08ba1a48
Merge pull request #25713 from qarmin/remove_all_missing_projects
Add button in Project Manager to remove all missing projects
2019-04-30 13:56:29 +02:00
Hugo Locurcio
35a0162167
Improve wording of various messages and make casing more consistent
This also adds the number of selected projects to the confirmation
dialog that appears before removing projects.
2019-04-21 14:37:14 +02:00
Twarit
0e62f5e6f7 Add 'Create Folder' button while installing templates
Fixes #25454
2019-04-10 11:23:13 +05:30