Closed
Bug 249141
Opened 22 years ago
Closed 17 years ago
Incorrect header cropping on narrow tree columns (ellipsis in wrong column)
Categories
(Core :: XUL, defect)
Core
XUL
Tracking
()
VERIFIED
FIXED
mozilla1.9.2a1
People
(Reporter: mnyromyr, Assigned: neil)
References
Details
(Keywords: verified1.9.1, Whiteboard: [fixed1.9.1b3])
Attachments
(6 files, 1 obsolete file)
|
4.27 KB,
image/png
|
Details | |
|
1.26 KB,
patch
|
enndeakin
:
review+
roc
:
superreview+
dbaron
:
approval1.9.1+
|
Details | Diff | Splinter Review |
|
1.93 KB,
application/vnd.mozilla.xul+xml
|
Details | |
|
1.99 KB,
application/vnd.mozilla.xul+xml
|
Details | |
|
1.59 KB,
application/vnd.mozilla.xul+xml
|
Details | |
|
5.13 KB,
patch
|
roc
:
review+
|
Details | Diff | Splinter Review |
When narrowing tree columns, the header text gets cropped eventually and
substituted by an ellipsis. But before reaching the minimal width, the ellipsis
"jumps" to the left into another column... (see attached screenshot)
Example: "Total" column in the MailNews folder pane tree.
Found in: Mozilla 1.3 on Win2k, Mozilla 1.8a2/20040627 on Win2k, Thunderbird 0.7
on Win2k, Mozilla 1.8a2/20040629 on Linux Debian Woody. Theme does not matter
(tested Classic, Modern, Noia).
| Reporter | ||
Comment 1•22 years ago
|
||
Comment 2•22 years ago
|
||
WFM Thunderbird version 0.7+ (20040630)
Comment 3•22 years ago
|
||
Mmh I can see it for some header columns and not all. Affected columns are
Unread and Total.
| Reporter | ||
Comment 4•22 years ago
|
||
It seems as if only the folder and thread pane trees in MailNews and Thunderbird
are affected, and only the columns Unread, Total and Size...
| Reporter | ||
Updated•19 years ago
|
Summary: Incorrect header cropping on narrow tree columns → Incorrect header cropping on narrow tree columns (ellipsis in wrong column)
Component: XP Toolkit/Widgets: Trees → XUL
QA Contact: xptoolkit.widgets
Comment 6•17 years ago
|
||
I can confirm this on both, Thunderbird 2.0 and 3.0.
The problem here is that those columns #folderUnreadCol, #folderTotalCol, #folderSizeCol on folder pane and #sizeCol, #unreadCol, #totalCol on message window have text-align: right but the property "crop" has a value "right" (they should be "left").
Comment 7•17 years ago
|
||
This patch adds the property crop="left" for those columns on messenger.xul. I'm not sure if this columns follow rtl, ltr directions...
Updated•17 years ago
|
Attachment #354908 -
Flags: review?(mkmelin+mozilla)
Updated•17 years ago
|
Assignee: Jan.Varga → pardal
Updated•17 years ago
|
Attachment #354908 -
Flags: ui-review?(clarkbw)
Comment 8•17 years ago
|
||
Comment on attachment 354908 [details] [diff] [review]
proposed patch
[Backout: Comment 13]
looks good
Attachment #354908 -
Flags: ui-review?(clarkbw) → ui-review+
Updated•17 years ago
|
Attachment #354908 -
Flags: review?(mkmelin+mozilla) → review+
Comment 9•17 years ago
|
||
Comment on attachment 354908 [details] [diff] [review]
proposed patch
[Backout: Comment 13]
This should be crop="start" instead. (treecol should handle rtl vs ltr), and the part for the folder pane is now obsolete - as we don't have those columns for tb3.
I'll make those changes and check this in for you
Comment 10•17 years ago
|
||
changeset: 1528:ba1e5bafe929
http://hg.mozilla.org/comm-central/rev/ba1e5bafe929
New bug for seamonkey, please.
Status: NEW → RESOLVED
Closed: 17 years ago
Component: XUL → Mail Window Front End
Product: Core → Thunderbird
QA Contact: xptoolkit.widgets → front-end
Resolution: --- → FIXED
Target Milestone: --- → Thunderbird 3.0b2
| Reporter | ||
Comment 11•17 years ago
|
||
> New bug for seamonkey, please.
Nonsens, why should I refile my own bug?
Status: RESOLVED → REOPENED
Component: Mail Window Front End → XUL
Product: Thunderbird → Core
Resolution: FIXED → ---
Target Milestone: Thunderbird 3.0b2 → ---
| Reporter | ||
Comment 12•17 years ago
|
||
I don't think the patch is right.
Changing the crop value changes the way the columns get cropped when they become too small. While it is debatable on which side you should crop a number, cropping eg. "Total in Thread" to "...Thread" is not desirable.
Basically, I do think the bug is in the tree column cropping code - cropping and positioning of the ellipsis is done right until all of the text is gone. Only then the ellipsis "jumps" to the wrong position...
Comment 13•17 years ago
|
||
I backed this out due to the unwanted side effects Karsten describes.
changeset: 1529:a554aabedc5d
http://hg.mozilla.org/comm-central/rev/a554aabedc5d
Comment 14•17 years ago
|
||
I don't see a problem here. Ellipsis indicates that a part of a text lacks, and where the ellipsis is positioned shows in which direction it lacks. For example a quote like "...the columns get cropped when they become too small" indicates that there is more text before the citation and "Changing the crop value changes the way..." indicates more text after it. Also the visual effect when I make the place for the text smaller - the ellipsis shows the direction I'm really cropping the text.
| Assignee | ||
Comment 15•17 years ago
|
||
The problem is that mTitleWidth wasn't being set in the case of an early return. I had the choice of two approaches. One of the other cases used a break rather than a return, however this means that it ends up recomputing the ellipse width in the case that it can't get any text at all to fit, so I decided to compute the ellipse width directly into mTitleWidth to allow for both early returns.
I also decided to set mTitleWidth to zero when even the ellipse does not fit inside the width, as that seems to match the behaviour in other cases.
Assignee: pardal → neil
Status: REOPENED → ASSIGNED
Attachment #355054 -
Flags: superreview?(roc)
Attachment #355054 -
Flags: review?(enndeakin)
Comment 16•17 years ago
|
||
Comment on attachment 355054 [details] [diff] [review]
Proposed patch
[Checkin: Comment 23 & 27]
> if (i == length-1)
>- break;
>+ return;
Doesn't this mean that mTitleWidth will be the width of an ellipsis here? Don't you want it to remain the width of the text?
| Assignee | ||
Comment 17•17 years ago
|
||
(In reply to comment #16)
>(From update of attachment 355054 [details] [diff] [review])
>> if (i == length-1)
>>- break;
>>+ return;
>Doesn't this mean that mTitleWidth will be the width of an ellipsis here? Don't
>you want it to remain the width of the text?
No, this is in the left cropping case, and we haven't been able to use any of the characters from the right end of the text. (The right cropping case already has the early return, and it's the incorrect mTitleWidth that causes this bug.)
Comment 18•17 years ago
|
||
Does this patch fix bug 344579?
| Assignee | ||
Comment 19•17 years ago
|
||
(In reply to comment #16)
>(From update of attachment 355054 [details] [diff] [review] [details])
>> if (i == length-1)
>>- break;
>>+ return;
>Doesn't this mean that mTitleWidth will be the width of an ellipsis here? Don't
>you want it to remain the width of the text?
No, this is in the left cropping case, and we haven't been able to use any of
the characters from the right end of the text. (The right cropping case already
has the early return, and it's the incorrect mTitleWidth that causes this bug.)
(In reply to comment #18)
> Does this patch fix bug 344579?
It looks to be a very similar bug.
| Reporter | ||
Comment 20•17 years ago
|
||
| Reporter | ||
Comment 21•17 years ago
|
||
Attachment #355054 -
Flags: superreview?(roc) → superreview+
Updated•17 years ago
|
QA Contact: front-end → xptoolkit.widgets
Comment 22•17 years ago
|
||
(In reply to comment #12)
> I don't think the patch is right.
>
> Basically, I do think the bug is in the tree column cropping code - cropping
> and positioning of the ellipsis is done right until all of the text is gone.
> Only then the ellipsis "jumps" to the wrong position...
You are absolutely right. The real problem here AFAICS is that the ellipsis for text-align=right with crop=end is rendering wrong. For the other cases is right like this testcase demonstrate. I'm marking my patch as OBSOLETE.
But I still thinking the crop for text-align=right should have crop=start, so if someone else agree with this, I could open a new bug and attach that patch to it...
Attachment #354908 -
Attachment is obsolete: true
Updated•17 years ago
|
Attachment #355054 -
Flags: review?(enndeakin) → review+
| Assignee | ||
Comment 23•17 years ago
|
||
Pushed changeset cd085064b5d1 to mozilla-central.
Status: ASSIGNED → RESOLVED
Closed: 17 years ago → 17 years ago
Resolution: --- → FIXED
| Assignee | ||
Updated•17 years ago
|
Attachment #355054 -
Flags: approval1.9.1?
| Assignee | ||
Comment 24•17 years ago
|
||
Comment on attachment 355054 [details] [diff] [review]
Proposed patch
[Checkin: Comment 23 & 27]
Fixes painting issue reproducible easily in trees but also in other cases (see dependent bug). I can write a simpler branch patch if desired.
Updated•17 years ago
|
Target Milestone: --- → mozilla1.9.2a1
Comment 25•17 years ago
|
||
Verified on trunk with the reftest files:
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.2a1pre) Gecko/20090129 Minefield/3.2a1pre ID:20090129020336
Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv:1.9.2a1pre) Gecko/20090129 Minefield/3.2a1pre ID:20090129033611
Can we checkin the reftest too, please?
Status: RESOLVED → VERIFIED
Flags: in-testsuite?
Hardware: x86 → All
Attachment #355054 -
Flags: approval1.9.1? → approval1.9.1+
Comment on attachment 355054 [details] [diff] [review]
Proposed patch
[Checkin: Comment 23 & 27]
a1.9.1=dbaron
| Assignee | ||
Comment 27•17 years ago
|
||
Pushed changeset 772c508564ee to releases/mozilla1.9.1
Keywords: fixed1.9.1
Comment 28•17 years ago
|
||
Verified fixed on 1.9.1 branch with builds on OS X and Windows: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1b3pre) Gecko/20090211 Shiretoko/3.1b3pre Ubiquity/0.1.5 ID:20090211020510
Karsten, were you able to figure out how to get a patch for the reftest?
Keywords: fixed1.9.1 → verified1.9.1
| Reporter | ||
Comment 29•17 years ago
|
||
Attachment #362108 -
Flags: review?
| Reporter | ||
Updated•17 years ago
|
Attachment #362108 -
Flags: review? → review?(roc)
Attachment #362108 -
Flags: review?(roc) → review+
| Reporter | ||
Comment 30•17 years ago
|
||
The longer I stare at the trunk tree, the redder it gets - setting checkin-needed.
Keywords: checkin-needed
Whiteboard: [reftest #362108 needs checkin]
Updated•17 years ago
|
Attachment #354908 -
Attachment description: proposed patch → proposed patch
[Backout: Comment 13]
Updated•17 years ago
|
Attachment #355054 -
Attachment description: Proposed patch → Proposed patch
[Checkin: Comment 23 & 27]
Comment 31•17 years ago
|
||
Comment on attachment 362108 [details] [diff] [review]
reftest as a patch
[Checkin: See comment 33+34+35]
That's the second patch which qimportbz gives me
{
UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position 15: ordinal not in range(128)
}
for :-/
Comment 32•17 years ago
|
||
(In reply to comment #31)
> UnicodeEncodeError: 'ascii' codec can't encode character u'\xfc' in position
> 15: ordinal not in range(128)
Mnyromyr suggested this is triggered by the 'ü' in his name, and he was right: see bug 476994 comment 8.
Nothing wrong with the patch.
Updated•17 years ago
|
Attachment #362108 -
Attachment description: reftest as a patch → reftest as a patch
[Checkin: See comment 33]
Comment 33•17 years ago
|
||
Comment on attachment 362108 [details] [diff] [review]
reftest as a patch
[Checkin: See comment 33+34+35]
http://hg.mozilla.org/mozilla-central/rev/57a0f015a43d
after fixing context for
{
patching file layout/reftests/bugs/reftest.list
Hunk #1 FAILED at 190
1 out of 1 hunks FAILED
}
***
I tried to save the qimportbz patch file as UTF-8,
which looks fine on Windows GUI,
but not in Hg web pages :-/
Updated•17 years ago
|
Flags: in-testsuite? → in-testsuite+
Whiteboard: [reftest #362108 needs checkin] → [needs 1.9.1 landing: reftest #362108] [fixed1.9.1b3]
Comment 34•17 years ago
|
||
Comment on attachment 362108 [details] [diff] [review]
reftest as a patch
[Checkin: See comment 33+34+35]
http://hg.mozilla.org/releases/mozilla-1.9.1/rev/4071ed824459
after fixing (back !?) context for
{
patching file layout/reftests/bugs/reftest.list
Hunk #1 FAILED at 203
1 out of 1 hunks FAILED
}
and removing extra whitespace
Attachment #362108 -
Attachment description: reftest as a patch
[Checkin: See comment 33] → reftest as a patch
[Checkin: See comment 33+34]
Updated•17 years ago
|
Keywords: checkin-needed
Whiteboard: [needs 1.9.1 landing: reftest #362108] [fixed1.9.1b3] → [fixed1.9.1b3]
Comment 35•17 years ago
|
||
Comment on attachment 362108 [details] [diff] [review]
reftest as a patch
[Checkin: See comment 33+34+35]
(In reply to comment #34)
> and removing extra whitespace
http://hg.mozilla.org/mozilla-central/rev/a750a4ebe950
(no bug) Removing ending whitespaces
Attachment #362108 -
Attachment description: reftest as a patch
[Checkin: See comment 33+34] → reftest as a patch
[Checkin: See comment 33+34+35]
You need to log in
before you can comment on or make changes to this bug.
Description
•