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

[segmenter] Add word segmentation #134

Merged
merged 6 commits into from
Jan 30, 2024
Merged

[segmenter] Add word segmentation #134

merged 6 commits into from
Jan 30, 2024

Conversation

benoitkugler
Copy link
Contributor

This PR adds support for breaking text on words. The entry point is the new WordIterator type and the related Segmenter.WordIterator() method.

My personal use case is to detect words when doing hyphenation.

For other uses cases, it might for example be useful to implement functionality such as "Select current word".

Note that we also have some (minor) changes on generated data since I've updated the Unicode version to 15.1.

Copy link
Member

@whereswaldon whereswaldon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice work! Seems straightforward to me.

Copy link
Contributor

@andydotxyz andydotxyz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cool :)

@andydotxyz andydotxyz merged commit deb5cd1 into main Jan 30, 2024
20 checks passed
@andydotxyz andydotxyz deleted the break-props branch January 30, 2024 17:24
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.

3 participants