undo experiment with object orientation
add ostream to Context. improve error checking. fix indents
refactor to remove duplicate code
refactor to reduce duplicate code
refactor to reduce duplicate code. enable ostream save from OffscreenView
commit files created during refactor