improved error handling in app editor

Ignore-this: 3cc8b6c9f1ab3fcbfc55403ae5949a3c

Now the app editor will highlight the line where an error is.
The error messsages are also now better formatted.

darcs-hash:20131123215348-c21fe-97fdfebc97a17cd5fc86dab13f6f459767c82dd6