Hi,
There is an article on perl.com that might be useful: http://www.perl.com/pub/a/2004/01/16/regexps.html
Regexes are a programs. It takes time to learn new languages and that's why it might look difficult at the begining. With time and practice that kind of regex become (almost) clear.
Using /x and commenting is very important but having the right support from the tools you use is also important. Here is a little html document that show your regex colored. I couldn't get it to show directly in this answer so you'll have to copy past :-(:
<HTML>
<HEAD>
<TITLE>Smed generated dump</TITLE>
</head>
<body bgcolor="#FFFFFF">
<FONT color=#000000 style="BACKGROUND-COLOR: #ffffff"> <br> </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #ffffff"> <br> </FONT>
<FONT color=#f00000 style="BACKGROUND-COLOR: #ffffff"> / </FONT>
<FONT color=#ffff00 style="BACKGROUND-COLOR: #ff0000"> .* </FONT>
<FONT color=#ffffff style="BACKGROUND-COLOR: #ff0000"> ( </FONT>
<FONT color=#ffff00 style="BACKGROUND-COLOR: #643296"> [\$#\%>~] <
+/FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #00ff00"> | </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \@ </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #afeeee"> \w </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> ~ </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \$ </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #00ff00"> | </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \\ </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \[ </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \\ </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> e </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \[ </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> 0 </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> m </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \\ </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \] </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> </FONT>
<FONT color=#ff0000 style="BACKGROUND-COLOR: #ffff00"> \[ </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> 0 </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #f0f0ff"> m </FONT>
<FONT color=#ffffff style="BACKGROUND-COLOR: #ff0000"> ) </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #afeeee"> \s </FONT>
<FONT color=#f00000 style="BACKGROUND-COLOR: #f0f0ff"> ? </FONT>
<FONT color=#f00000 style="BACKGROUND-COLOR: #ffffff"> / </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #ffffff"> <br> </FONT>
<FONT color=#000000 style="BACKGROUND-COLOR: #ffffff"> <br> </FONT>
</body>
</HTML>
If your text editor supported this, you would have less problems getting in regexes. There few tools to work on regexes and they do the coloring as well.
Cheers, Nadim (NKH).