summaryrefslogtreecommitdiffstats
path: root/tests/core/string
Commit message (Collapse)AuthorAgeFilesLines
* Merge commit godotengine/godot@d09d82d433b03bb3773fd2a8cc8d6ccc2f8739ceSpartan3222024-11-261-0/+30
|\
| * Expose standardize_locale add_default param publiclyDan Nicholson2024-11-211-0/+30
| | | | | | | | | | | | | | | | Comparing locales can have surprising outcomes since it standardizes locales with defaults. For example, zh and zh_CN result in an exact match since the defaults change them both to zh_Hans_CN. Expose the add_default parameter publicly with a default of false so the fully standardized locale can be inspected.
* | Merge commit godotengine/godot@cb411fa960f0b7fdbd97dcdb4c90f9346360ee0eSpartan3222024-11-122-15/+75
|\|
| * Merge pull request #98743 from dbnicholson/improve-compare-localesThaddeus Crews2024-11-121-4/+54
| |\ | | | | | | | | | Improve locale comparison
| | * Improve locale comparisonDan Nicholson2024-11-121-4/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since 9456454109, country specific locales are always preferred over country-less locales even when the OS locale country doesn't match. For example, running the Godot editor with locale es_ES will result in the es_AR locale being chosen even though the es locale would be better. The change happened because the score of the es_AR locale and the es locale are the same when comparing to es_ES. Change this by parsing locale strings into a Locale structure and decreasing the score when script, country or variant are set in both but not matched. For the es_ES case, this causes the es_AR score to be decreased since the countries don't match. On the other hand, the es locale is not decreased since it doesn't specify a country.
| * | Merge pull request #98547 from timothyqiu/loaded-locales-setThaddeus Crews2024-11-111-10/+20
| |\ \ | | | | | | | | | | | | Fix duplicated entries in `TranslationServer::get_loaded_locales()`
| | * | Fix duplicated entries in `TranslationServer::get_loaded_locales()`Haoyu Qiu2024-10-261-10/+20
| | | |
| * | | Allow passing UID to importerJuan2024-11-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This helps, for importers spitting out new resources to the res:// filesystem to actually hash them to generate deterministic UIDs. This PR also fixes the determinism for translations.
* | | | Merge commit godotengine/godot@0f5f3bc9546b46b2029fc8896dc859697f1eab97Spartan3222024-11-112-0/+104
|\| | |
| * | | Merge pull request #98278 from a-johnston/fuzzy-search-rebaseThaddeus Crews2024-11-102-0/+102
| |\ \ \ | | |_|/ | |/| | | | | | Add fuzzy string matching to quick open search
| | * | Add fuzzy string matching to quick open searchAdam Johnston2024-10-282-0/+102
| | |/ | | | | | | | | | Co-authored-by: sam <samsface@gmail.com>
* | | Merge commit godotengine/godot@c6c464cf9ae56e8b68620af65125dd980d0e8122Spartan3222024-11-021-12/+12
|\| |
| * | Merge pull request #47502 from KoBeWi/add_0Thaddeus Crews2024-10-311-12/+12
| |\ \ | | |/ | |/| | | | Always add decimal when converting float to string
| | * Always add decimal when printing floatkobewi2024-10-231-12/+12
| | |
* | | Merge pull request #818 from Spartan322/fixup/copyright-headersGeorge L. Albany2024-10-274-8/+8
|\ \ \ | | | | | | | | Fix copyright headers referring to Godot
| * | | Fix copyright headers referring to GodotSpartan3222024-10-274-8/+8
| | | |
* | | | Merge commit godotengine/godot@61accf060515416da07d913580419fd8c8490f7bSpartan3222024-10-261-1/+17
|\ \ \ \ | |/ / / |/| / / | |/ /
| * / Add checks for valid base in String::num_int64, uint64().yeojunh2024-10-201-1/+17
| |/ | | | | | | | | | | - Ensure String::num_int64, uint64 returns an empty string for bases less than 2 or greater than 36. - Added corresponding test cases to verify the behavior. - Error messages are printed when invalid bases are encountered. These messages are suppressed in the test output.
* | Rebrand preambles to RedotDubhghlas McLaughlin2024-10-114-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Credits: Co-authored-by: Skogi <skogi.b@gmail.com> Co-authored-by: Spartan322 <Megacake1234@gmail.com> Co-authored-by: swashberry <swashdev@pm.me> Co-authored-by: Christoffer Sundbom <christoffer_karlsson@live.se> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: McDubh <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: radenthefolf <radenthefolf@gmail.com> Co-authored-by: John Knight <80524176+Tekisasu-JohnK@users.noreply.github.com> Co-authored-by: Adam Vondersaar <adam.vondersaar@uphold.com> Co-authored-by: decryptedchaos <nixgod@gmail.com> Co-authored-by: zaftnotameni <122100803+zaftnotameni@users.noreply.github.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: wesam <108880473+wesamdev@users.noreply.github.com> Co-authored-by: Mister Puma <MisterPuma80@gmail.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: SingleError <isaaconeoneone@gmail.com> Co-authored-by: Bioblaze Payne <BioblazePayne@gmail.com>
* | Rebrand Godot to RedotRandolph W. Aarseth II2024-10-111-40/+53
|/ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add Linux Editor tests workflow matrix Add Windows Editor w/ Mono workflow matrix Add Generate Glue Code job to Windows workflow Add Build GodotSharp job to Windows workflow Add godot compatibility version references Add Godot author info Add Godot version compatibility info Add Godot donor info Add Godot authors and donors to editor_about.cpp Credits: Co-authored-by: Skogi <skogi.b@gmail.com> Co-authored-by: Spartan322 <Megacake1234@gmail.com> Co-authored-by: swashberry <swashdev@pm.me> Co-authored-by: Christoffer Sundbom <christoffer_karlsson@live.se> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: McDubh <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: Dubhghlas McLaughlin <103212704+mcdubhghlas@users.noreply.github.com> Co-authored-by: radenthefolf <radenthefolf@gmail.com> Co-authored-by: John Knight <80524176+Tekisasu-JohnK@users.noreply.github.com> Co-authored-by: Adam Vondersaar <adam.vondersaar@uphold.com> Co-authored-by: decryptedchaos <nixgod@gmail.com> Co-authored-by: zaftnotameni <122100803+zaftnotameni@users.noreply.github.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: wesam <108880473+wesamdev@users.noreply.github.com> Co-authored-by: Mister Puma <MisterPuma80@gmail.com> Co-authored-by: Aaron Benjamin <lifeartstudios@gmail.com> Co-authored-by: SingleError <isaaconeoneone@gmail.com> Co-authored-by: Bioblaze Payne <BioblazePayne@gmail.com>
* Add unit tests for String::parse_url()Pablo Andres Fuente2024-10-011-38/+53
|
* Parse fragment from URLHaoyu Qiu2024-09-271-0/+40
|
* Fix script editor wrongly replaces and quotes non-ASCII lettersHaoyu Qiu2024-09-231-1/+15
|
* Added more unit tests for String insert and join.Mika Viskari2024-08-291-3/+28
|
* Add `String.is_valid_unicode_identifier()`Haoyu Qiu2024-08-271-13/+15
| | | | | | | - Adds `is_valid_unicode_identifier()` - Adds `is_valid_ascii_identifier()` - Deprecates `is_valid_identifier()` - Renames `validate_identifier()` to `validate_ascii_identifier()`
* Merge pull request #95184 from jsjtxietian/shader-include-relativeRémi Verschelde2024-08-171-1/+1
|\ | | | | | | Fix `String::simplify_path` handling of relative paths to parent dir (`../`), fixes relative shader includes
| * Fix error when use relative #include in .gdshader / .gdshaderinc filejsjtxietian2024-08-081-1/+1
| |
* | Merge pull request #95613 from timothyqiu/split-emptyRémi Verschelde2024-08-161-48/+74
|\ \ | | | | | | | | | Fix `split_floats` behavior when spaces are used as separators
| * | Fix split_floats behavior when spaces are used as separatorsHaoyu Qiu2024-08-161-48/+74
| |/
* / Split TranslationServer into its own fileHaoyu Qiu2024-08-152-1/+2
|/
* [Core] Add case-insensitive `String::containsn`A Thousand Ships2024-05-081-1/+14
|
* Add const char * overloads to String classWilson E. Alvarez2024-05-071-139/+151
| | | | Co-authored-by: A Thousand Ships <96648715+AThousandShips@users.noreply.github.com>
* [Core] Fix incorrect file sort methodA Thousand Ships2024-03-241-0/+2
|
* Fix sorting of files/dirs in dialogsA Thousand Ships2024-03-201-0/+8
| | | | Sorts leading `_` before other characters except `.`.
* Fix String::begins_with when both strings are emptyMika Viskari2024-03-051-26/+37
|
* Merge pull request #81822 from nlupugla/nodepath-sliceRémi Verschelde2024-02-291-0/+53
|\ | | | | | | Add `NodePath::slice` method
| * Added NodePath::slice method.nlupugla2023-12-131-0/+53
| |
* | Fix running tests in template buildsA Thousand Ships2024-02-221-1/+1
| |
* | Add Unicode support to `String.to_*_case()` methodsDanil Alexeev2024-02-221-25/+40
| |
* | Fix various spelling errorsRobert Yevdokimov2024-01-041-11/+11
|/
* Add more C++ unit tests for String to number conversionsMika Viskari2023-12-021-9/+72
|
* Do not replace starting digit with underscore when making identifierAlfonso J. Ramos2023-10-041-1/+1
|
* [String] Fix string conversion for -0.0 float values.bruvzg2023-09-051-0/+16
|
* Merge pull request #78529 from Chaosus/string_reverseRémi Verschelde2023-08-161-0/+5
|\ | | | | | | Add `String.reverse` method
| * Add `String.reverse` methodYuri Roubinski2023-06-211-0/+5
| |
* | Merge pull request #80362 from Calinou/string-use-unicode-compiletimeRémi Verschelde2023-08-071-3/+3
|\ \ | | | | | | | | | Use compile-time Unicode string conversion
| * | Use compile-time Unicode string conversionHugo Locurcio2023-08-071-3/+3
| | | | | | | | | | | | | | | Thanks to this syntax introduced in C++11, this reduces the amount of work that needs to be performed at run-time while making the code more terse.
* | | Add a test suite for TranslationServerazuloo2023-07-111-0/+136
|/ /
* | Fix erroneous pad_zeros warningMewPurPur2023-07-081-0/+2
| |
* | Merge pull request #74760 from lassade/unicode-err-uses-replacement-charRémi Verschelde2023-06-221-5/+5
|\ \ | |/ |/| | | Don't append non unicode scalar values on the string, instead use the unicode replacement char