[Kdelibs-bugs] [PATCH] Fixing KMessageBox cutoff texts

Andreas Pakulat apaku at gmx.de
Thu Nov 1 10:20:08 CET 2007


On Donnerstag, 1. November 2007, Aaron J. Seigo wrote:
> On Wednesday 31 October 2007, Andreas Pakulat wrote:
> > Hi,
> >
> > just had a look why all KMessageBoxes cut off their text and the
> > problem seems to be the width/height calculation code in
> > KMessageBox::createKMessageBox and the fact that the result is set
> > as Fixed Size for the label.
> >
> > I don't quite understand why the contents width/height is
> > calculated in the first place, so I just disabled the whole stuff 
> > and set a real margin on the label instead of changing its size.
> > Looks more apropriate to me.
>
> the point of this code was to prevent really long strings from
> creating reaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaally wide
> dialogs. it looks at the size of the screen that the dialog is on and
> ensures it doesn't

Ok, AFAICS this is for message boxes that don't have whitespace in them, 
or rather have a very very long part of the text without whitespace - 
like a deeply nested url...

> iirc it does something along the lines of ensuring it doesn't take up
> more than 1/3rd of that space while keeping things in a nice
> proportion (e.g. 2:3). the idea was to make nice looking dialogs.

Hmm, ok, I'll have another try later today, maybe I can find a better 
way of fixing this...

Andreas

-- 
You will be successful in love.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
Url : http://mail.kde.org/pipermail/kdelibs-bugs/attachments/20071101/5d8c67c3/attachment.pgp 


More information about the Kdelibs-bugs mailing list