Post

Replies

Boosts

Views

Activity

Xcode 26, macOS 26, attempting to use alternate dock icons
I have added multiple status icons to my project, in the form of .icon files created with Icon Composer. The main app icon works, but the status icons are not working. I am attempting to load the images from the asset catalog using NSImage imageNamed:, and apply them to the NSApp dockTile using NSGlassEffectContainerView. I don't even know if that attempt is going to work, as I never get past the stage of NSImage loading the icons. Maybe someone on the forums knows what to do there? I'd be willing to use one of my coding support incidents to work through this if necessary, as my two incidents will expire as my subscription rolls over in August anyway. My project lives at https://github.com/losnoco/cog/, and the Tahoe attempt WIP lives in the wip.tahoe branch, with the latest commit as of this post being the attempt to adapt the Dock Icon generation. I'd love to know if I can adapt this easily. I'm also still trying to support existing non-Glass custom .png icons the user can add to their profile folder with buttons in the preferences, as well as supporting legacy status icons on pre-Tahoe installs. I also try to add a progress bar to the dock tile view when the app is processing something at length.
Topic: UI Frameworks SubTopic: AppKit Tags:
0
1
166
Jun ’25
Xcode: Can't attach to process
Just like this topic: https://developer.apple.com/forums/thread/713211 Except this also applies to the latest Xcode 15 beta 2. The Attach to process feature seems to be broken, as it is unable to enumerate a process list and display it for me to choose from. It just says "Getting process list..." forever. Edit: I seem to have found the problem. It is dependent on having a project currently open in Xcode. I am trying to debug a binary from someone else without their projects, just to peek at the Metal scene capture, and thus did not think to open a project first. Opening a project makes the process list fill out.
0
1
1.2k
Jun ’23
Mass re-IDing controls in all project XIBs
Is there a way to automate rebasing all controls in a project's XIB files to newly generated IDs? I have a slight problem with a translation assist site getting confused by the fact I have over a dozen XIB files, most of which still have controls identified by monotonically increasing integers rather than unique dashed alphanumeric strings, and several of the XIBs have the same IDs as each other on different controls, and this leads to such confusion as the translation site showing the comment string for one XIB alongside the string for another XIB, because they both have a "5.title". I would like to rebase all the numeric control IDs, and the associated .strings files paired with them. I probably have about 1700 strings in my project's dictionaries so far.
0
0
1.1k
Jul ’22
Xcode Cloud ignores my versioning attempts
Is it possible to control how Xcode Cloud versions the apps it builds? I would like to declare it to use the same template that my build system uses to generate its own Info.plist at build time: CFBundleVersion: [number of commits since a specific Git tag where I forked the project] CFBundleShortVersionString: [the same thing] And I want it to preserve the generated tags that I add to the Info.plist for informational purposes: GitHash: [the full commit hash that was built] GitVersion: [number of commits as used above]-g[minimum characters of hash to be unique, currently up to 8 now] BuildTime: [current date/time when Info.plist was generated near the end of build time] Is there any way I can automate at least the CFBundleVersion and preserving the rest of the custom tags with Xcode Cloud? Xcode Cloud unfortunately seems to completely override my version field, and sets it to the first 5 characters of the Git commit hash, which is incompatible with App Store version policy of only being numbers or dots.
3
0
1.6k
Jul ’22
How to properly use NSURLSession for audio streaming
I am trying to use NSURLSession for http and https streaming, but I encounter numerous issues doing so. For one thing, my file open function must be synchronous, since the caller is expecting to be able to start reading data the moment the open function returns. Also, the read requests are expected to complete on the same thread as the file is opened from, which also implies synchronous access. I also do my own decoding and playback interface, and support a whole host of exotic formats, so it's really impractical for me to use the AVPlayer interface.I also have a concern with using Core Audio to decode indeterminate length non-seekable streams which may not start on a packet boundary, but I'll take that to another sub forum of this site, since it's not really a networking question.
2
0
1.1k
Jul ’22
Is it possible to utilize the Spatial Audio API on macOS without targeting Mac Catalyst?
The question speaks for itself. Is there any exposed API for accessing or implementing Spatial Audio, for virtual surround playback, say, from doing my own multi-channel decoding and outputting to discrete surround speaker positions, and having that track a user wearing a Spatial Audio compatible headphone or earphone device attached to their Mac via Bluetooth? I maintain an audio player, and I currently implement a fixed position spatial audio downmixer for surround, as an option. I would also like to support Spatial Audio downmixing via the OS. And I do not want to have to convert my app to a Catalyst app and lose a good chunk of backwards compatibility with older macOS versions to do this.
1
0
1.2k
Jul ’22
LibcOverlayShims.h compile error
I'm getting this error trying to compile my framework, which I newly added some Swift code to: <module-includes>:1:9: note: in file included from <module-includes>:1: #import "LibcOverlayShims.h"         ^ /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/usr/lib/swift/shims/LibcOverlayShims.h:80:15: error: declaration of 'sem_t' must be imported from module 'Darwin.sys.semaphore' before it is required static inline sem_t *_stdlib_sem_open2(const char *name, int oflag) {               ^ /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX12.3.sdk/usr/include/sys/semaphore.h:43:13: note: declaration here is not visible typedef int sem_t;             ^ <unknown>:0: error: could not build Objective-C module 'SwiftOverlayShims'
0
1
1k
Jun ’22
Locating user folders outside the App Sandbox
I have developer an app, and it is in the App Store now, but apparently, I have done something rather pointless. I granted it the entitlements: com.apple.security.assets.movies.read-only com.apple.security.assets.music.read-only com.apple.security.files.downloads.read-only But I have no idea how to get the system paths associated with these entitlements. Currently, the user has to manually grant permission to files in these paths for them to work, as I have no idea how to exclude them from requirement to ask the user to add the directories. [[NSFileManager defaultManager] URLForDirectory:..] is useless, as it returns paths inside the app's container. This is also challenging, as I default to setting a file tree browser to the user's Music directory, which can be located anywhere, but instead, it points inside the sandbox container.
0
0
877
Jun ’22