博客链接,Cocoa App 开发进一步,表视图 TableView 、文件管理与拖拽
开始时,
拖入文件后,
博客链接,认识 Cocoa App 的开发:Cocoa Binding 、Window Control 、菜单栏...
Swift 5 updated , DangerCove/DCOAboutWindow
a replacement for the standard About dialog.
It adds the option to open acknowledgments and visit the website by clicking a button.
You can point to and maintain a custom Acknowledgments.rtf
file
Remember to hook it up to the 'About [app name]' menu item or a button.
You can change values by setting properties on AboutWindowController
:
/**
* 应用名,The application name.
* Default: CFBundleName
*/
let appName = BundleInfo.get.appName
/**
* 应用版本,The application version.
* Default: "Version %@ (Build %@)", CFBundleVersion, CFBundleShortVersionString
*/
let appVersion = BundleInfo.get.appVersion
/**
* 应用版权,The copyright line.
* Default: NSHumanReadableCopyright
*/
let appCopyright = BundleInfo.get.appCopyright
/**
* 应用信用: The credits.
* Default: contents of file at [[NSBundle mainBundle] pathForResource:@"Credits" ofType:@"rtf"];
*/
let appCredits = BundleInfo.get.appCredits
/**
* 应用网址: The URL pointing to the app's website.
* Default: none
*/
var appWebsiteURL: URL?
/**
* 感谢: The path to the file that contains the acknowledgments.
* Default: [[NSBundle mainBundle] pathForResource:@"Acknowledgments" ofType:@"rtf"];
*/
let acknowledgmentPath = BundleInfo.get.acknowledgmentPath
let acknowledgment = BundleInfo.get.acknowledgment
/**
* 设置致谢文件的打开方式,打开文件,还是窗口内展示
* If set to YES acknowledgments are shown in a text view, inside the window. Otherwise an external editor is launched.
* Default: NO;
*/
var useTextViewForAcknowledgments = false