【发布时间】:2023-03-18 08:27:01
【问题描述】:
我正在使用这个类别(对吗?)http://www.nightproductions.net/references/dsclickableurltextfield_reference.html#setAttributedStringValue
实现可点击的文本字段。我已经在我的控制器类中导入了头文件,并像这样设置它的属性字符串值
NSAttributedString* str = [[NSAttributedString alloc] initWithString:@"http://www.yahoo.com"];
[url setAttributedStringValue:(NSAttributedString *)str];
[str release];
文本字段不可选择且不可编辑。
文本字段值已设置,但不可点击且不是链接。
提前致谢。
【问题讨论】:
标签: cocoa hyperlink nstextfield clickable