This PR also adds default font styles for RichTextLabels
in the editor, and improves the introduction dialog
when you don't have any local projects available.
The offline mode is implemented in the asset library
plugin, alongside some code improvements.
Not everything is yet implemented, either for Godot or personal
limitations (I don't have all hardware in the world). A brief list of
the most important issues follows:
- Single-window only: the `DisplayServer` API doesn't expose enough
information for properly creating XDG shell windows.
- Very dumb rendering loop: this is very complicated, just know that
the low consumption mode is forced to 2000 Hz and some clever hacks are
in place to overcome a specific Wayland limitation. This will be
improved to the extent possible both downstream and upstream.
- Features to implement yet: IME, touch input, native file dialog,
drawing tablet (commented out due to a refactor), screen recording.
- Mouse passthrough can't be implement through a poly API, we need a
rect-based one.
- The cursor doesn't yet support fractional scaling.
- Auto scale is rounded up when using fractional scaling as we don't
have a per-window scale query API (basically we need
`DisplayServer::window_get_scale`).
- Building with `x11=no wayland=yes opengl=yes openxr=yes` fails.
This also adds a new project property and editor setting for selecting the
default DisplayServer to start, to allow this backend to start first in
exported projects (X11 is still the default for now). The editor setting
always overrides the project setting.
Special thanks to Drew Devault, toger5, Sebastian Krzyszkowiak, Leandro
Benedet Garcia, Subhransu, Yury Zhuravlev and Mara Huldra.
This change adds a new editor setting related to theming
which controls base and additional spacing used in the
generated editor theme. These values can also be changed
manually by the user to customize their experience.
Limited effort was applied to make sure both Compact and
Spacious presets work and look fine, but further tuning
and adjustments are totally expected. Some controls will
require layout changes or additional fixes to their constants.
Fixes the issue by adding a mechanism by which the functions that were
previously disappearing can be profiled too. This is optional with
an editor setting, since collecting more information naturally slows the engine
further while profiling.
Fixes#23715, #40251, #29049
This prevents using zero or negative values, which are invalid and
will cause various issues in the editor (such as the inspector never
updating until the editor is closed and reopened).
The follow options were added to the (new) `run/window_placement/android_window` editor setting:
- `Same as Editor`: run the project in the same window as the editor
- `Side-by-side with Editor`: run the project in an adjacent window to the editor
- `Auto`: choose how to run the project based on the device screen size
We initially added an option to disable constraining the 2D editor view.
This setting was still enabled by default to avoid confusing users
who end up scrolling too far away from their current scene
(which is a problem if you don't know about the F key to focus
on the selection).
However, it's probably a better choice to unconstrain the 2D editor view
by default because:
- Lots of people don't know about this setting and wonder how they
can scroll far away from the scene. This feels really limiting for them,
and it can even lead to some people thinking Godot intentionally limits
scene sizes.
- The 3D editor doesn't have such a contrain mechanism.
This makes the 2D editor more consistent with the 3D editor.
When enabled, this scales the editor icons to improve usability on touchscreen devices.
In addition this commit fixes touch detection for the collision_shape_2d_editor_plugin so it scales with the icons size.
The project manager can now only create projects that use a rendering
method compatible with the current platform. Rendering methods that
are disabled at build-time are also grayed out (only for OpenGL).
While it is possible in theory to create a project using Forward+
on web (thanks to the automatic fallback),
it will look different once edited on a desktop platform.