Re: /Library/Application Support off limits? (Davidap)

2021-04-21 Thread Jonathan Prescott via Cocoa-dev
Adobe, Google, etc., use the Apple security frame works and interfaces to temporarily elevate privileges to write their respective data to /Library/Application Support, which is actually where this data should go, based on Apple guidance. There is extensive documentation on this whole issue in

Re: sharing code between screensaver and regular app

2020-03-02 Thread Jonathan Prescott via Cocoa-dev
When you created the application, you should have created two pairs of files, AppDelegate.h/.m and ViewController.h/.m. The AppDelegate is used to augment and tailor the behavior of the NSApplication that is implicitly created as part of the AppKit framework. For your purposes, you may not nee

Re: What is the preferred way to set NSTextView content from NSAttributedString?

2020-02-02 Thread Jonathan Prescott via Cocoa-dev
Looking at the documentation for NSTextView, it is highly recommended that you manipulate the NSTextStorage associated with the view. NSTextStorage is a sub-class of NSMutableAttributedtString, so you have all of those capabilities as well. I’m just getting into this as well for my console app

RE: What is the preferred way to set NSTextView content from NSAttributedString?

2020-02-02 Thread Jonathan Prescott via Cocoa-dev
Did you tell V that it needs to re-load it’s display? There is a method on NSView (from which NSTextView is derived) called “needsDisplay(sic)” which sets a flag on the view so that the view will re-draw its content the next display cycle. So, after you set the content to T2, you need to call