PATCH: KIO::RenameDlg

David Faure faure at kde.org
Mon Oct 13 07:24:11 BST 2003


On Monday 13 October 2003 04:56, Dawit A. wrote:
> On Sunday 12 October 2003 16:28, David Faure wrote:
> > On Saturday 11 October 2003 03:25, Dawit A. wrote:
> > > Hi,
> > >
> > > The following is one possible fix to correct the problem of an ungainly
> > > wide rename dialog box mentioned in BR# 62736. It uses QToolTip to show
> > > the entire name of the source file if needed.
> >
> > Good idea, but what about using KSqueezedLabel instead of
> > KStringHandler::cEmSqueeze, so that resizing the dialog shows more
> > characters?
> 
> I wanted to do it that way first, but then I realized that we really only want 
> to squeeze long file names and not the other parts of the message, no ? 

Yes - so what about using a QLabel, and a KSqueezedTextLabel, side by side?
Hmm, might be a bad idea for i18n.

Another idea:
maybe KSqueezedTextLabel could have setMiniminumCharsLeft() / setMinimumCharsRight(),
so it would not try to squeeze those chars. This still requires to call i18n on the string
with %1, then look for %1 in the resulting string, deduce the numbers of chars left and
right, and finally use arg().
Or we could use 3 labels from the result of the above (QLabel/KSqueezedTextLabel/QLabel);
might be simpler than enhancing KSqueezedTextLabel.

> > -        QLabel *lb = new QLabel( sentence1 + i18n("Do you want to use
> > another file name?"), this ); You shouldn't remove this label, it explains
> > the reason for the lineedit.
> 
> I did not remove it. See the lines above it...

Hmm? It wasn't visible in the screenshot...

-- 
David FAURE, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).




More information about the kde-core-devel mailing list