First Baseline and Last Baseline Properties in UIStackView First Baseline and Last Baseline Properties in UIStackView xcode xcode

First Baseline and Last Baseline Properties in UIStackView


Suppose you have a two-line text view (or field or label or button) and a three-line text view, and you add them to a horizontal stack view. Do you want to align their first lines, or their last lines? That's the difference.

.FirstBaseline:

.FirstBaseline

.LastBaseline:

.LastBaseline

Note: I increased the vertical content hugging and compression resistance priorities to 1000 (required) to get this to work properly.