makes refactored viewer with materialwidgetbuilder work, ref #167