From 9ee2918904dd5c6bd2c6b4ef42cff0dc3f0c8acb Mon Sep 17 00:00:00 2001 From: getsnoopy Date: Mon, 6 Nov 2023 17:59:49 +0000 Subject: [PATCH] system, region: Fix name of the US measurement system This commit fixes the name of the US measurement system in the format preview to the correct name, as the US uses US customary units, not imperial units (which are only used in the UK and Canada). --- panels/system/region/cc-format-preview.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/panels/system/region/cc-format-preview.c b/panels/system/region/cc-format-preview.c index 895f063e73..cfdac882ba 100644 --- a/panels/system/region/cc-format-preview.c +++ b/panels/system/region/cc-format-preview.c @@ -69,7 +69,7 @@ update_format_examples (CcFormatPreview *self) g_autofree gchar *s = NULL; #ifdef LC_MEASUREMENT const gchar *fmt; - gboolean is_imperial = FALSE; + gboolean is_us_customary = FALSE; #endif g_autoptr(GtkPaperSize) paper = NULL; @@ -136,7 +136,7 @@ update_format_examples (CcFormatPreview *self) fmt = nl_langinfo (_NL_MEASUREMENT_MEASUREMENT); /* The returned pointer of nl_langinfo could be invalid after switching locale, so we must use it here. */ - is_imperial = fmt && *fmt == 2; + is_us_customary = fmt && *fmt == 2; if (locale != (locale_t) 0) { @@ -144,8 +144,9 @@ update_format_examples (CcFormatPreview *self) freelocale (locale); } - if (is_imperial) - adw_action_row_set_subtitle (self->measurement_format_row, C_("measurement format", "Imperial")); + if (is_us_customary) + /* Translators: "US Customary" refers to the measurement system as used in the USA */ + adw_action_row_set_subtitle (self->measurement_format_row, C_("measurement format", "US Customary")); else adw_action_row_set_subtitle (self->measurement_format_row, C_("measurement format", "Metric")); -- GitLab