Post not yet marked as solved
Since updating to Xcode 14.3 every view controller in every storyboard is not updating its IBDesignable's with an error saying it can't find the right .app with the right architecture. This all worked fine in Xcode 14.2
I'm running on an M1 mac mini
Error below:
/Users/****/Documents/Projects/****/****/Modules/Onboarding/Base.lproj/Onboarding.storyboard Failed to render and update auto layout status for ****ViewController (3EC-3V-hGn): dlopen(****.app, 0x0001): tried: '/****' (no such file), '/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Library/Developer/CoreSimulator/Profiles/Runtimes/iOS.simruntime/Contents/Resources/RuntimeRoot****.app' (no such file), '****.app' (mach-o file, but is an incompatible architecture (have 'x86_64', need 'arm64'))
I've tried following a stackoverflow post that suggested changing "Build Active Architecture Only" to "No" for debug builds. When I rebuilt I got a prompt from Xcode saying the build failed, and it asked me to turn on Rosetta to try again. I didn't try this as it seemed like this is broken, given it works fine on 14.2
Post not yet marked as solved
I added an asset catalog to an old iOS project that I'm in the process of updating. The app was originally created before asset catalogs existed.
I added an image and an icon set to my catalog. The icon works, and the image shows up when I run the app, but Interface Builder doesn't recognize the image by name when I type it into the Image field on an imageview.
I'm guessing that there is something somewhere which causes interface builder to read an asset catalog, which is probably not set on my old project, but I can't figure out what it is.
Thanks,
Frank
Post not yet marked as solved
Any hints or experience with the safe area and a hidden tab bar on iPhone X would be appreciated!We've been making updates to our app for iPhone X and we've run into one issue we haven't been able to resolve.Our app uses a UITabBarController. On some screens that are hierarchically below the UITabBarController, we hide the tab bar. On these screens, we normally have a bottom action bar of our own making that has a couple of action buttons in it. We hide the tab bar because it's odd to have this action bar above a tab bar both visually and when touching buttons (because it can be easy to mistap and activate a tab when an action button was the target or vice-versa).The problem occurs when we create one of these views. The view is defined via a UIViewController in an xib. If we create constraints from a subview (say, the bottom of a top level table view or the action bar itself) in the xib to the bottom of the safe area of the view controller's main view, the layout at runtime acts as though the tab bar is still visible even though it is hidden. So we have a space at the bottom of the screen that is the height of the bottom home button plus the tab bar height.After looking for solutions that didn't require specific checks for an iPhone X and iOS 11 (because iOS 10 doesn't have the issue), I relented and started trying anything that could work. If I create two constraints, one with a zero constant to the bottom safe area and one that forces the main view downward by the height of the tab bar, and then only make one of them active depending on what device and OS version is being run, it appears to work. Until it doesn't.The first layout of the screen on iPhone X will work, but if we then (for example) show a modal screen and then return to the first screen, the layout will be incorrect again. The bottom of the main view will go off the bottom of the screen.Uhg.
Post not yet marked as solved
anyone else notice this greek letter misspelled in the keycaps app?
i thought i was spelling it wrong but maybe not?
Post not yet marked as solved
Hi everyone, (you can answer in french)
I’m french-rookie in xcode, and I have a problem:
I’m trying to choice my custom font to add it in my Main.storyboard button, but it not works.
I have my « Font provided by application » line in my Info.plist, with the name of my font in [0]
(See images below)
When I’m on storyboard button, I chose « custom » in font selector, then display font list but my custom font doesn’t appear.
I already tried to install the font in my mac, but still stucked, nothing change 😭
Could you help me please?
Thanks a lot
(I specify that I scrupulously followed the way of doing explained on the Apple official page:
Adding a Custom Font to Your App )
Post not yet marked as solved
Whenever I switch away from a Nib file and then come back to it, Interface Builder "resets" its state. That is, the left-hand outlineView that shows the structure of an IB document collapses to a stupid "minimized" width and the canvas has scrolled away from the view/window I had selected before switching away from IB.
This has been a constant issue in Xcode 13 and persists in Xcode 14 Beta 2. Is anyone else seeing this behavior?
I have filed multiple Radars about it over the last year and not one has gotten a response (shocking, I know).
I have some NSPanels that are not resizable, the App is not localized and and don't need Layout Constraints. Any time I edit an NSText field in the .xib, XCode 14.2 starts to report many errors: "Views without any layout constraints may clip their content or overlap other views." I spent a lot of time trying to make XCode stop reporting these warnings, but I can't. Sometimes quiting XCode or restarting my Mac will make these go away.
According to XCode Help: "Auto Layout is enabled by default. To disable Auto Layout, choose View > Inspectors > Show File Inspector and deselect the checkbox for Use Auto Layout."
Too bad there isn't any checkbox for Use Auto Layout in the file inspector for the .xib, the .panel's view or the NSText Field so I can't actually do this. The editor>Layout>Automatic menu item is disabled. Is there really any way to disable Auto Layout or has Apple decided to require it?
Post not yet marked as solved
Is it possible to display the screen same as the size of iphone on Ipad even if the app supports iPad.
Want to prevent resize of screens on iPad for a library even though the app supports iPad.
is that possible?
Post not yet marked as solved
With Xcode 14, the device selection on the bottom of the storyboard canvas has changed, and the iPhone 12 and 13 mini screens are no longer there, as well as there only being one model of iPad. Is there a way to add more devices to this section?
I have simulators installed for these devices, and this is the way I've been checking compatibility so far, but this is not sustainable.
I appreciate any help that you can give me.
Post not yet marked as solved
Anyone knows how to solve this problem with safe area bottom??
Post not yet marked as solved
When I upgraded Xcode to the latest version 14.3, I have some problems with AEPServices.
Showing Recent Errors Only
underlying Objective-C module 'AEPServices' not found
failed to verify module interface of 'AEPServices' due to the errors above; the textual interface may be broken by project issues or a compiler bug
So I use more solutions about config search paths, target in build settings, and build phases, but it does not work for me. If anyone has encountered this problem, please give me a solution to fix it. Thanks a lot!
Post not yet marked as solved
I am trying to integrate a UIKit view into my SwiftUI project using UIViewRepresentable as an intermediate.
A TestViewVC.swift file was created containing just a simple IBOutlet:
import Foundation
import UIKit
class TestViewVC: UIViewController {
@IBOutlet weak var testLabel: UILabel!
}
A corresponding TestViewVC.xib file was creating containing just a single label centred on screen. The TestViewVC was then assigned as the File Owner's class.
These are then displayed within the SwiftUI context through the use of a TestRepresentableView.swift and TestViewVC.swift class (shown below).
//TestRepresentableView.swift
import SwiftUI
struct TestRepresentableView: UIViewRepresentable {
func makeUIView(context: Context) -> UIView {
// Load the XIB file and return its view
let nib = UINib(nibName: "TestViewVC", bundle: nil)
return nib.instantiate(withOwner: nil, options: nil)[0] as! UIView
}
func updateUIView(_ uiView: UIView, context: Context) {
// Update the view here if needed
}
}
//TestViewVC.swift
import SwiftUI
@main
struct TestApp: App {
var body: some Scene {
WindowGroup {
TestRepresentableView()
}
}
}
The app runs fine on debug however an NSUnknownKeyException is raised whenever label is connected to the IBOutlet. (Or any other outlet for that matter, even simply connecting the view results in the same error).
Any idea of which this is happening?
HiI recently updated to Xcode 11 GM seed. However I've noticed that the dreaded "Unknown class in Interface Builder file" is crashing my app. I haven't changed any class names or storyboards. Interestingly the app runs perfectly in teh simulator, but crashed on my phone.Here is what is being printed in the output window:MyAppName[9513:4230222] Unknown class _TtC10MyApp24SlideTableViewController in Interface Builder file.Could not cast value of type 'UIViewController' (0x1ebe282b0) to 'MyApp.SlideTableViewController' (0x104d05e08).MyAppName[9513:4230222] Could not cast value of type 'UIViewController' (0x1ebe282b0) to 'MyApp.SlideTableViewController' (0x104d05e08).I've deleted the class and recreated, removed the View Controller from the story board, made sure the view controller is references correctly as is the target, but the problem persists and I'm out of ideas.Is there a "reset" of the storyboard to reference the elements? Or some other way to resolve this?Many thanksCraig
Post not yet marked as solved
Hi,
the problem is not dangerous to life,
I don't want see the yellow button on top of the editor.
'Autoresizing Mask' is set to about 50 items, that works, except tableView, 10 warnings.
The tableView has 10 columns of 20 pixels width, min 10 and max 100000.
The ' Add new constraints' options are all grayed, so what ?
In an other project a warning was set for arrayController, I don't like Auto Layout,
the blue help lines are enough.
My question is : How do i can suppress this warnings ?
Kindly,
Uwe
What does this error mean?"Could not find a storyboard named 'main' in bundle NSBundle"
Post not yet marked as solved
Hello,
I have been working with storyboards for my projects without any problems.
However, since the XCode Version 14.0 (14A309), the "safe area" on the storyboard preview is wrong for landscape orientation, as you can see in the image below:
The "safe area" acts as in portrait (with margins on top and bottom) instead of margins on the left and right side as in the previous version. Also changing the device for preview does not help.
It seems to affect only the preview, as the safe area is well in place after building it on both iPhone 13 and iPhone 12 mini.
Do you have any idea how to fix this? Or is it a bug that should be fixed by the Apple developer team?
Thanks
Post not yet marked as solved
When running my program on my mac using xcode getting /Users/suhaan/Documents/kivy-ios/weatherpsychic-ios/Storyboards/Launch Screen.storyboard: iOS storyboards do not support target device type "mac".
Post not yet marked as solved
Xcode 14.2 is really crap.
I cannot find the Preview function as what I have in previous version. I cannot find this menu item:
Post not yet marked as solved
My app has 2 dylibs linked, in build settings run path is set to "@executable_path/../Frameworks" and a copy file rule is also there. The app runs fine for years now (in App Store).
But once I turn on IB_DESIGNABLE for a custom view, IB reports errors like below:
It seems IB tries to load the dylibs from somewhere in Xcode.app.
What should I do in order to get IB_DESIGNABLE to work in IB?
Post not yet marked as solved
I'm trying to back to my initial view controller, but it wasn't presented if the user was already logged in. So, when the user logs out, i want to go back to the initial view controller. i'm currently using a segue, but that would cause a memory leak if used too much. I can't user an unwind segue since the initial view controller was never presented. How would i do this?
Thanks.