Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Copying text will add more space

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

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

評価

難易度
4/5
見積もり時間
3〜5日
初心者へのやさしさ
35/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
java
領域
backend

調査の方向性

Start by reproducing the copied-text spacing with the reported BaseFont and PdfContentByte.showTextAligned calls in OpenPDF 1.4.2. The issue does not identify a source file or test, so trace how positioned text is encoded for copying and add a regression test for the reported characters. Done means copied text has no extra spaces; the issue has had no comments for 638 days.

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

説明

bug
Describe the bug

After adding the word according to the coordinate of the word, there will be an extra space after some words are copied.

To Reproduce

Code to reproduce the issue

Some core code:
BaseFont baseFont = BaseFont.createFont(curFontPath, BaseFont.IDENTITY_V, BaseFont.EMBEDDED);
PdfContentByte cb = writer.getDirectContentUnder();
cb.beginText();
cb.setFontAndSize(baseFont, fontHeight);
cb.setGState(gState);
cb.showTextAligned(PdfContentByte.ALIGN_LEFT, txt, x, y, 0);
cb.endText();

Expected behavior

We want the copied word to have no Spaces

Screenshots

image
郝𭣣 忠𫠡 陵

System
  • Used font:Inconvenient to provide
  • OpenPDF version:1.4.2
主要言語
Java
スター
4.4k
フォーク
714
PR マージ指標
30日以内にマージされた PR はありません

環境構築

はじめの一歩

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

LibrePDF/OpenPDF のほかの issue

LibrePDF/OpenPDF の issue をすべて見る

似ている issue

Java の issue をもっと見る

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

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