Thanks Justin - that works

W dniu 2014-04-09 12:50, Justin Israel pisze:
Ok, don't ask me why this this is really needed, but obviously there is some kind of refresh issue with the nested tabs, and if you make it switch tabs and back programmatically, then it works. This small snippet at the end of your function fixes it with a hack. Note, the commented parts are only needed if you were only creating one top level tab and needed a dummy to switch to:

proc test_tabLayout()
{
        window;
 
        string $tabs = `tabLayout`;
        
        for($i=0; $i<5; ++$i)
        {
                paneLayout;
                        tabLayout;
                                for($j=0; $j<5; ++$j)
                                {
                                        paneLayout;
 
                                        $textScrollListUI = `textScrollList`;
 
                                        for($k=0; $k<5; ++$k)
                                        {
                                                string $item = ($i+1)*($j+1)*($k+1);
                                                textScrollList -e -a $item $textScrollListUI;
                                        }
 
                                        setParent..; // to inner tab
                                }
                                setParent..; // to outer pane
                        setParent..; // to outer tab
        }
 
        showWindow;

        //string $dummy = `paneLayout`;
        tabLayout -edit -sti 2 $tabs;
        tabLayout -edit -sti 1 $tabs;
        //deleteUI $dummy;
}
 
test_tabLayout;
 
 



On Wed, Apr 9, 2014 at 7:06 AM, Marcus Ottosson <[email protected]> wrote:
MEL! Eeek!


On 8 April 2014 19:10, Michał Frątczak <[email protected]> wrote:
I've got a nested tabLayout that has problems with displaying it's content.
The layouts hierarchy looks like: window -> tabLayout -> paneLayout -> tabLayout -> paneLayout -> textScrollList 
After showing the window, the active tab is empty, and I have to switch to other tab to refresh.
This is a big problem when i want to draw only one outer tab and one inner - there's no way to refresh. 

Here's a demo (pardon MEL, but python does the same):


proc test_tabLayout()


{


        window;


 
        tabLayout;


        for($i=0; $i<5; ++$i)


        {


                paneLayout;


                        tabLayout;


                                for($j=0; $j<5; ++$j)


                                {


                                        paneLayout;


 
                                        $textScrollListUI = `textScrollList`;


 
                                        for($k=0; $k<5; ++$k)


                                        {


                                                string $item = ($i+1)*
($j+1)*($k+1);


                                                textScrollList -e -a $item $textScrollListUI;


                                        }


 
                                        setParent..; // to inner tab


                                }


                                setParent..; // to outer pane


                        setParent..; // to outer tab


        }


 
        showWindow;


}


 
test_tabLayout;


--
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/6f527ace-4c0d-4b94-a8b8-86d673728d99%40googlegroups.com.
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/CAFRtmOA30NY8wWBwysw7PEC_%3D-3CUzE9PidEnyor2gL3N7DHkg%40mail.gmail.com.

For more options, visit https://groups.google.com/d/optout.

--
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/CAPGFgA3rVj8-dcduoFY_SY1SgrFCWV%3DdujAXpaB9CpB8_n7mMA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
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/53455C48.2090904%40gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to