Fixed
Status Update
Comments
jb...@google.com <jb...@google.com> #2
This issue is assigned to an engineer for further evaluation
so...@gmail.com <so...@gmail.com> #3
same issue, I never could get a TextView with more than 2 lines ellipsized :(
al...@gmail.com <al...@gmail.com> #4
Hello. Can we get someone to fix this? The issue has been pending for more than 1 year.
sh...@gmail.com <sh...@gmail.com> #5
Please fix this.
kl...@gmail.com <kl...@gmail.com> #6
We have troubled with this problem, too.
kl...@gmail.com <kl...@gmail.com> #7
Ahha, someone has solved it with a custom view, this is the code: http://code.google.com/p/android-textview-multiline-ellipse/.Thanks .
But this project does not support chinese processing,I do it,and attchment is my code.
But this project does not support chinese processing,I do it,and attchment is my code.
al...@gmail.com <al...@gmail.com> #8
I have faced the same issue. Kli.java offered good solution but very slow, I mean we can not use this custom textview in listview`s items, it takes really much time to break text in lines with specified width. So I`ve changed the code, now it uses native Paint.breakText function to braek text in lines(but breaks in the middle of a word). If you need to have "fast" breakText version which will save words(don`t break them in the middle) you should implement native function. I implemented one. Though is it really difficult to fix this 1 year issue?
dk...@gmail.com <dk...@gmail.com> #9
still not fixed..
re...@gmail.com <re...@gmail.com> #10
it's amazing this is still not changed.
Thanks Kli and alexey.ponkin, your solution really helped out!
Thanks Kli and alexey.ponkin, your solution really helped out!
ru...@gmail.com <ru...@gmail.com> #11
BUMP BUMP!
This needs to be fixed.
This needs to be fixed.
to...@gmail.com <to...@gmail.com> #12
Yeah, I need a three line textview with '...' at the end and it gets truncated to only two lines with ellipsize
re...@gmail.com <re...@gmail.com> #13
Still having the same issue with it
da...@gmail.com <da...@gmail.com> #14
In addition to the noted truncation issues forcing the TextView to a maximum of 2 lines, the value set on the android:ellipsize attribute is ONLY applied to the last line when the view is 2 lines instead of one. For instance, if the TextView has android:ellipsize="start" set, the ellipsis will be drawn at the start of line 2, not at the start of the entire text String.
st...@gmail.com <st...@gmail.com> #15
It's a shame that this small but annoying bug is still open... Fix it please!!!
If not I will immediately start developing iOS by tomorrow, there you are!
If not I will immediately start developing iOS by tomorrow, there you are!
[Deleted User] <[Deleted User]> #16
Why this bug is still there. This is a really annoying issue.
zu...@gmail.com <zu...@gmail.com> #17
This is still causing problems. PLEASE FIX THIS!
ja...@gmail.com <ja...@gmail.com> #18
This really needs to be fixed. Thanks.
k7...@gmail.com <k7...@gmail.com> #19
This needs to be fix!
ya...@gmail.com <ya...@gmail.com> #20
Please fix this issue, it appears also in widgets
gg...@gmail.com <gg...@gmail.com> #21
alexey.ponkin's solution works,thank!
ya...@gmail.com <ya...@gmail.com> #22
How to add alexey.ponkin's text view to an app widget?
ma...@gmail.com <ma...@gmail.com> #23
pls fix it.
ya...@gmail.com <ya...@gmail.com> #24
And in android 2.3.2 it becomes one line only ...
l....@gmail.com <l....@gmail.com> #25
Only works with 2 lines, I've need 4 lines and doesn´t work, please fix it.
my...@gmail.com <my...@gmail.com> #26
please fix it, it only works with up to 2 lines.
fr...@gmail.com <fr...@gmail.com> #27
fix it!
ju...@gmail.com <ju...@gmail.com> #28
Come on, fix it!
va...@gmail.com <va...@gmail.com> #29
opened since March, 2009 and still not fixed? Come on... :)
mo...@gmail.com <mo...@gmail.com> #30
I'm surprised that this hasn't been fixed, over 2 years..
[Deleted User] <[Deleted User]> #31
They must come up with the solution or must notify the users that they are not going to fix it
ha...@gmail.com <ha...@gmail.com> #32
哎~,真郁闷
mi...@gmail.com <mi...@gmail.com> #33
Here's a workaround solution. Feel free to use it freely without attribution, or under the Apache license (whichever you prefer).
me...@gmail.com <me...@gmail.com> #34
Micah, it doesn't works to me. When resetText() is called getMaxLines() returns -1 somehow.
mi...@gmail.com <mi...@gmail.com> #35
You just have to call setMaxLines for this code to work, or just adapt it to your needs. For further comments or questions on this code, let's use stackoverflow (http://stackoverflow.com/questions/2160619/android-ellipsize-multiline-textview/5504572#5504572 ) so as to avoid emailing everyone on this list.
ge...@gmail.com <ge...@gmail.com> #36
Yikes; this is pretty glaringly annoying, and I hope it gets fixed someday. Having to do custom code to fix ellipses is not a good use of my time :-/
mo...@gmail.com <mo...@gmail.com> #37
Be warned that the solution posted above has several defects. All xml-attributes does not work. It does not ellipsize languages that does not have "space", like chinese. And it will screw up boldness and such stuff on the string. Please fix the googlor ;_;
ak...@gmail.com <ak...@gmail.com> #38
Please fix this issue!
fd...@gmail.com <fd...@gmail.com> #39
Could you please fix this?! Most anoying bug ever ...
ca...@gmail.com <ca...@gmail.com> #40
It's been almost 3 years and no news about this bug. Its annoying
al...@gmail.com <al...@gmail.com> #41
Even if this bug is fixed, until you want to drop support for older Androids (including Ice cream sandwich IIUC), you'll have to use a workaround.
Check outhttps://github.com/triposo/barone/blob/master/src/com/triposo/barone/EllipsizingTextView.java
It calculates automatically the maximum number of fully visible lines (when the size or padding changes) and adds ellipsis on the last line if the text does not fit.
Feedback welcome (there, not here). Contributions also. Thanks.
Check out
It calculates automatically the maximum number of fully visible lines (when the size or padding changes) and adds ellipsis on the last line if the text does not fit.
Feedback welcome (there, not here). Contributions also. Thanks.
ro...@android.com <ro...@android.com>
ly...@gmail.com <ly...@gmail.com> #42
it fixed in 4.0.4 at my test.but I hadn't test other ics branch.
lu...@gmail.com <lu...@gmail.com> #43
Only solution from comment 43 worked for me. Thanks man!
la...@gmail.com <la...@gmail.com> #44
Yes but 43 won't work for TextView in widgets
em...@gmail.com <em...@gmail.com> #45
#43 doesn't work for me in Android-8
<com.example.androidtest.EllipsizingTextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="ssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss"/>
<com.example.androidtest.EllipsizingTextView
android:id="@+id/textView1"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="ssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssssss"/>
ma...@gmail.com <ma...@gmail.com> #46
FUCK! Why isn't it corrected untill today?
je...@gmail.com <je...@gmail.com> #47
[Comment deleted]
je...@gmail.com <je...@gmail.com> #48
Plz fix it :S so disappointed...
al...@gmail.com <al...@gmail.com> #49
The status of the bug is FutureRelease, which means it's already fixed.
Anyway, if you want to support older Android versions (including JellyBeans) you have to use a workaround, seehttps://github.com/triposo/barone/blob/master/src/com/triposo/barone/EllipsizingTextView.java which can display non-HTML text and ellipsize it properly. (If you have comments, reply on github, not here. If you have other workarounds, tell us about them.)
Anyway, if you want to support older Android versions (including JellyBeans) you have to use a workaround, see
al...@gmail.com <al...@gmail.com> #50
Which is the first Android release with the fix?
[Deleted User] <[Deleted User]> #51
very odd, still not fixed.
ri...@instinctmedia.in <ri...@instinctmedia.in> #52
Still not fixed in 2017
la...@gmail.com <la...@gmail.com> #53
so, you guys are so busy....
te...@mifors.com <te...@mifors.com> #54
Видать ребята очень заняты
hi...@gmail.com <hi...@gmail.com> #55
holy ……
ma...@gmail.com <ma...@gmail.com> #56
8 years
m1...@gmail.com <m1...@gmail.com> #57
teeeeeeeeeeeeeeeeeeeeeee...
[Deleted User] <[Deleted User]> #58
Not fixed in TextView or AppCompatTextView yet
[Deleted User] <[Deleted User]> #60
sorry for the double post on the workaround :-(
el...@gmail.com <el...@gmail.com> #61
still not fixed and it's almost 2019.
This is just getting really really really really sad.
Thanks, Google
This is just getting really really really really sad.
Thanks, Google
na...@gmail.com <na...@gmail.com> #62
I don't think this will get fixed in Android or AndroidX.
li...@addcn.com <li...@addcn.com> #63
why not fix?
mi...@gmail.com <mi...@gmail.com> #65
Android is the worst.
mi...@gmail.com <mi...@gmail.com> #66
Full 10+ years this shit sits here and is not fixed.
ge...@gmail.com <ge...@gmail.com> #67
Why isn't this fixed yet?
co...@gmail.com <co...@gmail.com> #68
I've found that using ConstraintLayout with start and end bounds setup plus layout_width="0dp" sees the ellipses for multiline TextView. A solution for AppWidget remains at large.
an...@gmail.com <an...@gmail.com> #69
Why isn't this fixed yet?
da...@coffeeit.nl <da...@coffeeit.nl> #70
Please fix.
se...@kurlycorp.com <se...@kurlycorp.com> #71
Please fix. In 2023
Description
truncated to two lines, irrespective of the line count or size of the text
view. More than 2 lines should be displayed if the layout size permits.
To repeat this, use the following XML as the main layout for a default app:
<?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="
android:orientation="vertical"
android:layout_width="fill_parent"
android:layout_height="fill_parent"
>
<TextView
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="This is a repeat This is a repeat This is a repeat This
is a repeat This is a repeat This is a repeat This is a repeat This is a
repeat This is a repeat This is a repeat This is a repeat This is a repeat
This is a repeat This is a repeat This is a repeat This is a repeat This is
a repeat This is a repeat This is a repeat This is a repeat This is a
repeat This is a repeat This is a repeat This is a repeat This is a repeat
This is a repeat This is a repeat This is a repeat This is a repeat This is
a repeat This is a repeat This is a repeat This is a repeat This is a
repeat This is a repeat This is a repeat This is a repeat This is a repeat
This is a repeat This is a repeat This is a repeat This is a repeat This is
a repeat This is a repeat This is a repeat This is a repeat This is a
repeat This is a repeat This is a repeat This is a repeat This is a repeat
This is a repeat This is a repeat This is a repeat This is a repeat This is
a repeat This is a repeat This is a repeat This is a repeat This is a
repeat This is a repeat "
android:ellipsize="end"
android:minLines="3"
android:maxLines="4"
/>
</LinearLayout>