Add support for Lab color space. Currently alternate color is used to render the pixels, which may result in incorrect colors.
According to the PDF specification (AdobeĀ® Portable Document Format Version 1.7):
Append a rectangle to the current path as a complete subpath, with lower-left corner (x, y) and dimensions width and height in user space.
The operation:
x y width height re
An invalid case:
0 - 595 -842 re
This leads to an exception thrown: System.NullReferenceException: 'Object reference not set to an instance of an object.'
Hi Telerik Support
We use your Telerik PDF-Viewer since your last Version "UI for WPF R1 2021" which supports Type 3 fonts.
Now the version runs productive by our customers. But after a day, they found some special PDFs that doesn't work quite right with your PDF-Viewer.
In the appendix you will find the PDf-Files as samples for the bugs that i'm describing.
Because of data privacy, the PDF-Files are cutted and cropped.
Also a demo project is appended (It could also be reproduced with the demo Progress Telerik WPF UI for th PDF-Viewer).
First Problem: Blank Page
Hint: It seems that only a few PDF-Files from a specific program seems to be a problem.
Second Problem: Displaying data delayed
I would be glad for a quick possible solution for our customer.
Best regards
Serge Schoop
When importing a document containing Outlines (Bookmarks) containing Actions with an empty dictionary:
<</Title(Bookmarks)/Parent .../First .../Last .../Prev .../A<<>>/Count ...>
leads to an exception thrown: System.MissingMethodException: 'Cannot create an abstract class.'
Even small documents (~30 kb) containing images encoded with CCITTFaxDecode filter can take about 10 seconds to be opened. In 2014 Q1 SP1 such documents load faster.
Implement import of documents containing Type 3 fonts.
This exception seems to be caused because the stream is not decrypted correctly and the stream data is corrupted. For instance when the stream is with FlateDecode filter the exception is InvalidDataException with message "Unknown compression method".
When we render any PDF file with 'x' number of page count and try to enter page 'x+1' in telerik:CurrentPageTextBox and hit enter, it will enable the Previous Page RadButton and if we click Previous Page then it will freeze the application.
System.ArgumentOutOfRangeException: 'pageNo should be greater or equal than 1 and less or equal than 4. (Parameter 'pageNo')'
Workaround: A possible approach could be to attach to the CurrentPageTextBox` KeyDown event in order to restrict the input.
XAML:
<telerik:CurrentPageTextBox x:Name="PART_CurrentPageNumberTextBox"
KeyDown="PART_CurrentPageNumberTextBox_KeyDown"
Text="{Binding FixedDocumentViewer.CurrentPageNumber, Mode=TwoWay}"/>
private void PART_CurrentPageNumberTextBox_KeyDown(object sender, System.Windows.Input.KeyEventArgs e)
{
TextBox textBox = sender as TextBox;
if (textBox != null)
{
if (e.Key == System.Windows.Input.Key.Enter)
{
int pagesCount = this.pdfViewer.PagesCount;
int currentPageNumber = this.pdfViewer.CurrentPageNumber;
if (this.pdfViewer.Document != null && (currentPageNumber < 1 || currentPageNumber > pagesCount))
{
RadFixedPage currentPage = this.pdfViewer.CurrentPage;
int pageNum = this.pdfViewer.Document.Pages.IndexOf(currentPage) + 1;
this.pdfViewer.CurrentPageNumber = pageNum;
}
}
}
}
When modifying Interactive Forms TextBoxField's value the entered changes are preserved after is clicked out of the TextBoxField's editing area. However the changes are not applied when the click is performed on the save button. As possible workaround you can raise a MouseLeftButtonDown event on the RadPdfViewer and after this execute the SaveAsCommand. For example: private void SaveButton_Click(object sender, RoutedEventArgs e) { MouseButtonEventArgs mouseEventArgs = new MouseButtonEventArgs(Mouse.PrimaryDevice, 0, MouseButton.Left) { RoutedEvent = FrameworkElement.MouseLeftButtonDownEvent }; ((FrameworkElement)this.pdfViewer.FixedDocumentPresenter).RaiseEvent(mouseEventArgs); this.pdfViewer.CommandDescriptors.SaveAsCommandDescriptor.Command.Execute(null); }