My app observes NSWorkspaceActiveSpaceDidChangeNotification and set wallpaper on the active screen. But I see there is no way to distinguish between spaces on a screen. I'm not sure if I have read the docs thoroughly. I would like to know if it is possible to tell which space is active for the active screen.
Selecting any option will automatically load the page
Post
Replies
Boosts
Views
Activity
On my 27in monitor, the doc text is too small for reading. Is there any way to enlarge text size?
Maybe I should file a ticket to request for a new feature for this?
I am a little hesitant to ask this question because it's been years, during which I hoped it's just a specific problem of my own computer or Xcode version.
I'm not sure if it's only me alone with this problem.
First time run of any playground project is extremely slow (after I open it); sometimes it just never runs with the build indicator circling forever).
This is true for objc or swift playgrounds, or different machines, different Xcode versions, different OS versions.
Can anyone help?
I have a need to integrate icu (https://formulae.brew.sh/formula/icu4c#default) into one of my store apps. I'd like to know if this approach is supported by the app submission policies. Thanks.
I once enabled locate (not location) service but now I want to disable/remove it. It's really not very helpful compared to spotlight.
What is the correct commandline?
When I log in and start a Terminal window, a simple gcc command produces the following debug messages:
2022-07-15 13:52:41.470 xcodebuild[784:10833] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionSentinelHostApplications for extension Xcode.DebuggerFoundation.AppExtensionHosts.watchOS of plug-in com.apple.dt.IDEWatchSupportCore
2022-07-15 13:52:41.470 xcodebuild[784:10833] Requested but did not find extension point with identifier Xcode.IDEKit.ExtensionPointIdentifierToBundleIdentifier for extension Xcode.DebuggerFoundation.AppExtensionToBundleIdentifierMap.watchOS of plug-in com.apple.dt.IDEWatchSupportCore
Subsequent invoke of gcc does not produce these messages. How to avoid this small nuisance?
I have a custom view that acts as a container for many NSImageViews that will be created dynamically on the fly.
When the container view is resized (by parent window), some new subviews may be created and added to the container view, or some subviews may be removed because they are not fit into a smaller view.
I have two ways to handle the 'disappearing' subviews. One way is to hide them, the other is to remove them from the container view.
My concern is that - Is there a (big) performance difference between the two methods? Which is better?
I did searches on the Internet but could not find a definitive answer. The best thing I get is CGImageSourceCreateThumbnailAtIndex API function. But I don't know how create CGImageSource out of an NSImage object. Thanks for any suggestions.
I am aware of the following approach:
Add a custom view into a view in IB.
Set the class of this custom view, say "MyDatePickerView".
Now my datepicker view has a moderate complex UI, and I want to isolate its functionalities into a standalone XIB. Is it possible to do this in IB (I know I can do it in code)?
I really like to implement an overlay that is similar with what we have in NSDatePicker:
I know most of the time, we just use what Apple gives us behind the curtain, but I really want to know if this even possible. Thanks!
I think I can do this by creating a custom view overriding the following 2 methods:
@implementation MyTextField
- (BOOL)becomeFirstResponder {
NSLog(@"%s: %@", __func__, self);
return [super becomeFirstResponder];
//return YES;
}
- (BOOL)resignFirstResponder {
NSLog(@"%s: %@", __func__, self);
return [super resignFirstResponder];
//return YES;
}
@end
But there is a gotcha - I always get successive become/resign. That is when I get becomeFirstResponder, I also get resignFirstResponder immediately. Note - I only have one MyTextField instance on my window.
Is there another safe way to achieve my goal?
This is the first time I use KVO pattern. The code is quite simple but I could not get it working - the log method never gets run. What's wrong with my code?
@implementation ViewController
- (void)viewDidLoad {
[super viewDidLoad];
[self.view.window addObserver:self
forKeyPath:@"firstResponder"
options:NSKeyValueObservingOptionNew | NSKeyValueObservingOptionOld
context:nil];
}
- (void)observeValueForKeyPath:(NSString *)keyPath
ofObject:(id)object
change:(NSDictionary<NSKeyValueChangeKey,id> *)change
context:(void *)context
{
NSLog(@"%@", change);
}
@end
I have an annoying problem with Xcode 14.2. After opening a project, Quick Help pane works normally. But once a debugging session ends, it stops working (showing nothing). Meanwhile ALT+CLICK won't work either (no response).
After closing and re-opening the project Quick Help works again.
Is there any workaround for this nuiance? I already went back to 13.14.1.
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?
I am in peril. Can anyone save me. I am desperate!
I am using Xcode Version 14.2 (14C18) to build my 2 dylibs. I had no problems with older versions of Xcode (one and half a year ago). But it's causing code signing problems and Connect fails my submitted binary package complaining I had wrong entitlement on dylibs.
I contact Apple technical support and I got a reply:
Entitlements are only effective on a main executable. When you sign a shared library with entitlement then, at best, the system ignores them. However, in some cases you can run into mysterious problems like this one.
The key problem is that Xcode is autogenerating entitlement file for my dylibs. I have no entitlement files in my projects, I am sure.
codesign -d --ent - libsqlite3s.dylib
Executable=/Users/USERNAME/Library/Developer/Xcode/DerivedData/libsqlite3s-ahztenmeyvsijneqjzdtifjhljlr/Build/Products/Debug/libsqlite3s.dylib
[Dict]
[Key] com.apple.application-identifier
[Value]
[String] TEAMID.net.neolib.libsqlite3s
How can I turn off this 'useful' feature?