My Custom keyboard has presets for each screen resolution of all Apple devices. So I have iphone, iphon5, iphone6, iphone6plus and ipad presets.
But in case user runs iPhone app (like instagram) on iPad, I need to load iphone keyboard preset and use its geometry.
Also iPhone 6 and 6+ can use stretched mode, when apps run like iPhone 5 app being stretched.
So determining UI_USER_INTERFACE_IDIOM
is not a solution.
Keyboard extension and host app can see screen geometry in different ways, so I am stuck here. Need to get at least application frame for host app or any other explicit way to get that geometry.
App and keyboard extension see geometry different ways:
Also Swift key seems to have same bug while running hosted inside of iphone app on ipad screen.
Swiftkey inside iphone app on ipad: