Fix(#499): inconsistent text height when using multiple lines

This commit is contained in:
MarcinZiabek
2023-04-16 11:42:38 +02:00
parent e6c7befac4
commit 6ad465b9fa
2 changed files with 43 additions and 1 deletions
+30
View File
@@ -974,5 +974,35 @@ namespace QuestPDF.Examples
});
});
}
[Test]
public void InconsistentLineHeightWhenUsingNewLineTest()
{
RenderingTest
.Create()
.PageSize(PageSizes.A4)
.ProduceImages()
.ShowResults()
.Render(container =>
{
container
.Padding(20)
.Background(Colors.Grey.Lighten4)
.Text(text =>
{
text.DefaultTextStyle(x => x.FontSize(16));
text.Line(Placeholders.Paragraph());
text.Line("");
text.Line(Placeholders.Paragraph());
text.Line(Placeholders.Label()).FontSize(48);
text.Line(Placeholders.Paragraph());
text.Line("");
text.Line(Placeholders.Paragraph());
});
});
}
}
}