|
How to get App Icon
9 messages
macOS 13.6 The app has Assets.xccassets/AppIcon and shows a nice icon in the dock. But an NSAlert just shows a boring alert-triangle. I want it to display the icon of my app instead. So I did: NSImage
macOS 13.6 The app has Assets.xccassets/AppIcon and shows a nice icon in the dock. But an NSAlert just shows a boring alert-triangle. I want it to display the icon of my app instead. So I did: NSImage
|
By
Gerriet M. Denkmann
·
|
|
Custom keyboard with search bar not behaving
I’m implementing a custom keyboard for iOS. It consists a UISearchBar the user can use to filter the “keys” they can use to type. When the search button is used, I call [searchBar resignFirstResponder
I’m implementing a custom keyboard for iOS. It consists a UISearchBar the user can use to filter the “keys” they can use to type. When the search button is used, I call [searchBar resignFirstResponder
|
By
Steve Mills
·
|
|
Handling a menu item in a modal dialog
8 messages
I'm trying to enable the Quit menu item while a modal dialog is running, is that possible? My window controller implements the terminate: action, and has a validateMenuItem: method, but validateMenuIt
I'm trying to enable the Quit menu item while a modal dialog is running, is that possible? My window controller implements the terminate: action, and has a validateMenuItem: method, but validateMenuIt
|
By
James Walker
·
|
|
Can someone spot what's going on here?
4 messages
Hi all, I have a long-standing app project/workspace that embeds several sub projects, which build as embedded frameworks. It all builds and runs fine as it should. I add a new framework subproject -
Hi all, I have a long-standing app project/workspace that embeds several sub projects, which build as embedded frameworks. It all builds and runs fine as it should. I add a new framework subproject -
|
By
Graham Cox
·
|
|
Is this a bug in AppDelegate?
7 messages
macOS Yosemite 10.10.5; Xcode 6.4 In testing a vanilla Document app I tracked down what may be a bug in Cocoa. I expected that the app would not open an untitled file because applicationOpenUntitledFi
macOS Yosemite 10.10.5; Xcode 6.4 In testing a vanilla Document app I tracked down what may be a bug in Cocoa. I expected that the app would not open an untitled file because applicationOpenUntitledFi
|
By
Peter Teeson
·
|
|
UIImageView Scaling
15 messages
I have a UIImageView, which I load with the following function: func loadData() { guard let recipe = recipe, let fileN = recipe.photo, !fileN.isEmpty else { imageView.image = nil xableTrashButton() re
I have a UIImageView, which I load with the following function: func loadData() { guard let recipe = recipe, let fileN = recipe.photo, !fileN.isEmpty else { imageView.image = nil xableTrashButton() re
|
By
Rick Aurbach
·
|
|
Time zone crap.
10 messages
I’m in the deepest darkest jungles of ferocious downtown Africa at the moment (yeah, science) and if I‘m not smoking crack again, all of my business meetings are jacked up by an hour because something
I’m in the deepest darkest jungles of ferocious downtown Africa at the moment (yeah, science) and if I‘m not smoking crack again, all of my business meetings are jacked up by an hour because something
|
By
Alex Zavatone
·
|
|
Swift with NSDocument and Revert To... browse all versions.
11 messages
I've been trying track the correct path from document to Control and back again. Document automatically loads WindowController.document I use didSet to loop down the ViewControllers and set there View
I've been trying track the correct path from document to Control and back again. Document automatically loads WindowController.document I use didSet to loop down the ViewControllers and set there View
|
By
Bill Pitcher
·
|
|
Is sandboxing doing some weird caching of alias files?
I have a little app that writes alias files to its App Support folder on a regular basis. The app is sandboxed, so that ends up in ~/Library/Containers/<apputi>/Data/Library/Application Support/<appna
I have a little app that writes alias files to its App Support folder on a regular basis. The app is sandboxed, so that ends up in ~/Library/Containers/<apputi>/Data/Library/Application Support/<appna
|
By
Steve Mills
·
|
|
Translate Services Menu to Swift
4 messages
This works: - (void)lookUppString:(NSPasteboard *)pboard userData:(NSString *)data error:(NSString * _Nullable *)error { NSLog(@“%s",__FUNCTION__); } But this does not: func lookUppString(_ pboard: NS
This works: - (void)lookUppString:(NSPasteboard *)pboard userData:(NSString *)data error:(NSString * _Nullable *)error { NSLog(@“%s",__FUNCTION__); } But this does not: func lookUppString(_ pboard: NS
|
By
Gerriet M. Denkmann
·
|
|
How to call Swift from Objective-C
2 messages
I have a Swift project called TestSwift: import Cocoa @NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate { @IBOutlet weak var window: NSWindow! func applicationDidFinishLaunching(_
I have a Swift project called TestSwift: import Cocoa @NSApplicationMain class AppDelegate: NSObject, NSApplicationDelegate { @IBOutlet weak var window: NSWindow! func applicationDidFinishLaunching(_
|
By
Gerriet M. Denkmann
·
|
|
WkWebView delegates
macOS 13.5 I made a WkWebView and added navigationDelegate and uiDelegate and implemented (almost) all delegate methods, each containing a print(). 1. I never see any prints (running in Xcode) 2. the
macOS 13.5 I made a WkWebView and added navigationDelegate and uiDelegate and implemented (almost) all delegate methods, each containing a print(). 1. I never see any prints (running in Xcode) 2. the
|
By
Gerriet M. Denkmann
·
|
|
lazy variables in Swift - should be read-only
2 messages
This works: lazy var session = makeSession() func makeSession() -> URLSession { let sessionConfig = URLSessionConfiguration.ephemeral return URLSession( configuration: sessionConfig ) } First: is it p
This works: lazy var session = makeSession() func makeSession() -> URLSession { let sessionConfig = URLSessionConfiguration.ephemeral return URLSession( configuration: sessionConfig ) } First: is it p
|
By
Gerriet M. Denkmann
·
|
|
How to get DOMDocument from WkWebView
5 messages
WebView is sort of deprecated. “In apps that run in OS X 10.10 and later, use the WKWebView class instead of using WebView” But: how can I get the DOMDocument of a WkWebView? I navigate (using WebView
WebView is sort of deprecated. “In apps that run in OS X 10.10 and later, use the WKWebView class instead of using WebView” But: how can I get the DOMDocument of a WkWebView? I navigate (using WebView
|
By
Gerriet M. Denkmann
·
|
|
Handling of (shift-)cmd-backquote
Applications on macOS respond to command-backquote and shift-command-backquote by bringing one of the application's non-frontmost windows to the front. I have these questions about how this works: 1.
Applications on macOS respond to command-backquote and shift-command-backquote by bringing one of the application's non-frontmost windows to the front. I have these questions about how this works: 1.
|
By
Richard Kennaway
·
|
|
Can I advantage of Swift availability features in a UITableVIewDelegate?
3 messages
I am working on an app which I would like to support 10.x for the next release. The problem I have is in a UITableViewDelegate: I have two actions which I'd like to implement for cells. In 10.x, I hav
I am working on an app which I would like to support 10.x for the next release. The problem I have is in a UITableViewDelegate: I have two actions which I'd like to implement for cells. In 10.x, I hav
|
By
Rick Aurbach
·
|
|
Can I Generate a Segue This Way?
2 messages
I have a situation where I want a user tap on a UILabel to generate a segue. (Yes, it sounds a bit strange, but it makes sense in context.) Working with a storyboard, I add a Tap Gesture Recognizer, c
I have a situation where I want a user tap on a UILabel to generate a segue. (Yes, it sounds a bit strange, but it makes sense in context.) Working with a storyboard, I add a Tap Gesture Recognizer, c
|
By
Rick Aurbach
·
|
|
Replacement for Launch Services API
2 messages
Is there a replacement for LSSharedFileListCreate, LSSharedFileListInsertItemURL &c that have been deprecated in the latest SDKs? Or is there another way to add something to the Finder's sidebar or to
Is there a replacement for LSSharedFileListCreate, LSSharedFileListInsertItemURL &c that have been deprecated in the latest SDKs? Or is there another way to add something to the Finder's sidebar or to
|
By
Sak Wathanasin
·
|
|
Repeating timer firing way to fast
4 messages
Hi all, I’ve been trying to figure out what happened on an overnight run of the code that drives our scientific experiment, and I’m seeing logs that imply that a timer has been firing much more rapidl
Hi all, I’ve been trying to figure out what happened on an overnight run of the code that drives our scientific experiment, and I’m seeing logs that imply that a timer has been firing much more rapidl
|
By
Jonathan Taylor
·
|
|
Crash with "illegal opcode" - how to debug this issue?
4 messages
Hi all, We’ve received a number of reports from users of a crash due to a SIGILL as follows: Exception Type: SIGILL Exception Codes: ILL_ILLOPC at 0x7fff32837454 Crashed Thread: 0 Thread 0 Crashed: 0
Hi all, We’ve received a number of reports from users of a crash due to a SIGILL as follows: Exception Type: SIGILL Exception Codes: ILL_ILLOPC at 0x7fff32837454 Crashed Thread: 0 Thread 0 Crashed: 0
|
By
Graham Cox
·
|