Re: Selectable text in NSTableView?

Quincey Morris

On May 3, 2019, at 14:52 , Jens Alfke <jens@...> wrote:

If I set the “selectable” property of the NSTextField, nothing happens.

In a similar recent scenario, I found it takes two clicks when the text field is selectable but not editable. (Well, one click and one drag, if you’re actually trying to select text.)

What makes this seem unresponsive is that there’s no I-beam cursor in selectable-but-not-editable mode. It’s there but invisible after a second click (you can even move its — invisibly — with the arrow keys), but your brain resists believing it.

The reality is, it’s probably better to go ahead and subclass NSTableView and force it to pass the first click (or first drag, more likely) to the text field. I haven’t tried to do it yet, but I think there’s no built in behavior that isn’t going to make you angry on an ongoing basis.

Join { to automatically receive all group messages.