processing / processing/processing4
Incorrect calculation of the text width in the P2D renderer
オープン
まだ誰も着手していません。
bug
- 主要言語
- Java
- スター
- 494
- フォーク
- 183
- 平均マージ
- 4時間 39分
- マージ済み PR(30日)
- 3
説明
Most appropriate sub-area of Processing 4?
Core/Environment/Rendering
Processing version
4.3.4
Operating system
Windows 7
Bug description
Significant errors in calculating the width of text using the textWidth(String) method in P2D mode in the Eclipse environment
Steps to reproduce this
To reproduce the error, you need to run the code that I specified here in the Eclipse environment.
void settings() {
size(720,360,P2D);
}
void setup() {
stroke(0);
textSize(24);
final String str = "WWWtttt".repeat(100);
final float textWidth = textWidth(str);
text(str, 100 - textWidth, 200);
stroke(255, 0, 0);
line(100 - textWidth, 200, 100, 200);
noLoop();
}
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、報告された環境で提供された Processing スケッチを P2D モードで実行し、textWidth の結果をレンダリングされたテキストおよび参照行と比較します。次に、P2D レンダラーのテキスト幅計算を追跡します。textWidth(String) が繰り返された文字列を正確に測定し、再現結果に大きな位置合わせの誤差が見られなくなれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- computer-graphics
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 45/100