Closed
Description
Currently lineHeightFactor is ignored, if it is specified as text option.
It correctly checked for calculating lineHeight variable.
But this variable is not used for calculating descent value (still used global lineHeightFactor from document).
As result, those two options produces the different PDF files
Steps to reproduce:
- Open the sample https://codepen.io/SNovikov/pen/VwbJOzG?editors=0010
- Export PDF with specified document option
doc.setLineHeightFactor(1.5);
doc.text('Some text', 10, 10, { baseline: 'middle' });
- Export PDF with specified text option
doc.text('Some text', 10, 10, { lineHeightFactor: 1.5, baseline: 'middle' });