Post

Replies

Boosts

Views

Activity

Reply to SKTexture initialized with system UIImage has slightly wrong aspect ratio and ignores system symbol color
I believe there is no way to get the extra padding info. Yes I filed a bug ha ha ha. In principle you could render the UIImage into a graphics context and then create your SKTexture from that. Do you actually care about accurate typographic alignment of your symbol? If not, just use what you have. I know nothing about the colour issues you have mentioned.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Sep ’24
Reply to Do I need a privacy manifest when using UserDefaults and CloudKit in my app?
I didn't realize that User Defaults contained anything other than the data I write to it. Isn't it strange that Apple chose to add this peculiar "required reason" thing, rather than just fixing NSUserDefaults to do what you and I always thought it did? Maybe it's time to reconsider using UserDefaults at all. Yes, this. The only essential feature of NSUserDefaults is when you implement a Settings.bundle to make your settings appear in the Settings app. (Which, bizarrely, is not covered by any of the reason codes - so you have to lie in your privacy manifest if you use that.) Otherwise, just store your data in the filesystem and avoid all this agro.
Sep ’24
Reply to UnsafeMutablePointer direct exposure.
I directly want to use them in c++ as swift::UnsafeMutablePointer. Why? If it's not true what documentation mean, then what is the manifestation for exposing these UnsafeMutablePointer? We’ve already answered that, it’s just T* I guess you could write: namespace swift { template <typename T> using UnsafeMutablePointer = T*; };
Topic: Programming Languages SubTopic: Swift Tags:
Sep ’24
Reply to SKTexture initialized with system UIImage has slightly wrong aspect ratio and ignores system symbol color
I believe there is no way to get the extra padding info. Yes I filed a bug ha ha ha. In principle you could render the UIImage into a graphics context and then create your SKTexture from that. Do you actually care about accurate typographic alignment of your symbol? If not, just use what you have. I know nothing about the colour issues you have mentioned.
Topic: Graphics & Games SubTopic: SpriteKit Tags:
Replies
Boosts
Views
Activity
Sep ’24
Reply to Do I need a privacy manifest when using UserDefaults and CloudKit in my app?
I didn't realize that User Defaults contained anything other than the data I write to it. Isn't it strange that Apple chose to add this peculiar "required reason" thing, rather than just fixing NSUserDefaults to do what you and I always thought it did? Maybe it's time to reconsider using UserDefaults at all. Yes, this. The only essential feature of NSUserDefaults is when you implement a Settings.bundle to make your settings appear in the Settings app. (Which, bizarrely, is not covered by any of the reason codes - so you have to lie in your privacy manifest if you use that.) Otherwise, just store your data in the filesystem and avoid all this agro.
Replies
Boosts
Views
Activity
Sep ’24
Reply to UnsafeMutablePointer direct exposure.
I directly want to use them in c++ as swift::UnsafeMutablePointer. Why? If it's not true what documentation mean, then what is the manifestation for exposing these UnsafeMutablePointer? We’ve already answered that, it’s just T* I guess you could write: namespace swift { template <typename T> using UnsafeMutablePointer = T*; };
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Sep ’24
Reply to UnsafeMutablePointer direct exposure.
Can you Explain what does this mean? If you want, file a bug against the docs asking for that page to be explicit about how those pointer types map. The answer, as mentioned above, is that the Swift mutable pointer types map to * and the immutable pointer types map to const *.
Topic: Programming Languages SubTopic: Swift Tags:
Replies
Boosts
Views
Activity
Sep ’24