show/hide entity

closes #287
1:1 rewrite of the old code. Fixed