Post

Replies

Boosts

Views

Activity

Reply to Standard Value is disabled in Xcode 13
I do not remember how older Xcode was working, but Xcode 13 does not permit us to set Standard unless the actual views are placed in the Standard position in the graphical editor. Is this a known bug or a new 'feature'? Not sure. But if you feel this new behavior is making your works difficult, you should better send a feedback to Apple.
Oct ’21
Reply to Application Error ?
The issue is the main file that shows the window What in the main file is the problem?????????? Please clarify. If you want to learn app programming, keep the main file as in the app template. Never modify it. If you are planning to learn something else, please clarify what you want to achieve.
Oct ’21
Reply to Application Error ?
If I have a Main file, I want to remove the Main file You cannot remove the Main file, so your question does not make sense. see the NSWindow the Window on the display from the code that I'm programming. Can you explain what you mean by this? Where should I search in the documentation to solve these issue ? I do not understand what your question is. What are these issue?
Oct ’21
Reply to Finding the right Protocol for Generic that is interpolated into a String
Given that both Strings and Ints can be used in string interpolation First of all, you need to distinguish string interpolation of which type. In case of Text, the type is LocalizedStringKey, not String. So, you may need to find how string interpolation of LocalizedStringKey is working. LocalizedStringKey.StringInterpolation As far as I read the parts Appending to an Interpolation and Instance Methods, I cannot find a common protocol which would work both for String and Int. So, one possible work around, which does not need any protocols, would be converting theVariable to String before applying string interpolation of LocalizedStringKey. struct MySubView<T>: View { @Binding var theVariable: T var body: some View { HStack { Text("This part isn't important") Text("But this is \(String(describing: theVariable))") } } } With this, you can use any arbitrary type for T, and with making the type conform to CustomStringConvertible, you can control the result of string interpolation for your custom type.
Topic: App & System Services SubTopic: General Tags:
Oct ’21
Reply to 'kUTTypeData' is deprecated: first deprecated in iOS 15.0
A simplified example of using UTTypeData in Objective-C: #import "MyClass.h" @import UniformTypeIdentifiers; @implementation MyClass - (void)testWithDictionary:(NSDictionary *)itemDict { NSData *itemData = itemDict[UTTypeData.identifier]; } @end UTTypeData is a constant declared in the module UniformTypeIdentifiers. You should not declare another UTTypeData in your code.
Topic: App & System Services SubTopic: Core OS Tags:
Oct ’21
Reply to App for iOS14 and iOS15 togeher
First of all, you need to make your project settings to target iOS 14. If your project is using iOS 15-only features, you may find some compile time errors and you need to fix them. After that, test your app carefully for both iOS 14 & 15, and when you are sure it's ready to publish, submit it as an updated version of your app.
Oct ’21