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
Anonymous
25953 Views, 8 Replies

2016: Adding separators to shelves

Anonymous
Not applicable

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?

0 Likes

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: Anonymous

pshwayka
Advisor
Advisor
Accepted solution

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

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
Anonymous
in reply to: pshwayka

Anonymous
Not applicable

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...

 

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
Anonymous
in reply to: Anonymous

Anonymous
Not applicable

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...

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
Anonymous
in reply to: Anonymous

Anonymous
Not applicable

Kudo

0 Likes

Kudo

Message 6 of 9
Anonymous
in reply to: Anonymous

Anonymous
Not applicable

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. 🙂

0 Likes

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
Anonymous
in reply to: Anonymous

Anonymous
Not applicable

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.

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: Anonymous

brunogf13
Enthusiast
Enthusiast
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!
0 Likes

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: Anonymous

wrath_rage
Explorer
Explorer

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.

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