-
-
Notifications
You must be signed in to change notification settings - Fork 24k
Don't compile advanced Control nodes if disable_advanced_gui is on
#103291
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Conversation
b13a13d to
4cac2ec
Compare
4cac2ec to
285907d
Compare
98e89a5 to
85bf5f0
Compare
c80c663 to
dbdac13
Compare
|
This makes sense on the surface. I'm hoping it doesn't break GDExtension compatibility though. |
dbdac13 to
a0c8d85
Compare
d5fd991 to
c55b1cb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested locally, it works as expected.
Binary size for a stripped Linux x86_64 release export template with LTO (scons platform=linuxbsd target=template_release optimize=speed lto=full):
master: 72,031,960 bytes- This PR: 72,036,056 bytes (+ 5 KB)
masterwithdisable_advanced_gui=yes: 69,324,408 bytes- This PR with
disable_advanced_gui=yes: 69,099,096 bytes (-225 KB)
6ba0ab1 to
23a4954
Compare
23a4954 to
915e960
Compare
|
I tested this and I don't think the gains are worth the awkward Here's my test results for this PR and master (Linux x86_64
So the changes in this PR only strip an extra 195 KiB, which is IMO not worth breaking all PRs and well-used include paths for. In fact, this option predates the build profile feature, and arguably isn't particularly well designed nowadays as it just removes an arbitrary set of control nodes, some of which may be needed for games which aren't GUI heavy (e.g. RichTextLabel). Build profiles (once made to reliably detect what a project uses) should be much finer and more useful. |
This PR is a little intrusive I'm afraid. It does two things:
Controls that are categorized as "advanced" to a folder called, well, "advanced". Due to this, a lot of files are touched to updated the path for header includes.disable_advanced_guiis turned on. Before, it just didn't register the classes.Here are the size comparasions. GNU/Linux, release templates (this time
dev_buildis turned off as well. 🙃). It saves almost 3 MB:Sponsored By: 🐺 Lone Wolf Technology / 🍀 W4 Games.