Closed shahriar-ax closed 1 year ago
Hi @shahriar-ax,
That's correct. Everything that is text manipulation you have to implement yourself by manipulating the string using the UITextDocumentProxy
closure parameter object.
To give you an example for the logic for a button you add the the following View for deleting
the character left of the cursor:
var deleteButton: some View {
Button {
textProxy.deleteBackward()
} label: {
Text("DEL")
}
}
For the case
change you need to implement your own business logic to accomplish that for your keyboard (SwiftUI gives you all the tools :-) ), and for the done
action, you call the submit closure parameter and provide the keyboard the submit action from outside via the onSubmitCustomKeyboard(:)
View Modifier, and you decide what happens upon that.
Let me know if you need further assistance!
Closed due to inactivity
in custom keyboard has no delete button, case change button & no dismiss or done button