NTP snippets: Ellipsize long publisher names on cards |
||||||||||
Issue descriptionAt the moment we concatenate the publisher name with the date, which results in the whole string being ellipsized at the end if the publisher is very long. We should instead make sure that the publisher is ellipsized but the date stays full width.
,
Jul 11 2016
,
Jul 18 2016
,
Jul 19 2016
It may be a good idea to change from a single TextView that we format to '<publisher> - <timestamp>' to three separate TextViews. This would let Android take care of the ellipsis' and simplify a few other special cases (eg when the publisher is in a LTR language but the device is RTL). Do make sure you test with an RTL layout.
,
Jul 25 2016
Propose to Rachel if we could right align the publisher date as this will massively simplify the code and remove the need for java to manipulate and pre render to measure if there is space
,
Aug 1 2016
,
Aug 12 2016
,
Aug 16 2016
@mvanouwerkerk: What's the latest status here? Was this ever fixed? Or is it obsolete (I didn't check what the current behavior is)?
,
Aug 16 2016
I looked into it with Nicole when she was working on this. I think we could fix this by subclassing a LinearLayout or something like that, but she wasn't very keen on that. That's the latest. I have never seen this problem with production data, it's just something that came up with artificially long strings. P3 seems about right.
,
Aug 19 2016
ok. sgtm.
,
Aug 19 2016
What currently happens when we have a long publisher name?
,
Aug 19 2016
Ah, scratch that - I see this noted at the top of the bug. This is pretty non-ideal. Do we have an idea of how often it happens?
,
Aug 19 2016
I've never seen this in the real world - it was just an edge case I thought of while making tests.
,
Aug 22 2016
OK, thanks Pete. P3 seems good then.
,
Dec 15 2016
,
Apr 4 2017
,
Apr 19 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/1611b2644697ca7bc868e9a68bf28dd15619d250 commit 1611b2644697ca7bc868e9a68bf28dd15619d250 Author: galinap <galinap@google.com> Date: Wed Apr 19 12:43:40 2017 Fixed ellipsize of publisher instead of timespan string. Screenshots here: https://drive.google.com/drive/folders/0B7eRCSITD4qmYl9MbDRWWFFBZGs?usp=sharing BUG= 625775 Review-Url: https://codereview.chromium.org/2808773002 Cr-Commit-Position: refs/heads/master@{#465564} [modify] https://crrev.com/1611b2644697ca7bc868e9a68bf28dd15619d250/chrome/android/java/res/layout/new_tab_page_snippets_card.xml [modify] https://crrev.com/1611b2644697ca7bc868e9a68bf28dd15619d250/chrome/android/java/src/org/chromium/chrome/browser/ntp/snippets/SnippetArticleViewHolder.java
,
Apr 19 2017
|
||||||||||
►
Sign in to add a comment |
||||||||||
Comment 1 by nepper@chromium.org
, Jul 8 2016