parallax/jsPDF

TextField fontsize changes after editing content

Open

#3.071 geöffnet am 21. Jan. 2021

Auf GitHub ansehen
 (13 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)JavaScript (4.596 Forks)batch import
Improvementhelp wantedpersistent

Repository-Metriken

Stars
 (28.280 Stars)
PR-Merge-Metriken
 (Keine gemergten PRs in 30 T)

Beschreibung

Feature requests, bug reports etc. are very welcome as issues. But questions are directed to stackoverflow with the tag jspdf.

If you are facing issues with utf-8 characters, please refer to #2677.

Note that bug reports should follow these guidelines:

  1. A bug should be reported as an mcve
  2. Make sure code is properly indented and formatted (Use ``` around code blocks)
  3. You can run example here http://raw.githack.com/MrRio/jsPDF/master/ for AcroForms and download pdf and check the font size on chrome browser Initial font size for input value is ok when we chnge text it appear larger
/* global jsPDF */
var doc = new jsPDF();
var {
  TextField,
  Appearance
} = jsPDF.AcroForm;

doc.setFontSize(12);

doc.text("TextField:", 10, 145);
var textField = new TextField();
textField.Rect = [50, 140, 30, 10];
textField.multiline = false;
textField.value ="Test value"; //
textField.fieldName = "TestTextBox";
doc.addField(textField);

  1. Please check ath attached Pdf and open it in chrome browser it show larger text inside input fields. AcroForms (2).pdf

Contributor Guide