xcode-storyboard

start position of table view is wrong in simulator, and is not the same in storyboard

本秂侑毒 提交于 2019-12-17 20:30:05
问题 I created a tableview in storyboard, which looks good, but the start position is wrong in the simulator or device. The 'Label' should not be at the same position as the time. How could I solve it?? 回答1: Simulated metrics are just that. Simulated. They're useful to set to how the view will actually display in order to help set up the look in the storyboard, but whether or not a navbar or tabbar shows up in the actual program is irrelevant to whether or not you've selected it as a simulated

Crash when using gesture recognizers in StoryBoard

雨燕双飞 提交于 2019-12-17 16:28:18
问题 UPDATE This is an old question for an old version of Xcode. It turned out that the issue was a bug in Xcode which has been fixed. Original I have a storyboard generated from making a new tab iphone application (with ARC) In one of my tabs, if I drag a gesture recognizer (any, but let's say Pan) onto a control, and then set the selector to an action, it just crashes as soon as I go to the tab. There is nothing in the Console -- it appears to be happening while the storyboard is being loaded

IOS7, Segue and storyboards - How to create without a button?

喜夏-厌秋 提交于 2019-12-17 03:36:20
问题 I currently have a login View and an Application view, I have successfully implemented validation on the login view and I need to programmatically shift to the application view on successful validation. I understand I can add a segue to the login button and then call it programmatically like so... [self performSegueWithIdentifier:@"LoginSegue" sender:sender]; But this will obviously be triggered whenever the button is clicked (As the segue was created attached to the button). I've just read

IOS7, Segue and storyboards - How to create without a button?

懵懂的女人 提交于 2019-12-17 03:35:26
问题 I currently have a login View and an Application view, I have successfully implemented validation on the login view and I need to programmatically shift to the application view on successful validation. I understand I can add a segue to the login button and then call it programmatically like so... [self performSegueWithIdentifier:@"LoginSegue" sender:sender]; But this will obviously be triggered whenever the button is clicked (As the segue was created attached to the button). I've just read

How to assign an identifier to a UIViewController from the MainStoryboard?

…衆ロ難τιáo~ 提交于 2019-12-14 03:58:46
问题 Before I used to allocate and initialize a view controller using initWithNibName, where the parameter for the Nib name is simply the name of the xib/nib file. However, with the way Xcode/IB works with Storyboards now, I'm not sure what I need to do to initialize a view controller class with it's respective xib/nib. In my storyboard i have created the view controller and referenced it (from another view controller) and specified it as a Popover type. Any ideas how this is accomplished? Thanks.

View not showing up in iPad only in iPhone

与世无争的帅哥 提交于 2019-12-13 07:42:44
问题 I have a simple app where the UI is created using storyboard. I have a login screen with an icon and a login button. It is showing up when I run on iPhone, but on iPad. Both in simulator and on device. To check if it was due to my constraints, I just dropped one label without any constraints and view with blue background. Even these are not showing up. Build settings has Deployment Info --> Devices set to Universal. Any pointers to what is wrong will be greatly appreciated. EDIT I tried the

My app requires using instantiateViewControllerWithIdentifier - why?

谁都会走 提交于 2019-12-13 03:41:06
问题 I have added a Storyboard file to an app that initially had none. For some reason, I could not get my custom UIViewController to display correctly until I added this into didFinishLaunchingWithOptions : ActivityViewController *viewController = [[UIStoryboard storyboardWithName:@"MainStoryboard" bundle:NULL] instantiateViewControllerWithIdentifier:@"ActivityViewController"]; Why do I need to force the use of my storyboard like this? The iOS template projects (Single View, Master-Detail etc)

Opening a window for status bar OS X 10.10 application

拈花ヽ惹草 提交于 2019-12-13 02:39:35
问题 I'm developing a status bar OS X application with Swift 1.2 and storyboards. My application doesn't have an initial controller because I don't want any windows to be displayed when the app is being launched. But, I need to open a preferences window if the app hasn't been configured. How do I do that properly? Now I'm doing that with NSPopover , but that's an ugly solution and doesn't provide a good UX. Is there a way to open a window, a view controller, if an application doesn't have an entry

Why have my .storyboards gone red in Xcode 11.1?

∥☆過路亽.° 提交于 2019-12-12 17:54:28
问题 Just updated to Mac OS X Catalina (10.15) and Xcode 11.1, and some of my storyboards have gone red. All graphics appear to be there but, everything is RED. VERY red (as you can see below). They still publish OK and this isn't a problem on Xcode 11.0 on a OS X Mojave (10.14.6) on my MacBook Pro? Anyone? Thx 回答1: Obviously a change in storyboard previews in Xcode. Seems like it's no longer acceptable to show "simulated size: freeform" greater than iPhone screen height. Changing it to "simulated

NSSplitViewController causing contained views to draw over window corners

前提是你 提交于 2019-12-12 09:57:18
问题 I'm trying to create a little Finder clone using Cocoa. I'm placing a source list table view (to act as a sidebar) and a standard table view inside of an NSSplitView controlled by an NSSplitViewController . Unfortunately, when I run this, the standard table view's white background is drawn over the bottom right corner of the window, resulting in a non-rounded corner: I'm able to avoid the problem by not using NSSplitViewController , both with standard nib files or storyboards to get the