All Questions
Tagged with autolayout objective-c
2,482 questions
0
votes
1
answer
85
views
Prevent text in UITextView from bleeding outside of textView
I have a UItextView within a UIViewController created in storyboard. The UITextView has an outlet property myTextView and constraints that keep it at a fixed size. One wrinkle: The vertical ...
0
votes
2
answers
214
views
How to dynamically controls constraint to active them without manually doing calculation and set active by my self?
I want the text label adjust its position based on the green view.
It should left alignment to the view if possible, but if the text content extent out of the dashboard, I'd like the text to right ...
0
votes
1
answer
531
views
Constraints a view to the bottom of WKWebView.scollView
I am trying to put a view at the bottom of the contentView of my WkWebView.scrollView, but it seems like the view always end up at the origin Y of 5000 or 8000 which is the random value of bound ...
0
votes
1
answer
529
views
How does one properly load/reload UITableViewCells in iOS 15?
For about a week I've been trying to figure out this predicament with table view cells not loading/reloading properly, and it seems to only be an issue in iOS 15. Running the same code in an iOS below ...
-2
votes
1
answer
558
views
autolayout-conform UILabel with vertical text (objC or Swift)?
How would I create an UIView / UILabel with vertical text flow which would look like the red view of this example screen?
I have read about view.transform = CGAffineTransform(... which allows for ...
0
votes
0
answers
34
views
How to programmatically lay out stacking views and rotate?
I'd like to layout 3 imageViews programmatically by setting the frames manually. I am able to set up the middle image just fine but when trying to rotate the other two, the images's frames distort ...
0
votes
1
answer
503
views
How to trigger auto layout offscreen without adding the view to view hierarchy
My scenario is that I need to generate PNG Image data from an UIView whose layout I will setup myself. I create an UIView viewA in memory, which I will use to create PNG data. This happens in a ...
1
vote
2
answers
614
views
UIScrollView jumps when content has almost the same size as screen
I have an UIScrollView that "jumps" to the end of the content on touch when the content has almost the same size as the screen. This does not happen when the content is significantly smaller ...
1
vote
1
answer
206
views
programmatic NSLayoutConstraint in Mac app resizes window contentView
I'm trying to get auto layout working programmatically in an Objective-C Mac app.
The goal pretty basic, a simple toolbar-like view across the top of the window. Height should not change, view should ...
0
votes
1
answer
122
views
Adding vertical spacing constraint causes conflicts with height
I am just playing around with autolayout. In my View i added a label on top, below that label i added a textfield and below that another textfield. Each one of them i wanted to have a fixed height. I ...
0
votes
1
answer
978
views
Set button constraints properly to show at the bottom of the screen in objective C programmatically
I was trying to show a button on the bottom of the screen it was coming above safe area and it was not expected.
Expected position: How to show exactly as like in below image.
Current implementaion: ...
-1
votes
1
answer
144
views
Adaptive height for UITableViewCell containing an UITableView
I have an UITableView (let's call it table1) which contains static rows. The first row contains another UITableView (table2), populated dynamically from an XML file on the internet, which is completed ...
3
votes
1
answer
5k
views
iOS Autolayout height is ambiguous for UILabel
Height is ambiguous for UILabel (topCommentLabel)
Height and vertical position is ambiguous for UIView (commentContainerView)
In the tableview cell using
_tableView.rowHeight = ...
0
votes
1
answer
110
views
UITableViewCell not autosizing
I have two labels in a UITableViewCell subclass. I want both labels to be multiline labels, so I have set the number of lines to zero for both of them. But the problem is that my table view cell is ...
0
votes
2
answers
726
views
Custom layout 1 large 2 small cells UICollectionView
I want to create a layout like this image below but having trouble understanding how flow layout can be used to achieve this kind of layout
Basically what I want is 1 large picture than 2 small ...