Category "swift"

Google Places, Swift Package Manager & M1 Mac issues

I have students using Google Places AutoComplete with iOS UIKit and Swift. Students with M1 Macs still seem to not be able to use the simulator with this SDK an

Module compiled with Swift 5.3.2 cannot be imported by the Swift 5.6 compiler

After updating to Xcode 13 and trying to run my app on an iOS 15.4 simulator, I get the following error (note, this is not a repeat question). This error doesn'

How to make React Native Component background transparent?

I am using Tab Navigation which contains two screen, I need to make the background of each screen transparent so the app background is visible. This is how it l

After updated my Xcode 13.3.1, I unable to run my flutter project with the error CocoaPods not installed or not in valid state

Error in console: Warning: CocoaPods not installed. Skipping pod install. CocoaPods is used to retrieve the iOS and macOS platform side's plugin code that respo

Modify AppAuth alert

I am using AppAuth (0.95) to access google mail on my IOS app. Before redirecting to google sign-in, i get an alert with this message. 'Appname' wants to use

Is it possible to work with different schemas in Fluent with PostgreSQL?

I need to create tables with different number of fields for different users. I want to create a schema for each user, and in it a custom set of tables. I can do

How do I include iOS App Icon image within the app itself?

I have standard iOS app, with a standard app icon contained in Assets. I'd like to display the app icon within the app (using SwiftUI). Note that I am not ask

Event Delegation like in JavaScript, but in iOS Swift

Is there a way in Swift to capture events on a screen similar to how Event Delegation in JavaScript works? I would like to find a way to respond to events witho

SwiftUI System Cursor

I'm trying to change the cursor to a crosshair in SwiftUI on MacOS. I've put the following code into the AppDelegate applicationDidFinishLaunching() function:

SwiftUI: Why does @AppStorage work differently to my custom binding?

I have a modal presented Sheet which should display based on a UserDefault bool. I wrote a UI-Test which dismisses the sheet and I use launch arguments to contr

Core Bluetooth. How can I check does peripheral already connect?

During development I got a problem witch related to the connection central and peripheral. When one of the central already connected with perepheral I have to d

Build error for macOS in Swift Package for iOS platform

I am trying to add support for Swift Package Manager to one of my frameworks. The framework is iOS specific (I make use of UIKit on it), so I added the platform

How to remove '\u{ef}' character from String Swift

let's say I have a string var a = "#bb #cccc #ddddd\u{ef}" and i am setting it to textview like this let text = a.trimmingCharacters(in: .whitespacesAndNe

Making parts of text bold in SwiftUI

I was wondering how I would make only sections of a text bold while keep the rest 'regular' in SwiftUI. I currently have: Text("Coronavirus Disease of 2019")

How do I handle NSInlineData from Bluetooth scanning?

I want to use data that is passed through Bluetooth scan. and I want to split and use data from NSInlineData. I import data via Bluetooth scan as follows. fun

Images inaccessible from asset catalog in a SwiftUI framework

I've created an iOS framework that contains a single SwiftUI View. I've then added an Asset Catalog with a single image. Trying to access that image from the Sw

Using Vision and RealityKit Rotates Counterclockwise and Distorts(Stretches?) Video

I am attempting to learn object detection in iOS, and then mark the place of the detected object. I have the model trained and installed in the project. My next

GestureRecognizer in scrollView not working

I moved all my UIElements in a scrollView to avoid a loaded UIViewcontroller. But now the GestureRecognizers on the view does not work anymore. My View hierarc

How to add space and resize image for rightView of UITextField

I need to make this kind of text fields but I don't know how can I make spacing for rightView. Here is a code where I'm trying to set rightView image let i

UIKit automatically switch to another VC after launch screen appear

I'm trying to automatically switch from lauch screen to home screen after 3 sec. This is code in entry point view controller override func viewDidAppear