Support specifying the match index to replace.

This allows for replacing only a portion of the regex, which is lets
you replace a character only when it is followed by another specific
character. For example, `#()` defines a lambda in Clojure. but I don't
want to replace every `#`. With this patch, the following works:

    (add-to-list 'pretty-symbol-patterns
             '(?λ lambda "\\(#\\)(" (clojure-mode) 1))