That should be a problem Oh! Haha, I meant to say “should*n’t*“. How rude and sarcastic it made me sound just now. Sorry about that. :)
On 6 October 2016 at 19:28, Andrew Hazelden <[email protected]> wrote: > Hi MarkJ. > > I wanted to comment about your minimum width setting in the code sample > you provided. According to the workspaceControl documentation > <http://help.autodesk.com/cloudhelp/2017/ENU/Maya-Tech-Docs/CommandsPython/workspaceControl.html#flagminimumWidth> > that should be a boolean value so your code that sets the value to "mw=355" > wouldn't function as expected. You should probably add an entry to the > initial workspaceControl code of "minimumWidth=True", at the same time you > define the "initialWidth=355, " setting to get the results you are after. > > *minimumWidth*(mw) boolean create query edit > Sets the minimum width of control to the initial width. This should be > used along with initial width flag. > > Regards, > Andrew Hazelden > > > On Thursday, 6 October 2016 06:24:36 UTC-3, MarkJ wrote: >> >> Hi all, >> >> I'm trying to switch some of our base toolset so that the main UI (cmds >> built) now docks correctly in the same tab as the channelBox rather than >> docking to the right side of the main Maya UI. The ChannelBox is now a >> workspaceControl so I havce to call the UI through that as below, it's a >> bit of a pain to switch the ui over but I hate the fact that the right >> dockControl space is now the entire length of the Maya UI, and outside of >> everything else. >> >> So I did the following to make the UI tab into the workspace of the >> channelBox: >> >> >> >> element=mel.eval('getUIComponentDockControl("Channel Box / Layer >> Editor", false);') >> windowcall='myUIFunc' >> cmds.workspaceControl(animUI.workspaceCnt, label="Red9_Animation", >> uiScript=windowcall, >> tabToControl=(element, -1), >> initialWidth=355, >> initialHeight=720, >> retain=False, >> loadImmediately=False) >> >> cmds.workspaceControl(animUI.workspaceCnt, e=True,vis=True) # ensure we >> set visible >> cmds.workspaceControl(animUI.workspaceCnt, e=True, mw=355) # set >> minimumWidth >> cmds.workspaceControl(animUI.workspaceCnt, e=True, r=True) # raise >> >> Now that all works but I'll be damned if I can find a way to control and >> lock the width of this UI. If I go to the modelling tab and then my tab the >> ui is the correct width, presumably because I set the minimumWidth flag. >> >> However, if I go to the attributeEditor tab, then mine the ui remains the >> width of the attributeEditor. There's width query flags in the >> workspaceControl, but no edit. >> >> So the question is, how the hell do you set a base width that is >> respected for these? >> >> cheers >> >> Mark >> >> >> >> ------------------------------------- >> Mark Jackson >> CEO / Technical Director >> red9consultancy.com >> > -- > 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 [email protected]. > To view this discussion on the web visit https://groups.google.com/d/ > msgid/python_inside_maya/3ddf5aae-4d35-4e1b-8762- > 15b29ccc1312%40googlegroups.com > <https://groups.google.com/d/msgid/python_inside_maya/3ddf5aae-4d35-4e1b-8762-15b29ccc1312%40googlegroups.com?utm_medium=email&utm_source=footer> > . > > For more options, visit https://groups.google.com/d/optout. > -- *Marcus Ottosson* [email protected] -- 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 [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/CAFRtmOABrd_bbujBrKDLzi07fxj6CnGoTBYWTaevHgGj%3DE%2BA8w%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout.
