I have removed LaunchScreen.storyboard from my project and added my viewcontroller as initial view controller.
and from project navigation i have added Launch screen file to my viewcontroller storyboard.
how can we remove black screen when we launch our app
Select your storyboard who has your viewcontroller in Launch Screen File. Then go that storyboard and check Is Initial View Controller. Otherwise your launch screen wont shown or shown with black screen
Related
I want to remove the launch screen from my project because I want to add a GIF image as a launch screen. I tried to set Main.Storyboard as Launch screen file in target but it is not working.
You don't remove the launch screen. You must have a standard, static launch screen storyboard. It's used before your app is even running. You can't change that.
Add whatever static image you want to the launch screen.
If you need anything dynamic that you wish to show before the main storyboard is shown then you need to show it on your main storyboard or some other storyboard/root view controller you want to show before the main storyboard (but after the launch storyboard).
But do your users a favor and don't do anything that delays their ability to start using your app.
As you cannot set Gif image directly to launchscreen storyboard Try this way
Take first frame of your gif image as png and set it on the LaunchScreen storyboard.
Then in the next view controller to be shown after the LaunchScreen storyboard, create a view, put imageview in it and show gif image in it , it should be the same size as the image in your LaunchScreen storyboard.
Please refer this link https://github.com/kirualex/SwiftyGif
Nice example is given here to show gif image in UIImageView.
You can try Uber.
I have no idea how to remove the launch screen, but you can make the launch screen looks same as the first frame of your gif. After the static launch screen disappear, you can start your GIF.
Here is a video I take. Video
You will have to follow the same solution as rmaddy suggested. You will have to add a viewController which shows you animation, before you show your main storyboard, or your first viewcontroller whatever it is.
What you can do it, you can set an image which is identical to the first frame of your gif, as your default launch screen, so that it looks like there is an animation on the launch screen, when you show your gif containing launch screen.
Hope you get it.
Here is my question like I am having a storyboard called Tabbar.storyboard and another storyboard called Main.storyboard. Tabbar.storyboard is my initial storyboard and application starts with that storyboard. Now when I move from Tabbar storyboard to Main storyboard with enabled hidebottombarwhenpushed, Tabbar hides successfully but left an empty view instead.
I also put hidebottombarwhenpushed in my viewcontroller in which I pushed from tabbar controller but nothing worked
here is my of Tabbar storyboard.
Here is my in simulator.
Here when I push from Tabbar storyboard to main storyboard Tabbar is hidden but left an empty view. of simulator where you see an empty view at bottom.
Any help would be appreciated.
If you are using constraints, check if the bottom constraint of your UICollectionView [?] in your UIViewController are being set to "bottomLayoutGuide" (also check if "use safe area" option is checked/unchecked).
Using the XCode's view debugger is also helpful. Try to see where are the bounds of your views, and check if some constraints aren't being broken.
I see a white launch screen but my application requires black screen by default and all other elements floating.
Im able to covert latter screen black using storyboard but not the default launch screen.
create controller for that as LaunchScreen.storyboard can't have any animation only change view background or set an imageView
for that create rootViewController and do the animation in it
I am using SWRevealViewController as a slide menu in iOS. When I created the rear viewcontroller (the slide menu) a xib file was created with .m and .h files. I do not use autolayout and set the simulated metrics size as None.
The view seems all right when slide in and out on iPhone except that when the view is presented on iPad I want the positions of the menus to also change as the view becomes bigger but it doesn't.
Originally the view is as the image below shows:
In order to move the "settings" menu to the bottom I have made changes to the view settings of "settings image", "settings button" and the extra UIImageView as below:
but I want the settings menu to also locate at the bottom of the view just like it is now on iPhone. How can I do that?
I have used "Masonry" library to sort this out.
It is pretty amazing.
Check out Masonry from GitHub
I just saw a video demo of control-dragging from the view controller icon for an ipad storyboard at the bottom of a view controller to the toolbar within that view controller. While the view controller icon and the toolbar are not on the screen at the same time, the dragging actually scrolls the storyboard enabling the connection between the two.
However, in my ipad storyboard I am unable to make that auto-scrolling happen and thus unable to complete the control-drag.
Is there a way to make the storyboard scrolling happen while control dragging? I thought of temporarily moving the toolbar to the bottom of the screen to make the connection and then moving it back. But the storyboard won't auto-scroll to let me do that either. I'm using a 13" macbook pro. There appears to be no zoom setting that will have both on the screen at the same time.
Alternately, can someone tell me if there is an alternate way to accomplish that? Which part of the code would I control-drag to?
Thanks.
according to this, one can accomplish the same by control-dragging to the icon of the corresponding element (in my case the toolbar) in "document outline pane" which sits between the project navigator and the (storyboard) canvas.
http://developer.apple.com/library/ios/#documentation/iPhone/Conceptual/SecondiOSAppTutorial/GettingStarted/GettingStarted.html
doing so would bypass the inability to autoscroll within the storyboard.