public void Add(GridColumn newColumnDef) { int j = cols.Count; if (j == 0) { newColumnDef.Left = 0; newColumnDef.ColumnIndex = 0; } else { newColumnDef.Left = cols[j - 1].Right + 1; newColumnDef.ColumnIndex = j; } newColumnDef.SetParentColumnCollection(this); cols.Add(newColumnDef); #if DEBUG //contArrVisitor.dbug_StartLayoutTrace("GridCollection::Add(GridColumn)"); #endif InvalidateGraphicAndStartBubbleUp(); #if DEBUG //contArrVisitor.dbug_EndLayoutTrace(); #endif //-------------------------------------------- }