Custom widgets?

I've been making good progress so far. I think, at this point, I need to figure out how to make custom widgets. One should be easy: a hidden "autouser" field. Basically, all it does is take the currently logged-in user and makes their user id populate a hidden "users_id" field. This is to automatically associate a user to the records they create without them having to select their own username from a select box. If there is an easier way to do this, I'd like to know.
In any case, though, what is the simplest way to make a custom widget, and how would you then use it? I looked at the examples in HTML/QuickForm, but none of them looked all that simple. Just a "bare bones" custom widget is what I'd like to see, if possible.
In any case, though, what is the simplest way to make a custom widget, and how would you then use it? I looked at the examples in HTML/QuickForm, but none of them looked all that simple. Just a "bare bones" custom widget is what I'd like to see, if possible.