tasty-imitation-keyboard icon indicating copy to clipboard operation
tasty-imitation-keyboard copied to clipboard

Start up speed

Open dzpt opened this issue 10 years ago • 1 comments

I've worked on custom keyboard for few months. This keyboard is really good at UI, but speed at show up is not good as many keyboards written in swift.

I've tested few keyboards in appstore, first time load is slow but second time is really fast. My keyboard and this keyboard having same trouble is always take long times at start up.

Don't know why, is that because of swift? Objective C brings better performance here?

dzpt avatar Nov 29 '14 21:11 dzpt

I don't think it has anything to do with Swift. My suspicion is that many 3rd party keyboards don't use UIKit objects for the buttons, but instead draw them directly in CoreGraphics or OpenGL. Compositing takes up valuable time. Personally, I'm not willing to make that optimization, as it would take too long and reduce the keyboard's flexibility.

Other than that, the biggest performance sink in my keyboard appears to be the fact that I use separate buttons for each page instead of reusing buttons across pages. I'll be addressing this in an upcoming release. So far, startup performance has improved 2-3x. This is roughly on par with most 3rd party keyboards, though still a tiny bit slower.

archagon avatar Nov 29 '14 21:11 archagon