In context of this question I wanted to ask - how to provide custom controls to use with Form API? Especially ones that needs to be exploded into javascript and at least one additional hidden field to make their GUI work.
I can find manuals for Drupal 6 easily enough, but somehow I can't spot ones for 7. I know I need to start with hook_element_info(), but hook's description for Drupal 7 points to a manual for Drupal 6.
Could anyone provide step-by-step instruction how to make it work?