Browse Source

Improved debug pointers

MarcinZiabek 3 years ago
parent
commit
559de4520a
2 changed files with 4 additions and 2 deletions
  1. 2 1
      QuestPDF/Drawing/DocumentContainer.cs
  2. 2 1
      QuestPDF/Elements/Page.cs

+ 2 - 1
QuestPDF/Drawing/DocumentContainer.cs

@@ -16,13 +16,14 @@ namespace QuestPDF.Drawing
             var container = new Container();
             
             container
+                .DebugPointer("Document")
                 .Column(column =>
                 {
                     Pages
                         .SelectMany(x => new List<Action>()
                         {
                             () => column.Item().PageBreak(),
-                            () => column.Item().Component(x)
+                            () => column.Item().DebugPointer("Page").Component(x)
                         })
                         .Skip(1)
                         .ToList()

+ 2 - 1
QuestPDF/Elements/Page.cs

@@ -42,6 +42,7 @@ namespace QuestPDF.Elements
                     
                     layers
                         .PrimaryLayer()
+                        .DebugPointer("Page primary layer")
                         .MinWidth(MinSize.Width)
                         .MinHeight(MinSize.Height)
                 
@@ -64,9 +65,9 @@ namespace QuestPDF.Elements
 
                             decoration
                                 .Content()
+                                .DebugPointer("Page content")
                                 .Element(x => IsClose(MinSize.Width, MaxSize.Width) ? x.ExtendHorizontal() : x)
                                 .Element(x => IsClose(MinSize.Height, MaxSize.Height) ? x.ExtendVertical() : x)
-                                .DebugPointer("Page content")
                                 .Element(Content);
 
                             decoration