mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-08-01 13:49:16 +00:00
LibUnicode: Implement the range pattern processing algorithm
This algorithm is to inject spacing around the range separator under certain conditions. For example, in en-US, the range [3, 5] should be formatted as "3–5" if unitless, but as "$3 – $5" for currency.
This commit is contained in:
parent
b2709f161e
commit
0a6363d3e9
Notes:
sideshowbarker
2024-07-17 08:44:20 +09:00
Author: https://github.com/trflynn89
Commit: 0a6363d3e9
Pull-request: https://github.com/SerenityOS/serenity/pull/14631
Reviewed-by: https://github.com/linusg ✅
2 changed files with 45 additions and 10 deletions
|
@ -71,5 +71,6 @@ Vector<NumberFormat> get_compact_number_system_formats(StringView locale, String
|
|||
Vector<NumberFormat> get_unit_formats(StringView locale, StringView unit, Style style);
|
||||
|
||||
Optional<String> augment_currency_format_pattern(StringView currency_display, StringView base_pattern);
|
||||
Optional<String> augment_range_pattern(StringView range_separator, StringView lower, StringView upper);
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue