Matte color is used for preblending images with some background color, using the SMask. Matte color is specified using the optional 'Matte' entry for the SMask object. See PDF 1.7 specification, page 554-555: Matte array (Optional; PDF 1.4) An array of component values specifying the matte color with which the image data in the parent image has been preblended. The array consists of nnumbers, where n is the number of components in the color space specified by the ColorSpace entry in the parent image’s image dictionary; the numbers must be valid color components in that color space. If this entry is absent, the image data is not preblended.
The public API may be implemented as property of PdfExportSettings. Implementing this feature would help to easily workaround issue with PdfProcessing documents that cannot be opened on devices with iOS version 10.2 (due to the default FlateDecode compression).
For example, when some PDF file has uncompressed contents we may import it and apply better compression to the stream objects. Ensure that all the content inside the document is compressed.
Currently, we have the following options for PDF export optimizations:
pdfFormatProvider.ExportSettings.ImageQuality = ImageQuality.Low;
pdfFormatProvider.ExportSettings.ImageCompression = new ImageFilterTypes[] { ImageFilterTypes.FlateDecode };
pdfFormatProvider.ExportSettings.StreamCompression = new StreamFilterTypes[] { StreamFilterTypes.FlateDecode };
pdfFormatProvider.ExportSettings.FontEmbeddingType = FontEmbeddingType.Subset;
This is happening when the pages in the document has content arrays similar to the following: [34 0 R 243 0 R] [34 0 R 245 0 R] [34 0 R 247 0 R] .... As you may notice the content stream 34 0 R is reused and the issue is caused by incorrect caching of content stream indirect objects by their reference.
Currently this exception crashes the whole PDF document import. Instead we should simply skip the unsupported Action and import the rest of the PDF content correctly.
These images are defined directly in the PDF page content stream with BI and EI operators. Currently InvalidCastException is thrown when document with such images is imported. Available in R1 2018 SP2 release version.
For example exporting the text "\uD83D\uDE0A" with "Segoe UI Symbol" font family should export a single smiling face. Instead the characters are skipped during the export as PdfProcessing is trying to export them as separate char values ("\uD83D" and "\uDE0A") and the font does not contain glyphs corresponding to these char codes.
When creating a GradientStop, an alpha channel of the color could be applied. However, this setting is not respected it the result document and the gradient is with full opacity. Steps to reproduce: 1. Create a gradient with an alpha channel: RadFixedDocument document = new RadFixedDocument(); RadFixedPage page = document.Pages.AddPage(); FixedContentEditor containerEditor = new FixedContentEditor(page); LinearGradient linearGradient = new LinearGradient(new Point(0, 0), new Point(30, 30)); linearGradient.GradientStops.Add(new GradientStop(new RgbColor(10, 0, 207, 0), 0)); linearGradient.GradientStops.Add(new GradientStop(new RgbColor(10, 0, 102, 204), 1)); containerEditor.GraphicProperties.FillColor = linearGradient; containerEditor.DrawRectangle(new Rect(10, 10, 48, 29)); 2. Export the document to PDF Observed: The alpha channel is not respected and the gradient is with full opacity
This would allow to encrypt documents only with Owner Password and not showing password dialog when disabling some PDF features permissions. The customer should be able to disable printing, text and graphic selection and extraction, page rotations and others. The full specification of all permission bits may be seen in Table 3.20 on page 124 in PdfReference 1.7. On page 120 in PdfReference 1.7 are described the User and Owner passwords.
PDF Editor: the pdfiewer will now have a feature to perform the following: Sort pages by dragging and dropping selected pages. After adding stamps/annotations on the page, user will be able to move around those objects by dragging and dropping.
Possibility to convert a PDF file to EPS file.
This new API will not read/delete the existing PDF pages content and this would allow performance and memory efficient realization of the following scenarios: - Merge PDF document pages from different PDF files. - Split PDF document pages to separate PDF files. - Append/Prepend PDF content to existing PDF pages. Moreover, as this approach will not require reading/deleting existing PDF page content, it will not depend on complex PDF features and will depend only on the PDF file structure. This will allow processing of PDF documents which use less common PDF features which are currently not supported by the existing PdfProcessing API. Available in R1 2017 Release
When characters are in the ranges 61472-61566, 61565-61695, 65535-65535 they are correctly exported with Wingdings font. However, when the character value is outside these ranges the font fallback mechanism exports them with different font and this causes wrong glyph rendering in the resulted PDF.
The following code snippet shows how the Wingdings characters can be modified so that they are correctly exported to PDF when converting from WordsProcessing's RadFlowDocument:
RadFlowDocument document = new DocxFormatProvider().Import(File.ReadAllBytes(@"test_document.docx"));
foreach (Run run in document.EnumerateChildrenOfType<Run>())
{
if (run.FontFamily.GetActualValue(document.Theme).Source.Contains("Wingdings"))
{
StringBuilder modifiedText = new StringBuilder();
foreach (char character in run.Text)
{
modifiedText.Append(character > 256 ? character : (char)(character + 61440));
}
run.Text = modifiedText.ToString();
}
}
Workaround: When creating a RadFixedDocument:
using (RadFixedDocumentEditor editor = new RadFixedDocumentEditor(this.fixedDocument))
{
byte[] data = File.ReadAllBytes(@"CustomFont.ttf");
FontsRepository.RegisterFont(new FontFamily("CustomFont"), FontStyles.Normal, FontWeights.Normal, data);
FontBase customFont;
FontsRepository.TryCreateFont(new FontFamily("CustomFont"), FontStyles.Normal, FontWeights.Normal, out customFont);
editor.CharacterProperties.Font = customFont;
string text = "w";
StringBuilder modifiedText = new StringBuilder();
foreach (char character in text)
{
modifiedText.Append(character > 256 ? character : (char)(character + 61440));
}
text = modifiedText.ToString();
editor.InsertRun(text);
}
Currently, for .NET Framework scenarios, this could be achieved using RadPdfViewer's WPF control ThumbnailFactory class. Sample code may be seen at this forum post: http://www.telerik.com/forums/pdf-thumbnail-returns-transparent-images#jO33X-E8Cki_qLh_KsToWg.
The feature should be implemented for .NET Standard as well.
The method should create deep copy of the current page.
The NotImplementedException is thrown while getting the color from unsupported color space (for example ICC). This exception occurs during the import of shading patterns with gradient stops using this color space or during the import of tiling pattern with underlying color space. Available in R2 2018 Official Release Version.
Implement API for adding document outline (a.k.a bookmarks).
As some other decoders, JBIG2 may also handle different parameters in order to correctly decode the stream. Currently, decode parameters are not supported for this decoder.