I think I found the answer in another thread.
"#\{((?>[^\{\}]+)|(?R))*\}#x"
I tested it with different lines and it seems to be doing this work.
Any comments on how this works.? Advantages and disadvantages.?
Thanks for the answers btw .. :)
source share