Skip to content

Conversation

@samskiter
Copy link
Contributor

Tested on a Nexus 5 running lollipop with a variety of texts in a textview.

@AndroidDeveloperLB
Copy link
Owner

Can you please show me a screenshot or something, of the issue itself? or a way to reproduce it?
Also, sadly, this doesn't seem to fix the issue I've found and written about, that the last letter of the current line can go to the next line.

@samskiter
Copy link
Contributor Author

@AndroidDeveloperLB Appologies for not being clear, this relates to the issue i raised about text not filling: #11

The other issue i raised (#12), i think contains a solution to your other problem.

I'll try and get you a screenshot of the issue. But basically, the text is coming out far smaller than it could be on a square-ish textview. I'll probably also have to test on another device with an older version of android.

Could you try this and see if it breaks anything your end?

@samskiter
Copy link
Contributor Author

Before:
https://www.dropbox.com/s/rty07vxwmngvxsa/text_before.png?dl=0
After (with this fix applied):
https://www.dropbox.com/s/kmeg2vhejyz09eo/text_after.png?dl=0

Note that both textviews have some padding but similar results are observed without the padding. (In fact that was the situation I found this in)

@AndroidDeveloperLB
Copy link
Owner

I'm not sure what has happened here. You've create 3 thread about one issue? why didn't you just write it on the same thread?
The code you've written is the same as what you are suggesting here, and I've still noticed the issue I've written about.
Anyway, I'll now merge the pull request. Thank you for contributing.

AndroidDeveloperLB added a commit that referenced this pull request Feb 26, 2015
Fixed line width measuring
@AndroidDeveloperLB AndroidDeveloperLB merged commit a71ebe7 into AndroidDeveloperLB:master Feb 26, 2015
@samskiter
Copy link
Contributor Author

#12 Is about casting a float to int. I think that may fix your other issue. If you can reliably reproduce it, I could make you an MR to try out?

On the other hand, this MR is about using a different API to measure line widths - I wouldn't expect it to fix your other issue.

The approach on Github is generally to have one MR per issue. If for example, this MR caused a bug, we'd still have the issue open to track the problem.

Thanks for merging :)

@AndroidDeveloperLB
Copy link
Owner

ok, here's the issue I'm talking about:
#15

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants