I would also like to point out that you can't edit a code block in place. You have to left click in it to select the block, then repeat the steps above to open the syntax highlighter.
I'd like to also add suggestion of copying your code to something like notepad or notepad++ to deal with spacing/wraparound and then past it back into the codeblock per Dan Patterson suggestion in comments found here.
and to tie in all the links...