Community
Maya Forum
Welcome to Autodesk’s Maya Forums. Share your knowledge, ask questions, and explore popular Maya topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

2016: Adding separators to shelves

8 REPLIES 8
SOLVED
Reply
Message 1 of 9
tiburbage
24309 Views, 8 Replies

2016: Adding separators to shelves

Due to all of the UI changes re: icons etc. in 2016, I elected to not migrate my 2015 configuration when installing 2016. Now I'm recreating my custom shelves.

 

I notice that pre-built shelves like "Polygons" have separators, which displays as a vertical bar between buttons. However, after inspecting those in that shelf, and searching the documentation, I can't work out how to add separators to my own shelves.

 

Can somebody point me to the documentation page which talks about how to add separators?

8 REPLIES 8
Message 2 of 9
pshwayka
in reply to: tiburbage

I don't see any documentation on adding shelf separators, but after examining the mel script for one of the existing shelves, I discovered that the command addShelfSeparator(); does the trick.  I was able to create a new shelf, add some items to it, then go in and edit the script to add the separator between shelf button definitions.

The shelf scripts are in documents\maya\2016\prefs\shelves.

(On a mac it would be <username>\Library\Preferences\Autodesk\maya\2016\prefs\shelves.)

 

I know...it should be easier than this.  Smiley Happy

Message 3 of 9
tiburbage
in reply to: pshwayka

What I tried, after looking at shelf_Polygons.mel, was to copy:

 

 

separator
-enable 1
-width 12
-height 35
-manage 1
-visible 1
-preventOverride 0
-enableBackground 0
-style "shelf"
-horizontal 0
;

 

and insert that into one of my custom shelves (using an external editor). Seemed like it got stripped the first time I tried it, but in the end it worked.

 

But as you suggested, I also tried just adding:

 

addShelfSeparator;

 

and after Maya read in the .mel, the expanded/interpreted result was the same as the 'separator' code snippet I had copied from shelf_Polygons.

 

Thanks for the input. Now Maya team, add a button "Add Separator" to the Shelf Editor for those not comfortable manually working with mel. Seems like a natural addition...

 

Message 4 of 9
jalbertson
in reply to: tiburbage

It's a one-click operation if you install Bonus Tools for 2016.   From the Bonus Tools Menu, go to Create -> User Interface -> Seperator.     Why it's not built into the Shelf editor window, I have no idea...

Message 5 of 9
Mak-Tekken
in reply to: jalbertson

Kudo

Message 6 of 9
Shrooblord
in reply to: tiburbage

Just a general note to confirm a question you Internet-going wayfarers out there might have:

 

I'm a Maya LT user and I was able to perform all the steps listed in this topic, including doing the manual approach by editing the mel script of the Shelf, as well as installing the Bonus Tools (yep, they exist for Maya LT, too!!).

 

So kudos for being a helpful topic, everyone. 🙂

Message 7 of 9
gigayo
in reply to: jalbertson

For the same reason they dont do a lot of things they should.. lazyness, i guess. Or because they dont need to. If they are getting massive profits, why they should be worried about anything? at least that is what it looks like, unfortunately.

Message 8 of 9
brunogf13
in reply to: jalbertson

Thanks Mate! Really easy yeah... but only when someone tells you! 🙂 Really doesn't make any sense to have it there.. Using Maya 2020 and still no Separators in the shelf Editor!
Cheers for the info!
Message 9 of 9
wrath_rage
in reply to: tiburbage

Or at the very least, when someone tries to load a shelf that already exists, just pop up a warning that you're about to overwrite a shelf.. or add a "referesh shelves" button.

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report