Re: [gtk-list] GTK text widget (was Re: Proposal for a new project)




Josh MacDonald <jmacd@CS.Berkeley.EDU> writes:

> With all this talk of KDE and HTML and all sorts of other people starting
> to really use GTK, it strikes me that someday, someone is going to notice
> that the text widget doesn't really work. [ ... ]

Yes, I had noticed ... my first toy app for PerlGtk used a text widget, so
I wrote a bit of code to retrieve all the text from the text widget,
then I found that hitting return in a text widget caused a segfault ...
I looked at it some but it seemed pretty complex (but well designed).

I think having a text widget is important, and that performance should
be one of the design goals - often you want to bring up a bit
of text or have a few lines for the user to edit - and that's what
I see as the important role of a text widget. For major editing,
people will want to use their primary text editor anyways ...

Although combining a text widget and HTML widget is intriguing, I'm
not sure that it's very feasible to combine nice looking layout
with editability.

So it might be good to keep the text widget simple.

> I'm wondering if people have given this any thought to this or could 
> recommend the appropriate path to completing the text widget and/or any of 
> your other wild desires.  At the bare minimum, does anyone have suggestions 
> for what the rest of the text widget API should look like?

The minimum enhancements (from my point of view) would be:

1) Make editing work

2) $text_widget->set_point(0)
   $text_widget->get_text($text_widget->get_length)

Regards,
                                        Owen



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