5

Just presenting a QLPreviewController to view an image (on iOS13.) Ideally I'd like it to switch into edit mode automatically (and so present the PencilKit stuff.)

Anyone know how to do this? The setEditing: approach (used on UITableViewControllers) doesn't seem to work in this instance.

Thanks

Leo Dabus
  • 229,809
  • 59
  • 489
  • 571
Scotty
  • 2,019
  • 1
  • 20
  • 31

1 Answers1

0

setEditing is documented in UIViewController and says that subclasses must implement it to react to the editing.

I've tried setting it in both instance creation and completion handler of presentViewController and it's not working, meaning that QLPreviewController doesn't implement it.

tl;dr: There is no standard way to enable editing unless you hack into navigationBar items and try to 'press' the edit icon.