gpt4 book ai didi

macos - 连续 NSTextField

转载 作者:行者123 更新时间:2023-12-03 17:33:50 25 4
gpt4 key购买 nike

我有一个 NSTextField 和 Label,其值绑定(bind)到 View Controller 中的相同 NSString enter image description here

这里的问题是标签只有在我按 Tab 时才会更新。
如何使其连续,以便我在文本框中输入的内容立即反射(reflect)在标签中?
截至目前,我正在使用 -(void)controlTextDidChange:(NSNotification *)obj; 选择器,但我期待一个仅绑定(bind)的解决方案。

最佳答案

在 Interface Builder 中选择相关的 NSTextField,然后导航到绑定(bind)检查器。您需要确保选中连续更新值:

enter image description here

关于macos - 连续 NSTextField,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28364338/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com