Leopard weirdness
Christiaan Hofman
cmhofman at gmail.com
Tue Jun 10 10:11:34 PDT 2008
On 10 Jun 2008, at 5:44 PM, Jim Witte wrote:
>
> On Jun 6, 2008, at 10:51 AM, Christiaan Hofman wrote:
>> However, one has to do a direct hit on the text to start editing.
>> I also think that the need to click on the text is annoying
>> behavior. I'm not sure if it's a bug though
>
> I would say it's a bug, because users who don't click directly on
> the text could get a behavior they don't expect - although I don't
> have Leopard installed. Also, if the cell is empty, from the user's
> POV there is no 'text' in the cell, so no indication of where to
> click - the obvious click target for editing is anywhere in the cell
> as there is nothing preexisting to edit.
I did some testing, and I don't believe this is a bug (though you can
file a bug report and see what Apple says). The actual behavior for an
editable NSTextFieldCell is this:
- empty cell: double-click anywhere in the cell starts editing
- cell with text: double-click on the text always starts editing,
double-click outside the text calls the double-click action if
present, otherwise does nothing
This seems to me intended behavior, the point being that you can call
the double-click action by double-clicking an empty area in the cell,
unless there's text, in which case you want to be able to edit.
>> I truly fail to see any reason for this (AOT single-click editing I
>> described above). Especially for still empty cells it makes it
>> really hard to edit. I do believe this is cause for a bug report
>> (or at least an enhancement request).
>
> What about having a "hidden feature" (Apple loves these) where if
> you command-clicked on a cell or something, it would automatically
> go into edit mode on the cell. Or for that matter, a haxie to do
> the same (although that would be sure to break, especially if Apple
> changed the TableView code in an update)
>
Certainly command-click is wrong, as that's used to extend a
selection. The de-facto standard for this on Tiger is Option-click.
>> You can't simply revert back to the old editing behavior, it would
>> require you to override several methods in NSTableView, like
>> mouseDown:. It's very tricky to do that correctly. Moreover, this
>> is now the standard behavior, so better be consistent. So I advice
>> you to get used to it.
>
> That too.. Although a command click in a cell would preserve the
> existing behavior, while adding a way to get the the old behavior.
>
> Jim
There really is no need to preserve the old behavior. It is more
important to be consistent within the OS than to be consistent within
an app (you normally don't switch back and forth between OS's, but you
do switch back and forth between different apps).
Christiaan
More information about the MacOSX-dev
mailing list