Xcode 7.1: UILabel added to sizeclass regular/regular shown anywhere - ios

In Xcode 7, I was able to add a UILabel only to the Regular/Regular size-class. I simply selected w: Regular h:Regular below the storyboard and added it to my controller using drag 'n' drop. Once I switched to another size-class, the element was shown as inactive in the document outline on the left. Everything fine.
Now the same approach doesn't seem to work. When I switch to another size-class after the label was added to regular/regular, the UILabel is still active in the document outline and shown when the app is running (on an iPhone for example).
Any pointers or hints more than appreciated! Release notes don't offer any clue. Doesn't look like a wanted behaviour that was mentioned anywhere.

Related

Selectable objects on UITableViewCell not responding to user input on iOS14

While compiling a couple of projects with XCode 12 (beta 5 is the latest version at the moment) and running them on iOS14, I've noticed that UIButton, UITextField, and many other selectable objects are not responding to user input when inside of a UITableViewCell.
In some cases, it is possible to work around the issue by bringing the object to the front (object.bringToFront()), but this is not working for all the cases I'm facing. I've also noticed an empty view (layer) on top of the components of the cell when I use the "Debug View Hierarchy" Tool. This view is not present on XCode 11 builds. Is this some new cell configuration that I'm missing? Is there a standard way of disabling this behavior or will I have to be hacky to fix this?
PS: The issues were not present on the same projects when compiled with XCode 11 (or previous), even when running on iOS14.
All the select response issue may caused by adding subview on UITableviewCell. The right way is add on UITableViewCell.contentView, check it first.

ios 9, white splash screen instead of launch image, working fine previously, seemingly nothing changed to cause it

When my app launches, I see a white screen, instead of my launch image. I am using a storyboard, as required, and everything was working fine for about 2 months before this. I didn't change anything related to the image or storyboard either, it just started happening. I should mention that this started happening sometime after my first time uploading to TestFlight...but I doubt that is relevant. I have tried changing the constraints of the image to make it smaller than the bounds, and it still doesn't show up, so it isn't the size of the image. Again, I seemingly did nothing to have this start happening. Most of the questions related to my problem on stackoverflow have to do with the user not using a storyboard as required with iOS 9. Please help. Thanks.
UPDATE
I launched it on the simulator (iPad2) and the launch image for that was too small...there was white exposed above and to the right, I'm guessing I need to fix something in the storyboard but I'm not sure what.
UPDATE
I made a new storyboard and assigned the launch-screen config to it, and there is still a white screen.
I deleted the UIImageView and then inserted a new one with dimensions 200 x 200.
I added the image to the UIImageView.
I adjusted the constraints to the same values that I was using before.
Adding the image to the 200 x 200 UIImageView, before adding the constraints, seemed to be the key.
Make sure that one of the view controllers has the Is Initial View Controller checkbox checked in the Attributes Inspector in the right sidebar, that got me.
In project by default you LauchScreen.xib. Put your launch image there and set it’s top, bottom, leading, trailing constraints. Tap your project file and scroll down. There you will see: LauchScreen option and MainStoryboard. Set LauchScreen to your LauchScreen.xib. That’s it))

Main.Storyboard Frames Not Updated

I am currently making an app which I plan to submit to the iOS App Store. Normally, when I update my frames in the Main.Storyboard of Xcode, it stays like that. However, now it does not. Whenever I close the app and reopen it later, the frames are not updated. It looks like this:
After I update the frames, it looks like this (what I want it to look like):
The app still looks fine when I run it on the simulator, but I still have 16 warnings in my app. I would like to remove these bugs as (I previously mentioned) I am submitting this app to the iOS App Store. How can I fix this? Thanks.
1)As it showing you have designed the layout in size class width-COMPACT & height-ANY. If you design your storyboard in size class width-ANY & height-ANY it will solve your problem.IT also happened with me.I have changed the size class & updated constraints of all ViewControllers.
2)It now shows a blank view controller. However, You will not get any warnings
3) Now You can make it visible by changing size class of the views inside the controller
select the view ->go to attribute inspector->go to bottom-> select installed & delete earlier selected size class
4)Do it for all views & update the constraints

uppercase label in xcode storyboard not wanted

I'm using xcode 6 with storyboard for ios app development.
I have a problem with UILabel in view controllers in storyboard: the text is simple and inlower case, but when I run the app in the simulator or in the device I see the Label text in UPPERCASE.
Labels have no outlets, and cannot be modified programmatically.
some one has a solution? I'd prefer not using IBOutlet and setting text by code..
I had somewhat similar problem. In my case everything(title, lables, button texts, etc.) was in upper case. I found out that "Localization Debugging" was on, so when I had language on iphone which was not supported by localization, it turned words automatically to upper case. When I disabled it, everything worked fine again.
Just go to "Product > Scheme > Edit Scheme" and there select "Run" and disable "Localization Debugging". (Sorry, I don't have enough reputation to post images, otherwise I would put here screen)
Hope it helps
I answer myself fot other people.
Nothing to do with this strange thing. It seems a xcode bug. Sometimes the labels appears uppercased, other times are ok.
I discover a trick that was using the attributed text in storyboard. in this way it works correctly.
Another way is to use a outlet and setting the uilabel.text by code.
Bye

why storyboard ui elements not showing on UIViewController in xcode 6?

I am new to IOS development. I am developing an app for IOS 8 devices. I used storyboard for my design yesterday my storyboard showing all UI design but today morning it show blank UIViewController no UI element vision please see in screen shot and very strange thing is that when i run my app all ui element visible in my device. I google but dont find any solution please help me out. Thank you in advance.
It looks to me like you are using size class and you went into a particular size class and added these views. Now you are back in Any size class, so the views are not there (that is why they are greyed out in the document outline at the left). They are available only for that particular size class. If you switch back to it again, whatever it was, you will see them again. Basically, you have created conditional views - the condition being that they are present only when that particular size class situation is the case.
In other words, if you want your layout to apply in the general case, you want to start by creating and editing it under Any size classes. Only then do you switch to a particular size class and modify the layout for that particular size class.
when i run my app all ui element visible in my device
Yes, because on your device the particular size class situation matches the size class you were editing when you added those views. So there they are. That seems to me to prove my guess is right.
I have the same issue while copy a ViewController to another storyboard.
Fixed by following steps:
1: Select the viewController
2: Click on 5th Tab
3: Set the simulated size to Fixed.
Select install:
Since all components [like label,textfield,buttons] are in disable mode, one select Installed check mark its will be enable again adjust constrain accordingly.
The size must be the same, in all xcode storyboard
In my case, it was due to me setting alpha to 0.0 and forgetting it.

Resources