Re: FYI: GtkText design progress



Derek Simkowiak wrote:
> 
>      All,
>         I am one of the people working on a replacement GtkText widget.

I have read all of your posting carefully. So you plan to implement
text buffer as a linear gapped array and properies as a list. Seems
it's a strange mixture, because you have to iterate through properties
list on text change anyway. Imagine you have a heavily and variously
colored text and want to insert some text of the same kind at the end.
The cost will effectively be O(n*m), where n is number of colored
chunks in text widget, and m is num of chunks you plan to insert. No
good, is it?

So why not to implement data storage as a balanced binary tree?
The nodes will be chunks of text with their attributes, and if 
some piece of text with the same attributes grows too large, it can
be split in two. (what is 'too large' is to be defined yet.)
Do we have binary tree data storage class in glib? ;)

Leon.



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