I understand that there are many questions like this already, but please read, this is most likely another.
So, I was working on a calculator, and I would like the user to be able to click a button and get a layout for a mathematical function (square, sqrt, log, etc.). This is a bit hard to explain, so here is a screenshot of what I need right from the Apple grapher app:

See, the user can click one of them, and he will be directly inserted into the text box, and then the user can edit any attributes.
I would like to do this while still being able to use UITextField, so really any suggestions or recommendations would be highly appreciated, I just can't solve it.