ios - UILabel positioning different when text is present vs when text isn't present -
here picture of how want view positioned (i have constraints set in interface builder)
below images want , how set in interface builder (pic # 1)
the second 1 interface @ runtime.
note: once labels textual data during runtime, view expands give labels space (i.e. first picture)
my goal eliminate "animated movement". want view/progress bar/everything remain static once has been situated @ runtime , not bouncing , down if data in labels or if isn't.
i not want use stack view because ios 7 not supported feature or would.
note: it's different colors, same view problem shows stated in question. lazy , don't want explain myself how lazy , why different...
you should add height constraint constant, e.g. 20, , relation "greater or equal" each of labels. way autolayout know exact height needed before label text set, , allow labels stretch vertically if text long 1 line
Comments
Post a Comment