I tried to reply to this and Google blocked it as spam?  I'll try to 
copy/paste my reply here and see if it goes through...

First, in your plugin you need to implement either stringClassName or 
getClassName functions to tell Maya what the name of your context is.

Then Maya will look for two files/procedures based on your class name:  
<Class Name>Properties.mel and <Class Name>Values.mel.
In the Properties procedure you create all of your UI, and in the Values 
procedure you set the current state of the UI.  The first time your tool 
becomes active you should see your Properties procedure being called, and 
then every time you enter it Maya will call your Values procedure to update 
it.

To double check that you have your class name correct, you can set your 
tool active and then run:  contextInfo -q -class `currentCtx`

Take a look at the helixTool example in the devkit, it creates a context 
and a Tool Settings panel.

And related to this is how to create an Options marking menu for your 
context, this is the menu you get when you are in your context and you hold 
Ctrl-Shift-RMB.  There Maya expects a file named <Class 
Name>OptionsPopup.mel.  The helixTool example doesn't create one of these, 
but you can look at a Maya example like lassoOptionsPopup.mel.  

-Tim



On Thursday 26 September 2024 at 04:24:05 UTC-4 Matin Falahmanesh wrote:

> Hi everybody!
> I'm implementing some custom manipulators and contexts, and I was 
> wondering how to implement the 'Tool Settings' UI for my custom context. 
> I've noticed that if you implement MPxContext::setTitleString, the text 
> will show up at the top of 'Tool Settings', but I couldn't find any 
> resources for displaying UI elements or attributes there. Does anybody know 
> how to do this?  
>
> [image: Capture.PNG]

-- 
You received this message because you are subscribed to the Google Groups 
"Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to python_inside_maya+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/python_inside_maya/e0072708-c373-4d88-92e4-b39b22b82b76n%40googlegroups.com.

Reply via email to