Desktop icons

David Faure faure at kde.org
Sun Jul 20 18:03:10 BST 2003


On Sunday 20 July 2003 18:51, Waldo Bastian wrote:
> I have changed it to be "Hard disc". It will become "Hard disc (hda1)" when
> you have more than one hard disk (disc?). When you have one device that can
> be mounted at two different locations (some people have that, not very
> common) it will become "Hard disc [/mnt/foobar]". Unfortunately this looks
> horrible here since it gets wrapped as:
> 
> Hard disc [/
> mnt/foobar]
> 
> Question to kfm-devel: Does kde do the wrapping or is it done by Qt?

For desktop icons, KWordWrap does the job.

It wraps at word separators, which includes '/', so the above isn't too
surprising - but I see how it looks bad. I'm not sure which rule to make up
to avoid that though. Paths are always a bit special....
Hmm, something like: when finding a breakable char, check if the current word
"looks good" (i.e. contains any real chars, not only other breakable chars),
and if not, break before it. When hitting that '/', the current word is "[/", which
doesn't fullfil that requirement.....

-- 
David FAURE, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).
Qtella users - stability patches at http://blackie.dk/~dfaure/qtella.html




More information about the kfm-devel mailing list