I would of thought that a reasonable approach to this would be to locate a \n followed by any number of whitespace characters followed by { and replace with just {

Chris