Grasshopper in Layouts

I got this to work in layouts and in model space via grasshopper

a modification of this..