摘要: 一、简介 NSVisualEffectView 是 macOS 10.10 后开放的一个类,继承自 UIView 提供一个模糊效果的视图 二、相关属性 blendingMode NSVisualEffectBlendingMode 枚举 typedef NS_ENUM(NSInteger, NSVi 阅读全文
posted @ 2019-01-30 09:14 sundaysmac 阅读(994) 评论(0) 推荐(0) 编辑
摘要: mac开发系列17:定制NSView的事件处理 2017.08.14 11:39* 字数 399 阅读 217评论 0喜欢 1 2017.08.14 11:39* 字数 399 阅读 217评论 0喜欢 1 2017.08.14 11:39* 字数 399 阅读 217评论 0喜欢 1 这里以鼠标左 阅读全文
posted @ 2019-01-29 18:38 sundaysmac 阅读(1324) 评论(0) 推荐(0) 编辑
摘要: NSView转换为NSimage 与 UIImage转换为UIimage 总结 2016年07月21日 12:44:06 HiroGuo 阅读数:1061 2016年07月21日 12:44:06 HiroGuo 阅读数:1061 2016年07月21日 12:44:06 HiroGuo 阅读数:1 阅读全文
posted @ 2019-01-29 17:22 sundaysmac 阅读(815) 评论(0) 推荐(0) 编辑
摘要: import Foundation import Cocoa 在视图中的方法 extension NSView { /****1. 在drawRect方法中绘制 使用Quartz2D绘图函数在视图上绘制圆角矩形 ****/ override func draw(_ dirtyRect: NSRect 阅读全文
posted @ 2019-01-29 17:22 sundaysmac 阅读(636) 评论(0) 推荐(0) 编辑
摘要: Mac上多种字体名称的获取 在开发是我们使用的字体通常是系统常用的字体,而有时业务上的需求需要创建出特设字体,尤其是在游戏开发中字体需要一点特色,下面我们看下如何在mac上获取多种风格字体的名字 for(NSString *familyN in [UIFont familyNames]) { CFS 阅读全文
posted @ 2019-01-29 16:56 sundaysmac 阅读(1595) 评论(0) 推荐(0) 编辑
摘要: Swift 导入oc 库时引用不上怎么办? 2018.03.22 10:02 字数 272 阅读 265评论 0喜欢 0 如何在Swift中手动桥接OC? 1.创建swift桥接文件 2.设置桥接文件路径,也即Objective-C Bridging Header的路径,设置完就可以导入自定义的OC 阅读全文
posted @ 2019-01-29 16:32 sundaysmac 阅读(197) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/yuanya/article/details/21538919 2014年03月19日 16:17:00 newHung 阅读数:1058 2014年03月19日 16:17:00 newHung 阅读数:1058 2014年03月19日 16:17:00 阅读全文
posted @ 2019-01-29 15:20 sundaysmac 阅读(907) 评论(0) 推荐(0) 编辑
摘要: NSButtonTypeSwitch 就是勾选样式 其他样式可参考:http://blog.csdn.net/lovechris00/article/details/77976480allowsMixedState 代表是否可以混合选择。YES-有三种状态,-1、1、0;NO-2种状态,1、0。使用 阅读全文
posted @ 2019-01-29 15:03 sundaysmac 阅读(1809) 评论(0) 推荐(0) 编辑
摘要: swift中实现单选按钮 想要实现单选按钮Radio button: swift radio button swift radio button lib shamasshahid/SSRadioButtonsController: A Radio Button Controller class fo 阅读全文
posted @ 2019-01-29 14:52 sundaysmac 阅读(1420) 评论(0) 推荐(0) 编辑
摘要: http://www.itdaan.com/keywords/Show+NSMenu+next+to+NSButton+in+Swift+OSX.html http://www.itdaan.com/keywords/Swift+Mac+OSX+NSButton+title+color.html 1 阅读全文
posted @ 2019-01-29 14:36 sundaysmac 阅读(716) 评论(0) 推荐(0) 编辑