I want to calculate string font width in pixels in android. I am having string array and I am appending all these array elements to form one string. so I ha
Thanks Jake for the working solution, yet I found this to work for me too:
someText = "Lorem Ipsum";
TextView myTextView = (TextView) findViewById(R.id.myTextView);
float w = myTextView.getPaint().measureText(someText);
Getting the Paint directly from the TextView that I'm going to work with makes me feel that the anwser will be more accurate.