I kind of expected this to be the default behaviour for the NSTextField to automatically respond to left/right arrow key with caret movement. Unfortunately, in my app this does not happen. Is there an option to turn that behaviour on or do I have to add it myself?
To explain further, the interface is generated dynamically. I have views (xibs that contain NSTextFields) and their view controllers that I stack up (manually) on another view. When a view is created (that is, its controller (newView)) I use this code to add it to my NSBox's contentView (boxContent):
[boxContent addSubview:[newView view]];
[newView setWithLabel:attributeLabel forProperty:attribute];
newViewY -= [[newView view] frame].size.height;
[[newView view] setFrameOrigin:NSMakePoint(0, newViewY)];
newViewY -=padding;
Weird thing is that text input and backspace work while other keys (arrows, delete) do not.
Is this perhaps a problem with the NSResponder chain? Why does text input work then?