ios - Positioning of object programmatically in Swift -
i want set position of object programmatically. do:
youtubeico.frame.origin.y = 100
but nothing. doesn't change coordinates @ all. problem?
and second question:
when set in xcode constraints of webview(for ex: 10(top, left, right, bottom) disappears. when not set constraints it, appears. problem?
i want this:
you need set full frame like,
youtubeico.frame = cgrectmake(youtubeico.frame.origin.x, 100,youtubeico.frame.size.width,youtubeico.frame.size.height)
only y-axis change not it, have provide full frame that. or set centre, or offset.
Comments
Post a Comment