Make register_function use key dict (as keyword arguments).

Don't register_dispatch before doing key_dict_to_predicate_key, as
this may be done after configuration time (such as morepath's
request.view()).

Check whether a name in a predicate dict is unknown, and give
error if so. This we want in request.view too, for instance.