[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-i18n-doc
Subject:    Re: Word-wrap in message boxes.
From:       Waldo Bastian <bastian () kde ! org>
Date:       2002-01-16 20:47:18
[Download RAW message or body]

On Wednesday 16 January 2002 12:03 pm, Thomas Zander wrote:
> The more you make configurable the worse the usability gets of KDE as a
> whole. Please think before you make/suggest configurable. It is totally
> stupid to make this configurable in the first place!

Before more people get insulted let me give a short update. I seem to have 
found a reasonable algorithm to determine the size of a messagebox. It will 
prefer a size larger than the minimum required size but smaller than 1/3rd of 
the screen width. If the minimum required size is larger than 1/3rd of the 
screen width it will use that instead but it will never make the dialog wider 
than 2/3rd's of the screen. 

This is still based on Qt's WordBreak routines. It might be possible to 
squeeze words that don't fit into 2/3rd of the screen, but it will not be 
possible to provide a tooltip for that word only. That is, the tooltip will 
be active for the entire text and I guess should either contain the 
non-squeezed word or the total non-squeezed text.

If we want per-word tooltips someone should provide a widget that supports 
that. An advantage would be that we could cache e.g. the size of words which 
would make the various operations required slightly more efficient. A 
disadvantage would be that in order to stay consistent, it should also be 
able to handle rich-text. Given that, it might be easier to hack Qt so that 
it squeezes words when they don't fit, (and provide a tooltip) than to 
reinvent the wheel ourselves. 

Since the consensus seems to be that automatic linebreaks are here to stay, 
that means that all mid-sentence line-breaks within message boxes should be 
removed. Line-breaks should only be used to indicate end-of-paragraph.

Grepping the .pot (?) files for line-breaks which aren't preceeded by a '.' 
might provide a good start.

Cheers,
Waldo
-- 
bastian@kde.org  |   SuSE Labs KDE Developer  |  bastian@suse.com

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic