       if s.expandParentHeight {
         t.expandParentHeight = true
       }
+    }
+    t.width = width
+    if t.childrenWidth > t.width {
+      t.width = t.childrenWidth
+    }
+    t.height = height
+    if t.childrenHeight > t.height {
+      t.height = t.childrenHeight
     }
     if t.width > 0 {
       if borderRight {

        t.expandParentHeight = true
      }
    }
    if t.width > 0 {
      if borderRight {
        t.borderRight = 1

    var w = size.width - size.borderLeft - size.borderRight
    if w > 0 {
      NC.pd("expand count \(size.expandWidth) \(size.expandParentWidth) \(expandWidth)")
      NC.pd("child \(size.childExpandWidth) \(size.childExpandMaxWidth)")
      let cc = size.children!
      // if size.childExpandWidth {
      //   var anyCount = 0
      //   var ma
      //   var childrenWidths = [Int](count: cc.count, repeatedValue: 0)
      // }
      for s in cc {
        if s.width <= w {
          s.element!.draw(ap.x, y: ap.y, size: s)
          ap.x += s.width
