Browse Source

Updated release notes and code example

Marcin Ziąbek 4 years ago
parent
commit
7f94ae589a
3 changed files with 10 additions and 18 deletions
  1. 0 11
      QuestPDF.ReportSample/Layouts/StandardReport.cs
  2. 2 2
      QuestPDF/QuestPDF.csproj
  3. 8 5
      readme.md

+ 0 - 11
QuestPDF.ReportSample/Layouts/StandardReport.cs

@@ -25,17 +25,6 @@ namespace QuestPDF.ReportSample.Layouts
         public void Compose(IDocumentContainer container)
         public void Compose(IDocumentContainer container)
         {
         {
             container
             container
-                // .Page(page =>
-                // {
-                //     page.MarginVertical(40);
-                //     page.MarginHorizontal(50);
-                //     
-                //     page.ContinuousSize(PageSizes.A4.Width);
-                //         
-                //     page.Header().Element(ComposeHeader);
-                //     page.Content().Element(ComposeContent);
-                //     page.Footer().AlignCenter().PageNumber("Page A {number}");
-                // })
                 .Page(page =>
                 .Page(page =>
                 {
                 {
                     page.MarginVertical(40);
                     page.MarginVertical(40);

+ 2 - 2
QuestPDF/QuestPDF.csproj

@@ -4,9 +4,9 @@
         <Authors>MarcinZiabek</Authors>
         <Authors>MarcinZiabek</Authors>
         <Company>CodeFlint</Company>
         <Company>CodeFlint</Company>
         <PackageId>QuestPDF</PackageId>
         <PackageId>QuestPDF</PackageId>
-        <Version>2021.5.2</Version>
+        <Version>2021.8</Version>
         <PackageDescription>QuestPDF is an open-source, modern and battle-tested library that can help you with generating PDF documents by offering friendly, discoverable and predictable C# fluent API.</PackageDescription>
         <PackageDescription>QuestPDF is an open-source, modern and battle-tested library that can help you with generating PDF documents by offering friendly, discoverable and predictable C# fluent API.</PackageDescription>
-        <PackageReleaseNotes>New elements: Box, Grid, Canvas, EnsureSpance and Layers. Redesigned the Debug element. Added material design colors. Added list of basic fonts. Added spacing property to the Row element. Fluent API improvements and increased stability.</PackageReleaseNotes>
+        <PackageReleaseNotes>New elements: Unconstrained, Scale, ScaleHorizontal, ScaleVertical, FlipOver, FlipHorizontal, FlipVertical, Rotate, RotateLeft, RotateRight, TranslateX, TranslateY. Added support for more placeholders in the PageNumber element (current page, total number of pages, page number of any predefined location). Added support for documents with various page sizes. Various API improvements.</PackageReleaseNotes>
         <LangVersion>8</LangVersion>
         <LangVersion>8</LangVersion>
         <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
         <GeneratePackageOnBuild>true</GeneratePackageOnBuild>
         <PackageIcon>Logo.png</PackageIcon>
         <PackageIcon>Logo.png</PackageIcon>

+ 8 - 5
readme.md

@@ -54,16 +54,19 @@ For tutorial, documentation and API reference, please visit [the QuestPDF docume
 Here you can find an example code showing how easy is to write and understand the fluent API:
 Here you can find an example code showing how easy is to write and understand the fluent API:
 
 
 ```csharp
 ```csharp
-public void Compose(IContainer container)
-{
+public void Compose(IDocumentContainer container)
+{               
     container
     container
-        .PaddingHorizontal(50)
-        .PaddingVertical(50)
         .Page(page =>
         .Page(page =>
         {
         {
+            page.MarginVertical(60);
+            page.MarginHorizontal(40);
+            
+            page.Size(PageSizes.A4);
+                
             page.Header().Element(ComposeHeader);
             page.Header().Element(ComposeHeader);
             page.Content().Element(ComposeContent);
             page.Content().Element(ComposeContent);
-            page.Footer().AlignCenter().PageNumber("Page {number}");
+            page.Footer().AlignCenter().PageNumber();
         });
         });
 }
 }