Custom Shelf divider icons?

Custom Shelf divider icons?

imrifley
Explorer Explorer
2,896 Views
5 Replies
Message 1 of 6

Custom Shelf divider icons?

imrifley
Explorer
Explorer

So I've noticed the following divider in all the default shelves found in Maya.  I was wondering if and how I'd be able to put them in my own custom shelves as well, since they're a very nice and quick way to direct attention and categorize things.  Me being the the hopeless OCD guy that I am, I was hoping y'all could tell me how I'd be able to replicate the results.  

 

Screenshot example should be attached to it.  Let me know if y'all cant see it.  Any help would be greatly appreciated.  

0 Likes
2,897 Views
5 Replies
Replies (5)
Message 2 of 6

t_chanma
Autodesk
Autodesk

If you go into the Shelf's MEL file with a text editor, just add "addShelfSeparator();" in the appropriate spots where you want them to appear.



Matt C

Senior Content Experience Designer

Maya Documentation | Maya Learning Channel |
0 Likes
Message 3 of 6

imrifley
Explorer
Explorer

I seem to be having issue with actually finding where I should put that.    Also, is that doable from the in-program MEL editor?

 

0 Likes
Message 4 of 6

t_chanma
Autodesk
Autodesk

You can find the shelves in "Documents > maya > <version> > prefs > shelves".  Open one of those in the Script Editor then add that line to add a divider.



Matt C

Senior Content Experience Designer

Maya Documentation | Maya Learning Channel |
0 Likes
Message 5 of 6

hviator
Explorer
Explorer

I have a Mac and I don't believe the filing system is the same way, in my Documents>maya it just has a projects folder and nothing else. Additionally, it doesn't show version> prefs> shelves, but there is a maya folder in my applications tab, with different folders there. Would the shelf script be located in those files?

Message 6 of 6

sebastien_mGDQUZ
Explorer
Explorer

Hi there,
I was looking for adding separator to my shelves and found out this thread.
It's a bit old already but I thought I could add something to it.
When editing a shlve file and adding the "addShelfSeparator();", I noticed that, when closing Maya, it replaces the function by the content of it to actually show the separator.

Here it what's been created

    separator
        -enable 1
        -width 12
        -height 35
        -manage 1
        -visible 1
        -preventOverride 0
        -enableBackground 0
        -backgroundColor 0 0 0 
        -highlightColor 0.321569 0.521569 0.65098 
        -style "shelf" 
        -horizontal 0
    ;


Now you can simply add this code where you need the separators !

I hope it helps 😉

0 Likes