1
0
Fork 0
mirror of https://github.com/alacritty/alacritty.git synced 2025-11-06 22:44:18 -05:00

Bump dependencies

This performs all non-breaking dependency updates, which includes
unicode-width 0.2.2 for Unicode 17 support.
This commit is contained in:
Christian Duerr 2025-10-08 12:05:01 +00:00 committed by GitHub
parent fa36b3abb1
commit 48e19ec3cb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 356 additions and 409 deletions

View file

@ -31,6 +31,7 @@ Notable changes to the `alacritty_terminal` crate are documented in its
- Multi-sequence touch zoom sequences
- Vi action `Y` keybind, yank to the end of line
- Add `/etc/alacritty/alacritty.toml` fallback for system wide configuration
- Unicode 17 support
### Changed

720
Cargo.lock generated

File diff suppressed because it is too large Load diff

View file

@ -517,7 +517,5 @@ fn use_srgb_color_space(window: &WinitWindow) {
_ => return,
};
unsafe {
view.window().unwrap().setColorSpace(Some(&NSColorSpace::sRGBColorSpace()));
}
view.window().unwrap().setColorSpace(Some(&NSColorSpace::sRGBColorSpace()));
}

View file

@ -48,29 +48,27 @@ pub fn set_locale_environment() {
/// Determine system locale based on language and country code.
fn system_locale() -> String {
unsafe {
let locale = NSLocale::currentLocale();
let locale = NSLocale::currentLocale();
// `localeIdentifier` returns extra metadata with the locale (including currency and
// collator) on newer versions of macOS. This is not a valid locale, so we use
// `languageCode` and `countryCode`, if they're available (macOS 10.12+):
//
// https://developer.apple.com/documentation/foundation/nslocale/1416263-localeidentifier?language=objc
// https://developer.apple.com/documentation/foundation/nslocale/1643060-countrycode?language=objc
// https://developer.apple.com/documentation/foundation/nslocale/1643026-languagecode?language=objc
let is_language_code_supported: bool = locale.respondsToSelector(sel!(languageCode));
let is_country_code_supported: bool = locale.respondsToSelector(sel!(countryCode));
if is_language_code_supported && is_country_code_supported {
let language_code = locale.languageCode();
#[allow(deprecated)]
if let Some(country_code) = locale.countryCode() {
format!("{}_{}.UTF-8", language_code, country_code)
} else {
// Fall back to en_US in case the country code is not available.
"en_US.UTF-8".into()
}
// `localeIdentifier` returns extra metadata with the locale (including currency and
// collator) on newer versions of macOS. This is not a valid locale, so we use
// `languageCode` and `countryCode`, if they're available (macOS 10.12+):
//
// https://developer.apple.com/documentation/foundation/nslocale/1416263-localeidentifier?language=objc
// https://developer.apple.com/documentation/foundation/nslocale/1643060-countrycode?language=objc
// https://developer.apple.com/documentation/foundation/nslocale/1643026-languagecode?language=objc
let is_language_code_supported: bool = locale.respondsToSelector(sel!(languageCode));
let is_country_code_supported: bool = locale.respondsToSelector(sel!(countryCode));
if is_language_code_supported && is_country_code_supported {
let language_code = locale.languageCode();
#[allow(deprecated)]
if let Some(country_code) = locale.countryCode() {
format!("{}_{}.UTF-8", language_code, country_code)
} else {
locale.localeIdentifier().to_string() + ".UTF-8"
// Fall back to en_US in case the country code is not available.
"en_US.UTF-8".into()
}
} else {
locale.localeIdentifier().to_string() + ".UTF-8"
}
}