How to make Regex match the whole word when there is a submatch in that word ? Suppose for example I search for \'p{2,}y\' in "I am happy", I want m
\'p{2,}y\'