GemBox.Pdf
  • Overview
  • Examples
  • Free version
  • Support
  • Pricelist

    Show / Hide Table of Contents

    PdfPageObject Class

    Namespace:
    GemBox.Pdf
    Assembly:
    GemBox.Pdf.dll

    Represents a base class for page tree nodes: intermediate nodes, called page tree nodes represented with PdfPages type, and leaf nodes, called page objects represented with PdfPage type.

    • C#
    • VB.NET
    public abstract class PdfPageObject : PdfObject
    Public MustInherit Class PdfPageObject
        Inherits PdfObject
    Inheritance:
    System.Object
    PdfObject
    PdfPageObject
    Derived
    PdfPage
    PdfPages

    Properties

    CropBox

    (Optional; inheritable) A rectangle, expressed in default user space units, that shall define the visible region of default user space.

    When the page is displayed or printed, its contents shall be clipped (cropped) to this rectangle and then shall be imposed on the output medium in some implementation-defined manner (see 14.11.2, "Page Boundaries").

    Default value: the value of MediaBox.

    Value of this property might be null if this is an instance of a PdfPages, but it should never be null if this is an instance of a PdfPage.

    • C#
    • VB.NET
    public PdfRectangle CropBox { get; set; }
    Public Property CropBox As PdfRectangle
    Property Value
    PdfRectangle

    A rectangle, expressed in default user space units, that shall define the visible region of default user space.

    See Also
    PDF Specification ISO 32000-1:2008, section '7.7.3.3 Page Objects'

    MediaBox

    (Required; inheritable) A rectangle (see 7.9.5, "Rectangles"), expressed in default user space units, that shall define the boundaries of the physical medium on which the page shall be displayed or printed (see 14.11.2, "Page Boundaries").

    Value of this property might be null if this is an instance of a PdfPages, but it should never be null if this is an instance of a PdfPage.

    • C#
    • VB.NET
    public PdfRectangle MediaBox { get; set; }
    Public Property MediaBox As PdfRectangle
    Property Value
    PdfRectangle

    A rectangle, expressed in default user space units, that shall define the boundaries of the physical medium on which the page shall be displayed or printed.

    See Also
    PDF Specification ISO 32000-1:2008, section '7.7.3.3 Page Objects'

    Parent

    (Required except in root node; prohibited in the root node; shall be an indirect reference) The page tree node that is the immediate parent of this one.

    • C#
    • VB.NET
    public PdfPages Parent { get; }
    Public ReadOnly Property Parent As PdfPages
    Property Value
    PdfPages

    The page tree node that is the immediate parent of this one.

    See Also
    PDF Specification ISO 32000-1:2008, section '7.7.3.2 Page Tree Nodes'

    Rotate

    (Optional; inheritable) The number of degrees by which the page shall be rotated clockwise when displayed or printed.

    The value shall be a multiple of 90.

    Default value: 0.

    • C#
    • VB.NET
    public int Rotate { get; set; }
    Public Property Rotate As Integer
    Property Value
    System.Int32

    The number of degrees by which the page shall be rotated clockwise when displayed or printed.

    See Also
    PDF Specification ISO 32000-1:2008, section '7.7.3.3 Page Objects'

    Methods

    SetCropBox(Double, Double)

    Sets the CropBox.

    • C#
    • VB.NET
    public void SetCropBox(double width, double height)
    Public Sub SetCropBox(width As Double, height As Double)
    Parameters
    width
    System.Double

    The right X coordinate of the CropBox. The left X coordinate of the CropBox is set to 0.

    height
    System.Double

    The top Y coordinate of the CropBox. The bottom Y coordinate of the CropBox is set to 0.

    SetCropBox(Double, Double, Double, Double)

    Sets the CropBox.

    • C#
    • VB.NET
    public void SetCropBox(double left, double bottom, double right, double top)
    Public Sub SetCropBox(left As Double, bottom As Double, right As Double, top As Double)
    Parameters
    left
    System.Double

    The left X coordinate of the CropBox.

    bottom
    System.Double

    The bottom Y coordinate of the CropBox.

    right
    System.Double

    The right X coordinate of the CropBox.

    top
    System.Double

    The top Y coordinate of the CropBox.

    SetMediaBox(Double, Double)

    Sets the MediaBox.

    • C#
    • VB.NET
    public void SetMediaBox(double width, double height)
    Public Sub SetMediaBox(width As Double, height As Double)
    Parameters
    width
    System.Double

    The right X coordinate of the MediaBox. The left X coordinate of the MediaBox is set to 0.

    height
    System.Double

    The top Y coordinate of the MediaBox. The bottom Y coordinate of the MediaBox is set to 0.

    SetMediaBox(Double, Double, Double, Double)

    Sets the MediaBox.

    • C#
    • VB.NET
    public void SetMediaBox(double left, double bottom, double right, double top)
    Public Sub SetMediaBox(left As Double, bottom As Double, right As Double, top As Double)
    Parameters
    left
    System.Double

    The left X coordinate of the MediaBox.

    bottom
    System.Double

    The bottom Y coordinate of the MediaBox.

    right
    System.Double

    The right X coordinate of the MediaBox.

    top
    System.Double

    The top Y coordinate of the MediaBox.

    Inherited Properties

    Metadata

    (Optional; PDF 1.4) A metadata stream containing metadata for the component.

    (Inherited from PdfObject)

    Extension Methods

    PdfObjectExtensions.GetDictionary(PdfObject)
    PdfObjectExtensions.GetOrAddDictionary(PdfObject)
    PdfObjectExtensions.GetArray(PdfObject)

    Examples

    Page Tree example

    See Also

    PDF Specification ISO 32000-1:2008, section '7.7.3 Page Tree'
    Back to top

    Facebook • Twitter • LinkedIn

    © GemBox Ltd. — All rights reserved.