Re: iterator resolution




Havoc Pennington <hp@redhat.com> writes:

[ ... ]

> Well, if conceptually we are thinking of the preserved spot as a mark,
> there are two types of mark: left gravity and right gravity. So the
> cursor is a right gravity mark; if you insert text at the mark, the
> mark ends up on the right. But FrooTkxt also allows a left gravity
> mark, that ends up on the left.
> 
> I'll register one vote for "insert leaves iter pointed after the
> text." I haven't decided which I like yet...
> 
> One thing I like about right gravity is that it makes it clearer that
> this is magic _insert() function behavior, rather than standard
> iterator behavior.

I'm definitely in favor of "insert leaves iter after inserted string" -
after all, inserting a series of strings into a buffer in forward
order is a common operation, inserting a sequence of strings into
a buffer in reverse order, a rare operation.

                                        Owen



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]