See the example program to see how it should work. To help you out with text fields and scroll bars, look at tcat, which is a little interface on top of cat.
The best thing I can say is try the example and make your program work like this one. For an example of matching gif files to buttons, and modifying labels, see itsduke. To get the name buttons working, see the "radio buttons" example from the "widgets" program in the demo directory. This one will take a little time, but is well worth the effort!