Revision 82d42b8...

Go back to digest for 1st September 2013

Bug Fixes in KDE Base

Frank Reininghaus committed changes in [kde-baseapps/KDE/4.11] dolphin/src/kitemviews/kstandarditemlistwidget.cpp:

Fix filename trucation issues in Icons View with maximum number of lines

When the name of a file is too long to be shown inside the maximum
number of lines, the last line is elided. However, there were several
problems before this commit:

(a) "lastTextLine", which contains the text to be elided, was not
assigned the complete remaining text, but only the part that would
be put into the last line if there were more lines following. This
may be less than what would fit into the line because we try to not
break the text at random points.

(b) QFontMetrics::elidedText() was not given the width that is available
for the last line (that would be maxWidth), but only the width that
would be occupied by the text if there were more lines following

(c) The variable "nameWidth", which is required to calculate the QRectF
that is reserved for the name, was not updated correctly.

The result is that the text was sometimes trucated too early (especially
if there would be a line break early in the text if we had more lines
available), that there may be insufficient space to show the "...", and
that the hover/selection rectangle might be too narrow.

FIXED-IN: 4.11.1
REVIEW: 112265

File Changes

Modified 1 files
  • dolphin/src/kitemviews/kstandarditemlistwidget.cpp
1 files changed in total