Added the ability to specify a pattern to be matched before and/or after emoticons