android - Font issue in TextView -


I have a TextView that contains only one letter I Text size is calibrated so that the letter is the whole text view area Could stay in Now one of my users has reported a problem that the letter is not properly fit in the TextView. From the attached screenshot I can see that he uses some custom fonts on his Samsung S4 device. I'm sure the problem is here some snapshots are given:

Custom font in a TextView on ImageView:

custom font example on text view

custom font in the status bar :

Example of custom font in the status bar

My TextView Distorted letters in N:

Is there any way to use TextView to use standard Android fonts Ignore any custom fonts that apply to the user? How can I install custom fonts on the emulator or Sony phone (not Samsung) and repeat the behavior? You can set custom fonts in your app.

  1. Create a folder named fonts under the folder folder and put all your fonts in it (font format ttc or ttf. Can be anything in the name of the folder)
  2. < P> Add code below the CREATE method inside you.
      TextViewMyTeXview = (TextView) SearchVBIID (RED.text_view_ID); // loading font face Rename your font file typeface tf = Typeface.createFromAsset (getAssets (), "fonts / your_custom_font.ttf"); // apply mytextview.setTypeface (tf);  
  3. In the same way, the typeface you may need is as much as you can and the same typeface can be used as much as you want for textview. .

    This tutorial below tells you your requirement and also provides screenshots for better assistance.

    Apart from this, please note that there are many other options in the typeface which you can play with.

    I hope that will help you.

    Thank you!

Comments

Popular posts from this blog

php - PDO bindParam() fatal error -

logging - How can I log both the Request.InputStream and Response.OutputStream traffic in my ASP.NET MVC3 Application for specific Actions? -

java - Why my included JSP file won't get processed correctly? -