Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NormalizerNFKC: add unify_katakana_du_small_sounds option #1509

Merged
merged 3 commits into from
Feb 3, 2023

Conversation

HashidaTKS
Copy link
Contributor

@HashidaTKS HashidaTKS commented Feb 3, 2023

When unify_katakana_du_small_sounds is specified, NormalizerNFKC* normalize characters as below.

ヅァ -> ザ
ヅィ -> ジ
ヅェ -> ゼ
ヅォ -> ゾ

Usage:

normalize \
  'NormalizerNFKC130("unify_katakana_du_small_sounds", true, \
                     "report_source_offset", true)' \
  "ヅァヅィヅェヅォ" \
  WITH_CHECKS|WITH_TYPES

@HashidaTKS HashidaTKS changed the title Add unify_katakana_d_sounds option NormalizerNFKC: add unify_katakana_d_sounds option Feb 3, 2023
@HashidaTKS HashidaTKS marked this pull request as ready for review February 3, 2023 06:10
@kou
Copy link
Member

kou commented Feb 3, 2023

Ah, we should have used du_sounds, gu_sounds and zu_sounds for option name...

@HashidaTKS
Copy link
Contributor Author

HashidaTKS commented Feb 3, 2023

Ah, we should have used du_sounds, gu_sounds and zu_sounds for option name...

Hmm, if d_sounds is renamed to du_sounds and z_sounds to zu_sounds, what should be named a normalizer for to ?
Should du_sounds also normalize to ?

@kou
Copy link
Member

kou commented Feb 3, 2023

what should be named a normalizer for to ?

du_sound?

Should du_sounds also normalize to ?

Hmm. du_small_sounds?

@HashidaTKS
Copy link
Contributor Author

what should be named a normalizer for to ?

du_sound?

Should du_sounds also normalize to ?

Hmm. du_small_sounds?

Thanks!
By apply your comments, I would like to name them as below.

  • This pull request: du_small_sounds
  • The normalizer for to : du_sound

@HashidaTKS HashidaTKS changed the title NormalizerNFKC: add unify_katakana_d_sounds option NormalizerNFKC: add unify_katakana_du_small_sounds option Feb 3, 2023
@HashidaTKS
Copy link
Contributor Author

HashidaTKS commented Feb 3, 2023

Renamed.
I will rename g_sounds to gu_sounds and z_sounds to zu_sounds as following task (in other pull requests).

lib/normalizer.c Outdated Show resolved Hide resolved
@kou kou merged commit d94da4f into master Feb 3, 2023
@kou kou deleted the add-unify_katakana_d_sounds branch February 3, 2023 09:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants