Hi, this is probably one of those real easy things that I’m just not getting… I’ve created a custom display mode which is Shaded with the lines turned off, called it ShadedNoLines. Now I’m trying to have it as a button option on my Popup Menu, but when I enter the command text that I think it should be it does work.
The text I’ve entered in to the command window of the button editor is ! _ShadedNoLinesViewport but it just says Unknown command. I have it in the macro list of the Workspace editor and have tried numerous versions of the command but no luck.
I’ve created buttons before but this one is perplexing me! Any help?
I created a custom rendered shadening display mode named: MY-RENDER-ON-BLACK
so as suggested I creatd a button where left click has:
!_SetDisplayMode Mode=“MY-RENDER-ON-BLACK”
right mouse button click has:
!_SetDisplayMode _Viewport=_All _Mode=“MY-RENDER-ON-BLACK”
sadly this only works partially…
If I set this manually inside a viewport dropdown it works.
after that also the right mpuse button applies my shading setting on all views.
however left does not work.
Just a slight tune up, @JSD - if you are using display mode changes as you work, you probably do not want the ! at the start of the macro - this will stop any running command. Instead you can put the ’ prefix, with no space, to tell Rhino that the following command is nested (i.e. can be run inside another command)
'_SetDisplayMode Mode=ShadedNoLines
If you do want the ! then put a space after it and before the actual command name including the “_” part.
And yes, as mentioned in another post, maybe the Wiki page needs to be updated and have more complete info…
After testing here it looks like no special characters are recognized, the display mode name should not contain dashes, underscores, spaces, slashes etc. if you want the macro to work. Funny because if you duplicate a display mode it initially is proposed as Copy of XXX with two spaces in it. Now revising all of my custom display mode names to be one single camel-cased name with no spaces, dashes or underscores.