Completed
Last Updated: 27 Mar 2023 07:14 by ADMIN
Release R1 2023 SP1
Ken
Created on: 26 Dec 2022 06:45
Category: PdfViewer
Type: Bug Report
0
RadPdfViewer: Input fields can't be read in some dark themes

Open the Demo application >> Interactive Forms example and apply the Office2019Dark theme. You will notice that if the text field enters edit mode, it is difficult to read the input due to black fore color and black backcolor:

1 comment
ADMIN
Dess | Tech Support Engineer, Principal
Posted on: 26 Dec 2022 06:58

Hello, Ken,

Thank you for pointing this out.

Currently, the possible solution that I can suggest is to specify white color for the text field: 

            var provider = new Telerik.Windows.Documents.Fixed.FormatProviders.Pdf.PdfFormatProvider();
            string filePath = @"../../../InteractiveForms.pdf";
            Telerik.Windows.Documents.Fixed.Model.RadFixedDocument doc = provider.Import(File.ReadAllBytes(filePath));

            foreach (RadFixedPage page in doc.Pages)
            {
                foreach (var a in page.Annotations)
                {
                    VariableContentWidget widget = a as VariableContentWidget;
                    if (widget != null)
                    {
                        widget.TextProperties.Fill = new Telerik.Windows.Documents.Fixed.Model.ColorSpaces.RgbColor(255, 255, 255);
                       
                    }
                }
            }

            this.radPdfViewer1.Document = doc;

I hope this will be suitable for your scenario.

Regards,
Dess | Tech Support Engineer, Principal
Progress Telerik

Virtual Classroom, the free self-paced technical training that gets you up to speed with Telerik and Kendo UI products quickly just got a fresh new look + new and improved content including a brand new Blazor course! Check it out at https://learn.telerik.com/.