Added structured types for higer order function parameters

Some function parameters of function type (e.g. handlers, callbacks) was
described with the signature in the name-attribute, eg. <argument
name="function(index, value)" type="Function">. This have been modified
to used nested argument-elements to describe the signatures more
consistently.