Last Comment Bug 666842 - Use an ellipsis for long tab names in Panorama
: Use an ellipsis for long tab names in Panorama
Status: VERIFIED FIXED
[inbound]
:
Product: Firefox Graveyard
Classification: Graveyard
Component: Panorama (show other bugs)
: unspecified
: All All
: -- minor
: Firefox 7
Assigned To: Patrick Walton (:pcwalton)
:
Mentors:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-06-23 21:49 PDT by Patrick Walton (:pcwalton)
Modified: 2016-04-12 14:00 PDT (History)
5 users (show)
See Also:
QA Whiteboard:
Iteration: ---
Points: ---


Attachments
Proposed patch. (1.70 KB, patch)
2011-06-23 21:49 PDT, Patrick Walton (:pcwalton)
dao+bmo: review-
Details | Diff | Splinter Review
Proposed patch, version 2. (554 bytes, patch)
2011-06-25 18:11 PDT, Patrick Walton (:pcwalton)
no flags Details | Diff | Splinter Review
Proposed patch, version 3. (2.11 KB, patch)
2011-06-26 00:44 PDT, Patrick Walton (:pcwalton)
dao+bmo: review+
Details | Diff | Splinter Review
Proposed patch, version 4. (2.25 KB, patch)
2011-06-26 00:48 PDT, Patrick Walton (:pcwalton)
no flags Details | Diff | Splinter Review

Description Patrick Walton (:pcwalton) 2011-06-23 21:49:58 PDT
Created attachment 541600 [details] [diff] [review]
Proposed patch.

Now that text-overflow: ellipsis has landed, this is trivial. We can simply trim long tab names in Panorama with an ellipsis.
Comment 1 Dão Gottwald [:dao] 2011-06-23 22:06:46 PDT
Comment on attachment 541600 [details] [diff] [review]
Proposed patch.

This belongs in browser/base/content/tabview/tabview.css.

> .tab-title {
>   top: 100%;
>   text-align: center;
>   width: 94.5%;
>   white-space: nowrap;
>   overflow: hidden;
>+  text-overflow: ellipsis;
> }

Is overflow:hidden still needed?
Comment 2 Tim Taubert [:ttaubert] 2011-06-24 02:16:14 PDT
We should watch out for bug 666669 as this might pref off "text-overflow: ellipsis" for Fx 7.
Comment 3 Patrick Walton (:pcwalton) 2011-06-25 18:11:45 PDT
Created attachment 541974 [details] [diff] [review]
Proposed patch, version 2.

Patch version 2 moves the text-overflow to browser/base/content/tabview.css.

The overflow: hidden is indeed still needed.
Comment 4 Dão Gottwald [:dao] 2011-06-25 23:30:32 PDT
(In reply to comment #3)
> The overflow: hidden is indeed still needed.

What is it needed for?
Comment 5 Patrick Walton (:pcwalton) 2011-06-26 00:33:21 PDT
(In reply to comment #4)
> (In reply to comment #3)
> > The overflow: hidden is indeed still needed.
> 
> What is it needed for?

To prevent the tab name from overflowing its bounds. text-overflow only specifies what to do if overflow occurs, not whether to do overflow. See MDC docs:

https://developer.mozilla.org/En/CSS/text-overflow
Comment 6 Dão Gottwald [:dao] 2011-06-26 00:42:38 PDT
It should be in content CSS along with text-overflow, then.
Comment 7 Patrick Walton (:pcwalton) 2011-06-26 00:44:29 PDT
Created attachment 541997 [details] [diff] [review]
Proposed patch, version 3.

Patch version 3 moves overflow.
Comment 8 Dão Gottwald [:dao] 2011-06-26 00:46:43 PDT
Comment on attachment 541997 [details] [diff] [review]
Proposed patch, version 3.

>   white-space: nowrap;

This too.
Comment 9 Patrick Walton (:pcwalton) 2011-06-26 00:48:47 PDT
Created attachment 541998 [details] [diff] [review]
Proposed patch, version 4.

Patch version 4 moves white-space too.
Comment 10 Dão Gottwald [:dao] 2011-06-26 23:42:11 PDT
*** Bug 589132 has been marked as a duplicate of this bug. ***
Comment 11 Patrick Walton (:pcwalton) 2011-06-27 11:15:57 PDT
http://hg.mozilla.org/integration/mozilla-inbound/rev/622f3e5f6c17
Comment 12 Marco Bonardo [::mak] (Away 6-20 Aug) 2011-06-28 02:25:32 PDT
http://hg.mozilla.org/mozilla-central/rev/622f3e5f6c17
Comment 13 George Carstoiu 2011-07-07 05:47:31 PDT
Mozilla/5.0 (X11; Linux i686; rv:7.0a2) Gecko/20110706 Firefox/7.0a2

Verified issue on Ubuntu 11.04 x86, WinXP, Mac OS X 10.6, Win7 x86 and long website titles are no longer truncated but instead the ellipsis is shown.

Setting status Verified Fixed.

Note You need to log in before you can comment on or make changes to this bug.