Fixes for context positioning (#143)