Adopting Dynamic Type

Self-sizing Table View Cells

  • Two options for self-sizing table cells:
    1. Autolayout constraints — add constraints to cell.contentView.
    2. Manual sizing — override -sizeThatFits:.
  • Set UITableView’s estimatedRowHeight instead of rowHeight and set rowHeight to UITableViewAutomaticDimension on iOS 8 for self-sizing table cells.
    • In the current seed, table views unarchived from a NIB have their rowHeight property set to a constant height by default. This will change to UITableViewAutomaticDimension in a future seed.

Self-sizing Collection View Cells

Invalidation Contexts

  • Fine grained invalidation methods:

  • Inform the collection view of a content-size change using the contentSizeAdjustment and contentOffsetAdjustment properties on UICollectionViewLayout (deltas).