Re: wrong wordwrap behaviour
- From: Owen Taylor <owt1 cornell edu>
- To: gale daedalus dra hmg gb
- Cc: gtk-list redhat com
- Subject: Re: wrong wordwrap behaviour
- Date: 29 Mar 1998 15:05:27 -0500
gale@daedalus.dra.hmg.gb writes:
> The text widget now does word wrap on word boundaries, which is
> good, but the behaviour of the function gtk_text_set_word_wrap is, I
> would argue, wrong. This function toggles between the text widget
> wrapping whole words and breaking words across lines. The Motif, and
> IMO correct, behaviour is to *always* wrap words on word boundaries
> and for wordwrap itself to be toggled - this used to be the
> behaviour under GTK aswell.
First, if you try fooling around with the default text in testgtk,
toggling word-wrap and changing the width. I think you'll appreciate
why I left the capability to break on characters. Word wrap for
code does not produce good results.
My intention was to have seperate functions
gtk_text_set_word_wrap (text, word_wrap);
gtk_text_set_line_wrap (text, line_wrap);
[ I suppose that could be combined into
gtk_text_set_wrap (text, GTK_WRAP_[NONE/WORDS/CHARS]) ]
The second could be implemented now easily enough. (And can
be simulated by setting GTK_TEXT (text)->line_wrap = FALSE).
But you would quickly discover why it hasn't been done. Horizontal
scrolling is not yet implemented. ;-)
(You might want to just not show the horizontal scrollbar for now).
Regards,
Owen
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]