CYRKeyboardButton icon indicating copy to clipboard operation
CYRKeyboardButton copied to clipboard

how can add CYRKeyboardButton on keyboard extension

Open senjaliyavishal opened this issue 8 years ago • 3 comments

-add CYRKeyboardButton on Custom keyboard extension.

  • CYRKeyboardButton not working with keyboard extension.
  • i think issue found on "keyboardButton.textInput = self.textView"; line.
  • i have bellow library like..... https://github.com/kulpreetchilana/Custom-iOS-Keyboards how can add CYRKyboardButton on PMCustomKeyboard.m file please help me.
  • please download Custom-iOS-Keyboards project and in this project found PMCustomKeyboard.m.

senjaliyavishal avatar Apr 27 '16 12:04 senjaliyavishal

It is working. I have already tried that. You can't use self.textView like that. Instead, create your own textfield (no need to be iboutlet, just UITextfield) and make sure delegate is set to your view. After that, add this one. It is super cool.

- (BOOL)textField:(UITextField *)textField shouldChangeCharactersInRange:(NSRange)range replacementString:(NSString *)string {
    [self sendText:string];  // actually this one. I write inside that func >>         [self.textDocumentProxy insertText:str];
    return NO;
}

khantthulinn avatar Nov 03 '16 09:11 khantthulinn

can u elaborate please?

carloskekwa avatar Dec 13 '16 15:12 carloskekwa

@khantthulinn can u elaborate please about your answer?

carloskekwa avatar Dec 15 '16 09:12 carloskekwa