PDFAnnotation with PDFAnnotationSubtype equal to .widget is not refreshing its appearance after adding it to PDFPage

Originator:rafal.rebacz
Number:rdar://35039352 Date Originated:18.10.2017
Status:New Resolved:
Product:PDFKit Product Version:
Classification:Bug Reproducible:Always
 
Summary:
PDFAnnotations with PDFAnnotationSubtype equal to .widget are not updating its appearance after adding them to PDFPage.
Properties I tried to update, without success:
1. Change bounds
2. Change color/backgroundColor
3. Change text (widget value)
Steps to Reproduce:
1. Add PDFView as a subview of a view of UIViewController
2. Create new PDFAnnotation instance with type == .widget.
3. Edit annotation dictionary. It must be done AFTER it is rendered in PDFView.
4. Annotation dictionary is updated but its view is not updated.

Expected Results:
Editing annotation dictionary should update its appearance immediately.

Actual Results:
Annotation dictionary is updated but its view is not updated.

Configuration:
iOS 11.0.2, iPhone 5s
iPhone 8 Plus simulator

Added sample project.

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!