PdfSaveOptions.TextCompression

PdfSaveOptions.TextCompression property

Gets or sets a compression type to be used for all content streams except images. Default is Flate.

public PdfTextCompression TextCompression { get; set; }

Examples

Shows how to set a compression type to be used for all content streams except images.

var project = new Project(DataDir + "EstimatedMilestoneTasks.mpp");

var options = new PdfSaveOptions();

// set compression type to be used for all content streams except images
options.TextCompression = PdfTextCompression.Flate;

// tune additional properties
// set the <see cref="P:Aspose.Tasks.Saving.SaveOptions.PresentationFormat" /> in which the document will be saved.
options.PresentationFormat = PresentationFormat.GanttChart;

// set a desired conformance level for generated PDF document
options.Compliance = PdfCompliance.PdfA1b;

project.Save(OutDir + "WorkWithTextCompression_out.pdf", options);

See Also