Ejemplo n.º 1
0
        private ManagedXpsDocument GetNewManagedXpsDocument(ReportContentDefinition xpsHeaderAndFooterDefinition)
        {
            Uri     packageUri = GetNewIndexedPackageUri();
            Package package    = GetNewPackageAt(packageUri);

            return(new ManagedXpsDocument(packageUri, package, xpsHeaderAndFooterDefinition, this._reportProperties));
        }
Ejemplo n.º 2
0
        private ManagedXpsDocument CreateManagedXpsDocumentFrom(ManagedFlowDocument managedFlowDocument)
        {
            ReportContentDefinition xpsHeaderAndFooterDefinition = GetXpsHeaderAndFooterDefinitionWith(managedFlowDocument.DataContext);
            ManagedXpsDocument      managedXpsDocument           = GetNewManagedXpsDocument(xpsHeaderAndFooterDefinition);

            managedXpsDocument.CreateContentFromFlowDocument(managedFlowDocument);
            return(managedXpsDocument);
        }
Ejemplo n.º 3
0
 public ManagedXpsDocument(Uri packageUri, Package package, ReportContentDefinition xpsHeaderAndFooterDefinition, ReportProperties reportProperties)
     : base(package, CompressionOption.SuperFast, packageUri.ToString())
 {
     this.PackageUri = packageUri;
     RegisterAtPackageStoreWith(package, packageUri);
     this._xpsHeaderAndFooterDefinition = xpsHeaderAndFooterDefinition;
     this._reportProperties             = reportProperties;
 }
Ejemplo n.º 4
0
 public void AddFooterAndHeader(ReportContentDefinition xpsHeaderAndFooterDefinition)
 {
     this.AddVisualAtTopOfPage(xpsHeaderAndFooterDefinition.HeaderVisual);
     this.AddVisualAt(xpsHeaderAndFooterDefinition.FooterOffsetY, xpsHeaderAndFooterDefinition.FooterVisual);
 }