Bug 172116 - Long text lines in message boxes should be word-wrapped
Summary: Long text lines in message boxes should be word-wrapped
Status: RESOLVED FIXED
Alias: None
Product: kde
Classification: I don't know
Component: general (show other bugs)
Version: unspecified
Platform: Compiled Sources Linux
: NOR wishlist
Target Milestone: ---
Assignee: Unassigned bugs mailing-list
URL:
Keywords:
: 148870 (view as bug list)
Depends on:
Blocks:
 
Reported: 2008-10-03 23:48 UTC by Thomas Fischer
Modified: 2020-09-29 04:16 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Thomas Fischer 2008-10-03 23:48:28 UTC
Version:            (using Devel)
OS:                Linux
Installed from:    Compiled sources

Long text lines in message boxes are not wrapped by default resulting in one long line that is shorted by replacing the middle part of the text with "...".
A better solution would be to put <p> tags around the text which make Qt to wrap the text according to the message boxes size.

An example is kdebase/workspace/kwin/kcmkwin/kwincompositing/main.cpp (as of rev 866903) which contains the following KMessageBox call if the composite stuff fails to work.

KMessageBox::sorry( this, i18n(
 "Failed to activate desktop effects using the given "
 "configuration options. Settings will be reverted to their previous values.\n\n"
 "Check your X configuration. You may also consider changing advanced options, "
 "especially changing the compositing type." ));

The actual message box shows the text as follows:
"Failed to activate desktop effects using the given ...Settings will be reverted to their previous values.
Check your X configuration. You may also conside...tions, especially changing the compositing type."

It requires the user to enlarge the window to read the whole text.

I suggest to check the whole source tree with some script for KMessageBox calls with long lines. Then, either the text can be placed in <p>..</p> tags or some manual editing can be performed. In this step, "\n\n" could be replaced by a closing and opening <p> tag.
Comment 1 Alexander Mentyu 2018-03-28 15:31:02 UTC
Not relevant?, related issue https://bugs.kde.org/show_bug.cgi?id=161070
Comment 2 Thomas Fischer 2018-03-31 16:17:06 UTC
(In reply to Alexander Mentyu from comment #1)
> Not relevant?, related issue https://bugs.kde.org/show_bug.cgi?id=161070
Actually, I have not noticed this issue in recent years, at least I don't remember. Maybe the issue has dissolved itself during the migration from KDE4/Qt4 to KF5/Qt5?
I suggest to close this bug as it was obviously related to KDE4.
Comment 3 Christoph Feck 2018-04-27 00:58:53 UTC
Thanks for the update; closing.
Comment 4 Nate Graham 2020-09-29 04:16:15 UTC
*** Bug 148870 has been marked as a duplicate of this bug. ***