Added 'Format code' feature for RAW data editor.

Code in the raw editor is auto-formatted on mode select change (depending on the mode type). Additionally ive added 'Format code' button that gives the ability to format code at any time.