Browse Source

Refactor: enhance document structure debugging with semantic document pointer

Marcin Ziąbek 3 months ago
parent
commit
ee107b1464
2 changed files with 3 additions and 2 deletions
  1. 3 1
      Source/QuestPDF/Drawing/DocumentContainer.cs
  2. 0 1
      Source/QuestPDF/Elements/Page.cs

+ 3 - 1
Source/QuestPDF/Drawing/DocumentContainer.cs

@@ -22,7 +22,9 @@ namespace QuestPDF.Drawing
                 if (Pages.Count == 0)
                     return;
 
-                container = container.DebugPointer(DebugPointerType.DocumentStructure, DocumentStructureTypes.Document.ToString());
+                container = container
+                    .DebugPointer(DebugPointerType.DocumentStructure, DocumentStructureTypes.Document.ToString())
+                    .SemanticDocument();
                 
                 if (Pages.Count == 1)
                 {

+ 0 - 1
Source/QuestPDF/Elements/Page.cs

@@ -31,7 +31,6 @@ namespace QuestPDF.Elements
         {
             container
                 .DebugPointer(DebugPointerType.DocumentStructure, DocumentStructureTypes.Page.ToString())
-                .SemanticDocument()
                 .ContentDirection(ContentDirection)
                 .DefaultTextStyle(DefaultTextStyle.DisableFontFeature(FontFeatures.StandardLigatures))
                 .Layers(layers =>