The text representation shown above is just for clipboard interchange purposes; it isn't really intended for editing by hand.
If you want to view/edit the scripts comprising a contraption, open its Prototype by either choosing "Prototype..." from the properties panel of an instance of the contraption or choosing "File -> Prototypes...", selecting the prototype, and clicking "Edit...". While in the Prototype editor you can then choose "Prototype -> Script..." to view the main script.
For additional information, see the custom widgets tutorial.