Example #1
0
 /// <summary>
 /// Copies from other settings.
 /// </summary>
 /// <param name="settings">The settings</param>
 internal void CopyFrom(PdfExportSettings settings)
 {
     if (settings != null)
     {
         this.author          = settings.author;
         this.title           = settings.title;
         this.subject         = settings.subject;
         this.keywords        = settings.keywords;
         this.creator         = settings.creator;
         this.centerWindow    = settings.centerWindow;
         this.displayDocTitle = settings.displayDocTitle;
         this.hideMenubar     = settings.hideMenubar;
         this.hideToolbar     = settings.hideToolbar;
         this.hideWindowUI    = settings.hideWindowUI;
         this.fitWindow       = settings.fitWindow;
         this.pageLayout      = settings.pageLayout;
         this.openType        = settings.openType;
         this.pageDuration    = settings.pageDuration;
         this.pageTransition  = settings.pageTransition;
         this.destinationType = settings.destinationType;
         this.openPageNumber  = settings.openPageNumber;
         this.printPreset.CopyFrom(settings.printPreset);
         this.documentAttachments.AddRange((IEnumerable <DocumentAttachment>)settings.documentAttachments);
     }
 }
 /// <summary>
 /// <inheritdoc/>
 /// </summary>
 public IPageLayoutAdapter this[PageLayoutType type]
 {
     get
     {
         return(_pageLayoutAdapters.FirstOrDefault(adapter => adapter.LayoutType == type));
     }
 }
Example #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="BasePageLayout"/> class.
 /// </summary>
 /// <param name="pageComponent"><see cref="PDFPageComponent"/> used to obtain information.</param>
 /// <param name="layoutType">Type of supported layout.</param>
 internal BasePageLayout(PDFPageComponent pageComponent, PageLayoutType layoutType)
 {
     PageComponent = pageComponent ?? throw new ArgumentNullException(nameof(pageComponent));
     LayoutType    = layoutType;
 }