gpui: Treat typographic apostrophes as word characters for line wrapping#51973
Merged
eholk merged 2 commits intozed-industries:mainfrom Mar 19, 2026
Merged
gpui: Treat typographic apostrophes as word characters for line wrapping#51973eholk merged 2 commits intozed-industries:mainfrom
eholk merged 2 commits intozed-industries:mainfrom
Conversation
The line wrapper's is_word_char function included the ASCII apostrophe (U+0027) but not the typographic right single quotation mark (U+2019) or left single quotation mark (U+2018). When Markdown rendering produces curly quotes, words like won't were being split at the apostrophe during line wrapping.
mikayla-maki
approved these changes
Mar 19, 2026
AmaanBilwar
pushed a commit
to AmaanBilwar/zed
that referenced
this pull request
Mar 20, 2026
…ing (zed-industries#51973) The line wrapper's `is_word_char` function included the ASCII apostrophe (U+0027) but not the typographic right single quotation mark `'` (U+2019) or left single quotation mark `'` (U+2018). When Markdown rendering produces curly quotes, words like `won't` were being split at the apostrophe during line wrapping, producing `won` at the end of one line and `'t` at the start of the next. This adds both typographic quote characters to `is_word_char` so they are treated the same as the ASCII apostrophe. Release Notes: - Fixed line wrapping splitting words at typographic apostrophes (e.g. "won't" breaking as "won" / "'t").
toshmukhamedov
pushed a commit
to toshmukhamedov/zed
that referenced
this pull request
Mar 20, 2026
…ing (zed-industries#51973) The line wrapper's `is_word_char` function included the ASCII apostrophe (U+0027) but not the typographic right single quotation mark `'` (U+2019) or left single quotation mark `'` (U+2018). When Markdown rendering produces curly quotes, words like `won't` were being split at the apostrophe during line wrapping, producing `won` at the end of one line and `'t` at the start of the next. This adds both typographic quote characters to `is_word_char` so they are treated the same as the ASCII apostrophe. Release Notes: - Fixed line wrapping splitting words at typographic apostrophes (e.g. "won't" breaking as "won" / "'t").
AmaanBilwar
pushed a commit
to AmaanBilwar/zed
that referenced
this pull request
Mar 23, 2026
…ing (zed-industries#51973) The line wrapper's `is_word_char` function included the ASCII apostrophe (U+0027) but not the typographic right single quotation mark `'` (U+2019) or left single quotation mark `'` (U+2018). When Markdown rendering produces curly quotes, words like `won't` were being split at the apostrophe during line wrapping, producing `won` at the end of one line and `'t` at the start of the next. This adds both typographic quote characters to `is_word_char` so they are treated the same as the ASCII apostrophe. Release Notes: - Fixed line wrapping splitting words at typographic apostrophes (e.g. "won't" breaking as "won" / "'t").
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The line wrapper's
is_word_charfunction included the ASCII apostrophe (U+0027) but not the typographic right single quotation mark'(U+2019) or left single quotation mark'(U+2018). When Markdown rendering produces curly quotes, words likewon'twere being split at the apostrophe during line wrapping, producingwonat the end of one line and'tat the start of the next.This adds both typographic quote characters to
is_word_charso they are treated the same as the ASCII apostrophe.Release Notes: