From 44bd646babd6b216b74dcbd4cc403fd00046d3e5 Mon Sep 17 00:00:00 2001 From: knoxyz <30576590+knoxyz@users.noreply.github.com> Date: Fri, 29 Apr 2022 11:36:28 +0200 Subject: [PATCH] Replaced the obsolete methods from 2022.3 (InternalLink and Color) --- QuestPDF.ReportSample/Layouts/TableOfContentsTemplate.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/QuestPDF.ReportSample/Layouts/TableOfContentsTemplate.cs b/QuestPDF.ReportSample/Layouts/TableOfContentsTemplate.cs index 8788edd..0eba5d0 100644 --- a/QuestPDF.ReportSample/Layouts/TableOfContentsTemplate.cs +++ b/QuestPDF.ReportSample/Layouts/TableOfContentsTemplate.cs @@ -41,7 +41,7 @@ namespace QuestPDF.ReportSample.Layouts private void DrawLink(IContainer container, int number, string locationName) { container - .InternalLink(locationName) + .SectionLink(locationName) .Row(row => { row.ConstantItem(25).Text($"{number}."); @@ -52,7 +52,7 @@ namespace QuestPDF.ReportSample.Layouts text.Span(" - "); text.EndPageNumberOfSection(locationName); - var lengthStyle = TextStyle.Default.Color(Colors.Grey.Medium); + var lengthStyle = TextStyle.Default.FontColor(Colors.Grey.Medium); text.Span(" (").Style(lengthStyle); text.TotalPagesWithinSection(locationName).Style(lengthStyle).Format(x => x == 1 ? "1 page long" : $"{x} pages long"); @@ -61,4 +61,4 @@ namespace QuestPDF.ReportSample.Layouts }); } } -} \ No newline at end of file +}