Commit Graph

256 Commits

Author SHA1 Message Date
0fb7e3fc57 Merge pull request #88339 from Rubonnek/remove-hashunion
Remove `_HashUnion` from `StringName`
2024-02-15 15:45:19 +01:00
d2003d2025 Remove _HashUnion from StringName 2024-02-14 15:38:57 -05:00
a8bc9f3e78 Add const lvalue ref to core/* container parameters 2024-02-14 11:20:36 -03:00
5ee4b49e42 Link xid_start and xid_continue externally to prevent data duplication in binary 2024-02-11 12:54:53 +01:00
15369fdb1d Remove unnecessary this-> expressions 2024-01-29 09:59:18 +01:00
e7bdb60e56 [Pseudolocalization] Prevent out of bounds reads. 2024-01-05 14:10:26 +02:00
5fd5176a79 Merge pull request #84462 from MewPurPur/optimize-humanizesize
Optimize `String.humanize_size()`
2024-01-04 14:25:40 +01:00
6c390b620d Merge pull request #84445 from Rubonnek/add-const-references-clang-tidy
Add const references detected by clang-tidy
2024-01-04 14:25:33 +01:00
b66d16fcc9 Merge pull request #84375 from Rubonnek/use-const-reference
Add const references in `String` class
2024-01-04 14:25:27 +01:00
a3cb1b096f Add const references detected by clang-tidy 2023-12-16 13:36:44 -05:00
41365c6c8b Merge pull request #70315 from RandomShaper/d3d12_mesa
Direct3D 12 Rendering Driver (Mesa NIR approach)
2023-12-12 21:58:57 +01:00
829349d2ca Do not reload resources and send notification if locale is not changed. 2023-12-05 16:17:22 +02:00
208c1020f5 Add 'u' format modifier for unsigned int/hex 2023-12-01 16:42:26 +01:00
ec052cd38a Add unsigned char cast ifdef. 2023-11-29 11:59:18 +02:00
8b2260544a Fix remapped font reloading on locale change. 2023-11-13 21:25:41 +02:00
edcad2ea88 Allow auto-generated node names in PopupMenu::add_submenu_item 2023-11-09 17:12:41 +01:00
f3d4f5a77e [X11] Add fallback from desktop GL to GLES, suppress PRIME detector error spam. 2023-11-06 12:40:44 +02:00
931928feb9 Optimize String.humanize_size() 2023-11-05 02:42:54 +02:00
dbc49d2a68 Add const references in String class 2023-11-02 13:49:39 -04:00
4952d37f4b Fix StringName leaks in VariantParser 2023-10-19 17:13:15 +02:00
5cd7ca0ccc Do not replace starting digit with underscore when making identifier 2023-10-04 08:05:04 -05:00
43be9fa0c8 Fix platform-dependent hashing for char* and wchar_t*
Since char/wchar_t can be either signed or unsigned, its conversion to uint32_t leads to different values depending on platform.
In particular, the same string represented as char* (Latin-1; StringName direct construction) or uint32_t (UTF-8; constructed
via String) previously resulted in different hashes.
2023-09-24 20:57:57 +02:00
893f889d74 [Core] Replace ERR_FAIL_COND with ERR_FAIL_NULL where applicable 2023-09-11 19:45:49 +02:00
d8ff69d53c Extract ScriptInstance to simplify includes
This allows to include script_instance.h directly in the
generated gdvirtual.gen.inc, and remove excessive includes
from the codebase.

This should also allow Resource to use GDVIRTUAL macros,
which wasn't possible previously due to a circular dependency.
2023-09-06 22:54:38 +02:00
2b3bbde6da [String] Fix string conversion for -0.0 float values. 2023-09-05 11:32:55 +03:00
c9287e5224 Optimize String.left() and String.right() 2023-08-20 20:01:06 +03:00
20e24bd2bb Merge pull request #78529 from Chaosus/string_reverse
Add `String.reverse` method
2023-08-16 16:53:40 +02:00
835957b1fc Merge pull request #79980 from bruvzg/fix_test_str_errs
[String] Fix Unicode parsing error message encoding and related JSON tests.
2023-08-09 15:20:16 +02:00
8654ba130b Merge pull request #79654 from timothyqiu/han
Fix script name of Hant and Hans
2023-08-01 17:25:21 +02:00
84a6f0d232 [String] Fix Unicode parsing error message encoding and related JSON tests. 2023-07-28 12:27:01 +03:00
7c204874eb Merge pull request #78747 from RandomShaper/fix_trans_threading
Support loading of translations on threads
2023-07-26 18:39:27 +02:00
52cdba6def Fix script name of Hant and Hans 2023-07-20 15:01:39 +08:00
f0c24f3145 Merge pull request #79017 from bruvzg/esc_fix
[Terminal Output] Reset text properties after `print_rich`.
2023-07-14 18:49:26 +02:00
cc5500f7de Fix erroneous pad_zeros warning 2023-07-08 16:16:01 +03:00
0e8cb304a5 [Terminal Output] Reset text properties after print_rich. 2023-07-04 14:09:28 +03:00
5301bbb3a5 Support loading of translations on threads 2023-06-29 16:48:55 +02:00
100082b3ac Merge pull request #74760 from lassade/unicode-err-uses-replacement-char
Don't append non unicode scalar values on the string, instead use the unicode replacement char
2023-06-22 18:30:04 +02:00
230385b587 Add String.reverse method 2023-06-21 20:40:48 +03:00
d2ddd8b228 Fix StringName comparison 2023-05-18 13:25:40 +02:00
5ade250c7d Merge pull request #76735 from AThousandShips/natural_cmp
Add `naturalcasecmp_to` function to `String`
2023-05-09 17:44:37 +02:00
491a437df5 Merge pull request #76540 from reduz/redo-remote-filesystem
Redo how the remote filesystem works
2023-05-08 13:52:51 +02:00
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
46a7018e3c Add naturalcasecmp_to function to String
Functions as a complement to `naturalnocasecmp_to`
2023-05-07 10:17:53 +02:00
7a13cf9aeb Merge pull request #75510 from SilicDev/string_erase
Reimplement `String.erase()` as immutable method
2023-05-05 10:03:49 -07:00
610877e326 Merge pull request #72288 from MewPurPur/use-string-repeat
Use `String.repeat()` to optimize several String methods
2023-05-05 09:56:48 -07:00
6fa4f71ca6 Reimplement String.erase 2023-05-04 00:52:35 +02:00
6b84e258d2 Use String.repeat() in more places 2023-05-01 02:27:46 +02:00
36bedd341a Fix misuses of error macros 2023-04-18 10:20:48 +03:00
8950943356 Optimize Object::get_class_name
* Run the static function once per class instead of one per instance.
* Saves some memory in Object derived classes.
2023-04-08 19:25:50 +02:00
223ce4fcb9 Optimize Node::add_child validation
Adding 10k nodes is almost twice as fast.
2023-04-07 13:18:47 +02:00