Further work on function editor.
Opening a function now works, saving does not