tonsky / tonsky/FiraCode

Zero-width non-joiner behaves incorrectly with some ligatures

オープン
#1,663 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

主要言語
Clojure
スター
82k
フォーク
3.2k
PR マージ指標
30日以内にマージされた PR はありません

説明

Hiya,

I really don't know much about fonts and font development in general, so please feel free to close this issue if the described behavior is intended or likely caused by something else :)

I noticed some weird behavior with U+200C (Zero-width non-joiner). To my understanding, inserting this character should prevent the surrounding characters from forming a ligature together. In Fira Code, this behavior can be seen with the != ligature:

  • the sequence != displays as a ligature
  • the sequence !\U200C= does not display as a ligature

However, for some ligatures, this does not work. The following sequences seem to consistently render as ligatures, even though they shouldn't:

  • -\U200C> renders the -> ligature
  • ~\U200C> renders the ~> ligature
  • -\U200C- renders the -- ligature

And likely more. All of this was tested both in Kitty and in IntelliJ IDEA, with Fira Code 6.2.

Even more weirdly, when disabling ligatures (at least in IntelliJ, in Kitty disabling ligatures seems to just disable ligature rendering alltogether as U+200D doesn't even do anything anymore) the insertion of U+200C seems to force these ligatures to be rendered even if they otherwise wouldn't be, behaving the same as U+200D!

I tested this in the software that was available to me, if there's a more direct way to reproduce this without potentially being biased by application-specific ligature rendering weirdness do let me know. Again, I know very little about font developent.

Thank you! :)

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

調査の方向性

Fira Code 6.2をKittyまたはIntelliJ IDEAで使用して報告されたシーケンスを再現し、リガチャを有効にした場合と無効にした場合でU+200CとU+200Dを比較する。挙動がフォントに起因するのか、レンダリングアプリケーションに起因するのかを特定する。影響を受けるシーケンスが期待されるゼロ幅非接合子の挙動に一貫して従い、直接的な再現手順が文書化されていれば完了とする。

索引モデルが issue の本文から書いたものです。

評価

領域
design
issue の種類
バグ
難易度
4/5
見積もり時間
3〜5日
活発さ
停滞
明瞭さ
説明が足りない
初心者へのやさしさ
28/100

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。