NSStepper ignores current NSTextField value
Posted
by JanX2
on Stack Overflow
See other posts from Stack Overflow
or by JanX2
Published on 2010-01-29T16:23:45Z
Indexed on
2010/05/23
4:00 UTC
Read the original article
Hit count: 555
cocoa
|user-interface
I have the same initial problem as described in Integrate NSStepper with NSTextField:
I need to have a NSTextField working with a NSStepper as being one control so that I can edit an integer value either by changing it directly on the text field or using the stepper up/down arrows.
Using bindings as commented on by carlosb results in a usable UI. However, in the initial question carlosb describes the following:
Problem is that if I edit the text field then click the stepper again it will forget about the value I manually edited and use the stepper's internal value.
This is why I am posting a variation on this question again. carlosb's use of bindings doesn't solve this problem. This happens in both the current project I am working on and a test project I have created. The test project can be found at GitHub. You can download it there (even without git) via the "Download Source" button in the top right.
Is there a clean way to solve this issue?
© Stack Overflow or respective owner