I'm making custom keyboard with obj-c, Xcode 7 (tried 6 too). The issue is that keyboard is loading too slow.
I tried to load completely empty UIInputViewController
's view - no changes. I have no xibs, no heavy resources. Please if someone know any solution of this problem, write an answer. user won't be glad to wait every time keyboard lags.
Custom keyboard appears with ~5seconds delay
Asked Answered
Update your question with some relevant code if you want any help. –
Peewee
I tried to run completely empty keyboard like this: - (void)viewDidLoad { [super viewDidLoad]; } Result is the same, so I don't think it's in the code –
Trader
Do you also find that your keyboard looks ugly, as if a low-res image was captured and displayed first, before the actual keyboard renders? –
Cobbett
It's a known issue that the keyboard (custom or not) may load slowly the first time it's opened after the app launch.
It happens only in debug mode and should not happen on a release build thanks to the high optimization level.
I'm having the same issue, sometimes, my keyboard doesn't show up, at the spotlight search. Do you mean that, when we install the keyboard on our device by xcode, it will slow, but after release build and update to appstore, it will load faster? –
Secede
Yes. To make sure, build your app as release and not debug. Optimization will then occur and the delay should vanish ;) –
Tootsy
@QuentinHayot Sir, I am making a custom keyboard myself too! Mine is having the same 4, if not 6, seconds of delay. Does this issue get resolved once it get released in the app store. I'm using swift. Currently even in testflight, the performance is really poor. For some details, I'm only using stackviews and buttons for them. I have a background image for it. Also, I am saving the keyboard defaults in a shared container using FMDB SQlite DB. Does this occur even in testflights. I've made other new prototype projects, and their performance is the same with 3-4 sec delays. –
Forbearance
@SumanAdhikari Try to build your app with a "Release" setting. If the delay does not vanish, you have a problem somewhere. –
Tootsy
@QuentinHayot It seems there is extra overhead due to AutoLayouts. The performance issue has vanished after disabling the Auto Layouts. Now, I am trying to make the whole layout using Springs and Struts sir. That way the performance is really fast. The culprit is Auto Layout. –
Forbearance
© 2022 - 2024 — McMap. All rights reserved.