Tasharen Entertainment Forum
Support => NGUI 3 Support => Topic started by: vidjogamer on May 26, 2014, 11:29:21 AM
-
Is is possible to have the table ignore certain widgets when calculating the bounds for an item? I am adding a square widget to a table with children widgets that stick out of the bounds of the square. I want the table to ignore the children that are sticking out when positioning these objects.
-
You could disable those objects before updating the table. Just make sure 'hideInactive' is set to 'true'.
-
You could disable those objects before updating the table. Just make sure 'hideInactive' is set to 'true'.
There's one thing that doesn't seem to make much sense in UITable's behavior: it looks into clipped UIPanels when calculating objects bounds. Couldn't it be made to ignore protruding contents of clipped panels in future versions?
-
NGUIMath.CalculateRelativeWidgetBounds doesn't look inside clipped panels. It uses clipped panel's bounds instead. Line 455 of NGUIMath.cs. This is the same function that UITable uses to calculate content bounds (line 151 of UITable.cs).