Unplanned
Last Updated: 30 Jul 2024 14:14 by Mathew

This is the code for inserting the image: 

        static void Main(string[] args)
        {
            FixedExtensibilityManager.ImagePropertiesResolver = new ImagePropertiesResolver();

            //Telerik.Windows.Documents.Extensibility.JpegImageConverterBase defaultJpegImageConverter = new Telerik.Documents.ImageUtils.JpegImageConverter();
            //Telerik.Windows.Documents.Extensibility.FixedExtensibilityManager.JpegImageConverter = defaultJpegImageConverter;

            //Output("fyb-64.png", "output-working.pdf");
             Output("fyb.png", "output-broken.pdf");
        }
        private static void Output(string resourceName, string outputFileName)
        {
            var document = new RadFixedDocument();
            using (var editor = new RadFixedDocumentEditor(document))
            {
                Stream image = new FileStream(resourceName, FileMode.Open);

                var table = new Table
                {
                    LayoutType = TableLayoutType.FixedWidth,
                    Margin = new Thickness(10, 0, 0, 0),
                };

                var row = table.Rows.AddTableRow();
                var cell = row.Cells.AddTableCell();
                var block = cell.Blocks.AddBlock();
                block.InsertImage(image);
                editor.InsertTable(table);

                var pdfData = ExportToPdf(document);
                File.Delete(outputFileName);
                File.WriteAllBytes(outputFileName, pdfData);

                Process.Start(new ProcessStartInfo() { FileName = outputFileName, UseShellExecute = true });
            }
        }

        private static byte[] ExportToPdf(RadFixedDocument document)
        {
            byte[] pdfData;

            using (var ms = new MemoryStream())
            {
                var pdfFormatProvider = new PdfFormatProvider();
                pdfFormatProvider.Export(document, ms);
                pdfData = ms.ToArray();
            }

            return pdfData;
        }

Workaround: Instead of setting the ImagePropertiesResolver, set the JpegImageConverter: 

            Telerik.Windows.Documents.Extensibility.JpegImageConverterBase defaultJpegImageConverter = new Telerik.Documents.ImageUtils.JpegImageConverter();
            Telerik.Windows.Documents.Extensibility.FixedExtensibilityManager.JpegImageConverter = defaultJpegImageConverter;

Completed
Last Updated: 12 Feb 2025 15:20 by ADMIN
Release 2025.1.205 (2025 Q1)

When loading some PDF documents with German culture, part of the text got missing.

Workaround: set English culture before loading the document

Thread.CurrentThread.CurrentCulture = new System.Globalization.CultureInfo("en-US");

Completed
Last Updated: 12 Feb 2025 15:21 by ADMIN
Release 2025.1.205 (2025 Q1)
ArgumentNullException is thrown when importing a document with missing indirect reference object.
Unplanned
Last Updated: 14 Feb 2025 13:26 by Vitalii
IndexOutOfRangeException is thrown due to wrongly processed image data.
Unplanned
Last Updated: 05 Jan 2018 08:06 by ADMIN
Currently RadPdfProcessing allows setting standard fonts using FontsRepository static properties.

However, in RadWordsProcessing font can be set only by specifying FontFamily, FontWeight and FontStyle. As there is no way to set standard fonts this way, API users cannot benefit from using these fonts which may help them achieve smaller PDF size as standard fonts may not be embedded. The same applies to RadSpreadhProcessing as well.
Completed
Last Updated: 17 May 2018 08:00 by ADMIN
ADMIN
Created by: Deyan
Comments: 8
Category: PdfProcessing
Type: Feature Request
5
Implemented import and export of IccBased, Indexed, Cmyk color spaces. Available in Q3 2015.

Available in R2 2018 Official Release version.
Completed
Last Updated: 14 Dec 2023 12:30 by ADMIN
Release Q1 2024

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);
}

Completed
Last Updated: 21 Aug 2020 07:34 by ADMIN
Release R3 2020
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.
Unplanned
Last Updated: 04 Oct 2018 08:44 by ADMIN
ADMIN
Created by: Anna
Comments: 0
Category: PdfProcessing
Type: Feature Request
5
The hierarchical document structure is a means to describe the PDF document structure, which is currently not supported. See 10.6.1 Structure Hierarchy on 856 page of the PDF specification for details.
This document structure is an alternative to the standard PDF structure and most non-Adobe software does not support it.

The document might have been created with Adobe software like Adobe LiveCycle Designer. Very often the document contains some fallback text in the standard PDF structure like:
"Please wait... If this message is not eventually replaced by the proper contents of the document, your PDF viewer may not be able to display this type of document."
"The document you are trying to load requires Adobe Reader 8 or higher. You may not have the Adobe Reader installed or your viewing environment may not be properly configured to use Adobe Reader. For information on how to install Adobe Reader and configure your viewing environment please see  http://www.adobe.com/go/pdf_forms_configure."
"For the best experience, open this PDF portfolio in Acrobat X, Reader X, or later."
Completed
Last Updated: 12 Aug 2019 11:54 by ADMIN
Release LIB 2019.2.812 (08/12/2019)
Although Lab color space is currently unsupported, the provider should not throw exceptions that break the whole file import.
Completed
Last Updated: 18 May 2023 07:24 by ADMIN
Release R2 2023
When a document is exported with a cross-reference stream, the stream is missing the required according to the specification Length property. Although most of the viewers open the document without any issues, some cannot. Such documents cannot be opened in MS Edge.
Completed
Last Updated: 29 Jul 2020 12:45 by ADMIN
Release R3 2020
For example, importing URI Action with invalid mailto URL scheme - mailto:***@***.**(E-mail), throws UriFormatException: 'Invalid URI: The hostname could not be parsed.'
Completed
Last Updated: 19 Apr 2021 10:35 by ADMIN
Release R2 2021

When a TrueType font is defined, the mapping of character codes to glyph indices depends on the built-in cmap table mappings defined in the font and the Encoding property defined in the PDF dictionary.

However, the current implementation maps all characters with cmap tables for Microsoft Symbolic and Macintosh Roman, which causes incorrect mapping results, e.g. space characters are mapped to an Ê glyph.

The issue is also described in the following public item: TryGetCharCode for OpenTypeFont uses wrong cmap and returns wrong charcode.

Workaround: Change the font  of the TextBoxField's widget appearance:
foreach (var widget in field.Widgets)
{
    widget.TextProperties.Font = FontsRepository.Helvetica;
}

Unplanned
Last Updated: 17 Feb 2020 14:10 by ADMIN
Created by: Richard
Comments: 0
Category: PdfProcessing
Type: Feature Request
5

Implement Replace method(s) which enable the users to replace a concrete string/content/text in a PDF document (RadFixedDocument).

Workaround
Check the sample project attached ("RemoveText.zip") that demonstrates how to remove text separated into several text fragments.
Completed
Last Updated: 09 Feb 2022 13:00 by ADMIN
Release R1 2022 SP1

When importing a not embedded TrueType Font defined as Type 1 subtype Font an InvalidCastException is thrown.

In PDF document:

<< /BaseFont /Arial /Encoding 21 0 R /Name /F13 /Subtype /Type1 /Type /Font >>

In Adobe Reader:

Unplanned
Last Updated: 18 Nov 2020 13:52 by ADMIN
Created by: Martin
Comments: 0
Category: PdfProcessing
Type: Feature Request
5

Support for exporting WMF (Windows Metafile) and EMF (Enhanced Metafile) images should be implemented for the Net Standard version.

To allow the library to export such images you can use the extensibility point for providing a custom implementation of the JpegImageConverterBase. More information and examples can be found in the PdfProcessing`s Cross-Platform Support help and Create Custom JpegImageConverter in .Net Standard knowledge base articles.

Unplanned
Last Updated: 20 Dec 2024 11:06 by ADMIN
Currently, RadFixedDocumentInfo is used only for the export of Author, Title, and Description document metadata properties.
Completed
Last Updated: 13 Nov 2024 08:50 by ADMIN
Release 2024.4.1106 (Q4 2024)
Watermark transparency is not imported correctly
Unplanned
Last Updated: 22 Jul 2021 11:22 by ADMIN
Created by: Suren
Comments: 4
Category: PdfProcessing
Type: Feature Request
5

This could be implemented by linking to RadFixedPages or Bookmarks.

Until this feature is developed this could be custom created with the help of Link annotations:

RadFixedPage toc = new RadFixedPage();
document1.Pages.Insert(0, toc);

FixedContentEditor editor = new FixedContentEditor(toc);

foreach (RadFixedPage page in document1.Pages)
{
	int pageNumber = document1.Pages.IndexOf(page);

	if (pageNumber > 0)
	{
		int factor = 20;

		int offsetX = 70;
		int offsetY = 20 + factor * pageNumber;
		editor.Position.Translate(offsetX, offsetY);

		Block block = new Block();
		block.GraphicProperties.FillColor = new RgbColor(255, 5, 99, 193);
		block.InsertText($"Page {pageNumber}");
		Size blockSize = block.Measure();
		editor.DrawBlock(block);

		Location location = new Location
		{
			Left = 0,
			Top = 0,
			Zoom = 0,
			Page = page
		};

		GoToAction goToAction = new GoToAction();
		goToAction.Destination = location;

		Link uriLink = toc.Annotations.AddLink(goToAction);
		uriLink.Rect = new Rect(offsetX, offsetY, blockSize.Width, blockSize.Height);
	}
}

Completed
Last Updated: 15 Sep 2021 13:14 by ADMIN
Release R3 2021
Unable to import field with a name the is not specified as a literal string