I want to change the color of the arrow that
backgroundColor property should handle that for you
I've used this approach a number of times and have never seen what you have in your screenshot. Are you sure you are using
popoverPresentationController.backgroundColor and not setting a different background color on a view or container? Below is screenshot of non-centered popover arrow. The view controller background is green, the popoverPresentationController.backgroundColor is red. Shown next to the code setting the value.
I looked at the project you posted and found the problem (although I'm not entirely sure why it's the problem). You are setting the popover presentation controller's
backgroundColor property inside your presented view controller under
viewWillAppear:. I suspect that setting the background color like this after the presentation happened is what triggers the bug pre-iOS 10.
If you set the popover presentation controller's
backgroundColor inside your presenting view controller's
onPopover: method, where you are also setting the
sourceRect properties (and before you actually call
presentViewController:), everything works correctly.