From d3f314df9cb15b22cd6a3a7193a85473ceb1021f Mon Sep 17 00:00:00 2001 From: Jan Guegel Date: Mon, 15 Dec 2025 15:27:47 +0100 Subject: [PATCH 1/2] fix double spaces in contacts --- CHANGELOG.md | 2 ++ .../kotlin/org/fossify/contacts/adapters/ContactsAdapter.kt | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 92e293158..a0881b620 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Fixed invisible navigation bars in contact viewer ([#415]) - Fixed search highlighting for characters with accents and diacritics ([#12]) +- Fixed spacing for double in contact names ([#157]) ## [1.4.0] - 2025-10-29 ### Changed @@ -102,6 +103,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 [#12]: https://github.com/FossifyOrg/Contacts/issues/12 [#30]: https://github.com/FossifyOrg/Contacts/issues/30 [#78]: https://github.com/FossifyOrg/Contacts/issues/78 +[#157]: https://github.com/FossifyOrg/Contacts/issues/157 [#201]: https://github.com/FossifyOrg/Contacts/issues/201 [#281]: https://github.com/FossifyOrg/Contacts/issues/281 [#289]: https://github.com/FossifyOrg/Contacts/issues/289 diff --git a/app/src/main/kotlin/org/fossify/contacts/adapters/ContactsAdapter.kt b/app/src/main/kotlin/org/fossify/contacts/adapters/ContactsAdapter.kt index 0c936e0bf..743b177ef 100644 --- a/app/src/main/kotlin/org/fossify/contacts/adapters/ContactsAdapter.kt +++ b/app/src/main/kotlin/org/fossify/contacts/adapters/ContactsAdapter.kt @@ -389,7 +389,7 @@ class ContactsAdapter( view.apply { setupViewBackground(activity) findViewById(org.fossify.commons.R.id.item_contact_frame)?.isSelected = selectedKeys.contains(contact.id) - val fullName = contact.getNameToDisplay() + val fullName = contact.getNameToDisplay().replace(Regex("\\s+"), " ") findViewById(org.fossify.commons.R.id.item_contact_name).text = if (textToHighlight.isEmpty()) fullName else { val normalizedFullName = fullName.normalizeString() val normalizedSearchText = textToHighlight.normalizeString() From 5d3daa3572fa292841e971837ddff0160ca60ef3 Mon Sep 17 00:00:00 2001 From: Jan Guegel Date: Mon, 15 Dec 2025 15:29:49 +0100 Subject: [PATCH 2/2] fix typo --- CHANGELOG.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index a0881b620..393b8e868 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,7 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 ### Fixed - Fixed invisible navigation bars in contact viewer ([#415]) - Fixed search highlighting for characters with accents and diacritics ([#12]) -- Fixed spacing for double in contact names ([#157]) +- Fixed wrong spacing in contact names ([#157]) ## [1.4.0] - 2025-10-29 ### Changed