Class PdfPageTransition
Represents parameters how to display the page in the presentation mode.
Inheritance
Implements
Namespace: Syncfusion.Pdf
Assembly: Syncfusion.Pdf.NET.dll
Syntax
public class PdfPageTransition : Object, IPdfWrapper, ICloneable
Examples
//Create a new document
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
doc.Save("output.pdf");
doc.Close(true);
'Create a new document
Dim doc As New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition
Dim transition As New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
doc.PageSettings.Transition = transition
'Create a new page
Dim page As PdfPage = doc.Pages.Add()
doc.Save("output.pdf")
doc.Close(True)
Constructors
PdfPageTransition()
Initializes a new instance of the PdfPageTransition class.
Declaration
public PdfPageTransition()
Examples
//Create a new document.
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition.
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
//Set page transition.
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
//Save and close the document.
doc.Save("output.pdf");
doc.Close(true);
'Create a new document.
Dim doc As PdfDocument = New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition.
Dim transition As PdfPageTransition = New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
'Set page transition.
doc.PageSettings.Transition = transition
Dim page As PdfPage = doc.Pages.Add()
'Save and close the document.
doc.Save("output.pdf")
doc.Close(True)
See Also
Properties
Dimension
Gets or sets the dimension in which the specified transition effect occurs.
Declaration
public PdfTransitionDimension Dimension { get; set; }
Property Value
Type | Description |
---|---|
PdfTransitionDimension | The PdfTransitionDimension handles the dimensions . |
Examples
//Create a new document.
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition.
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
//Set page transition.
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
//Save and close the document.
doc.Save("output.pdf");
doc.Close(true);
'Create a new document.
Dim doc As PdfDocument = New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition.
Dim transition As PdfPageTransition = New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
'Set page transition.
doc.PageSettings.Transition = transition
Dim page As PdfPage = doc.Pages.Add()
'Save and close the document.
doc.Save("output.pdf")
doc.Close(True)
See Also
Direction
The direction in which the specified transition effect moves, expressed in degrees counter clockwise starting from a left-to-right direction. (This differs from the page object�s Rotate property, which is measured clockwise from the top.)
Declaration
public PdfTransitionDirection Direction { get; set; }
Property Value
Type | Description |
---|---|
PdfTransitionDirection | The PdfTransitionDirection handles the various directions |
Examples
//Create a new document.
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition.
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
//Set page transition.
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
//Save and close the document.
doc.Save("output.pdf");
doc.Close(true);
'Create a new document.
Dim doc As PdfDocument = New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition.
Dim transition As PdfPageTransition = New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
'Set page transition.
doc.PageSettings.Transition = transition
Dim page As PdfPage = doc.Pages.Add()
'Save and close the document.
doc.Save("output.pdf")
doc.Close(True)
See Also
Duration
Gets or sets the duration of the transition effect, in seconds.
Declaration
public float Duration { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The transition duration. |
Motion
Gets or sets the the direction of motion for the specified transition effect.
Declaration
public PdfTransitionMotion Motion { get; set; }
Property Value
Type | Description |
---|---|
PdfTransitionMotion | The PdfTransitionMotion handles the various transition motions |
Examples
//Create a new document.
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition.
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
//Set page transition.
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
//Save and close the document.
doc.Save("output.pdf");
doc.Close(true);
'Create a new document.
Dim doc As PdfDocument = New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition.
Dim transition As PdfPageTransition = New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
'Set page transition.
doc.PageSettings.Transition = transition
Dim page As PdfPage = doc.Pages.Add()
'Save and close the document.
doc.Save("output.pdf")
doc.Close(True)
See Also
PageDuration
Gets or sets The page�s display duration (also called its advance timing): the maximum length of time, in seconds, that the page is displayed during presentations before the viewer application automatically advances to the next page. By default, the viewer does not advance automatically.
Declaration
public float PageDuration { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The page duration. |
Examples
//Create a new document.
PdfDocument doc = new PdfDocument();
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen;
//create a page transition.
PdfPageTransition transition = new PdfPageTransition();
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight;
transition.Dimension = PdfTransitionDimension.Vertical;
transition.Motion = PdfTransitionMotion.Outward;
transition.PageDuration = 3;
//Set page transition.
doc.PageSettings.Transition = transition;
//Create a new page
PdfPage page = doc.Pages.Add();
//Save and close the document.
doc.Save("output.pdf");
doc.Close(true);
'Create a new document.
Dim doc As PdfDocument = New PdfDocument()
doc.ViewerPreferences.PageMode = PdfPageMode.FullScreen
'create a page transition.
Dim transition As PdfPageTransition = New PdfPageTransition()
transition.Direction = PdfTransitionDirection.TopLeftToBottomRight
transition.Dimension = PdfTransitionDimension.Vertical
transition.Motion = PdfTransitionMotion.Outward
transition.PageDuration = 3
'Set page transition.
doc.PageSettings.Transition = transition
Dim page As PdfPage = doc.Pages.Add()
'Save and close the document.
doc.Save("output.pdf")
doc.Close(True)
See Also
Scale
Gets or sets the starting or ending scale at which the changes are drawn. If Motion property specifies an inward transition, the scale of the changes drawn progresses from Scale to 1.0 over the course of the transition. If Motion specifies an outward transition, the scale of the changes drawn progresses from 1.0 to Scale over the course of the transition.
Declaration
public float Scale { get; set; }
Property Value
Type | Description |
---|---|
System.Single | The scale. |
Remarks
This property has effect for Fly transition style only.
Style
Gets or sets the transition style to use when moving to this page from another during a presentation.
Declaration
public PdfTransitionStyle Style { get; set; }
Property Value
Type | Description |
---|---|
PdfTransitionStyle | The PdfTransitionStyle, handles the various transition styles |
Methods
Clone()
Creates a new object that is a copy of the current instance.
Declaration
public object Clone()
Returns
Type | Description |
---|---|
System.Object | A new object that is a copy of this instance. |