Using font in android app - Forum

Forum Navigation
You need to log in to create posts and topics.

Using font in android app

How can we use a font in the VisualNEO web, that works with android?

I think slLoadGoogleFont command should work for loading Google fonts.
Add it to Project > Events > Start-up

I have tried it, it does not work.

You can also include your own fonts.
Then take a look here:
https://css-tricks.com/snippets/css/using-font-face/

Yes Luishp finally I  have understood it.

This is the way to use custom font in android platform:

step1: add your custom font at =>project=>properties=>Libraries/files

step2: Add the below css code at =>project=>propertis=>Styles

@font-face {
  font-family: "my-font";
  src: url("../fonts/yekan.ttf");         //yekan.ttf is my font.
}

.class-myfont {
   font-family: my-font;
}

 

 

Uploaded files:
  • You need to login to have access to uploads.
luishp, Vadim and 4 other users have reacted to this post.
luishpVadimCDY@44danitojavadrajabihakamiEduardoVolpi
Quote from asmat on October 2, 2019, 8:15 pm

Yes Luishp finally I  have understood it.

This is the way to use custom font in android platform:

step1: add your custom font at =>project=>properties=>Libraries/files

step2: Add the below css code at =>project=>propertis=>Styles

@font-face {
font-family: "my-font";
src: url("../fonts/yekan.ttf"); //yekan.ttf is my font.
}
.class-myfont {
font-family: my-font;
}
@font-face { font-family: "my-font"; src: url("../fonts/yekan.ttf"); //yekan.ttf is my font. } .class-myfont { font-family: my-font; }
@font-face {
  font-family: "my-font";
  src: url("../fonts/yekan.ttf");         //yekan.ttf is my font.
}

.class-myfont {
   font-family: my-font;
}

 

 

Thanks for the example @asmat . It works perfectly;

@eduardovolpi @asmat next version will include a simple to use AddFont command that will make unnecesary both steps.
Best regards.

javadrajabihakami and EduardoVolpi have reacted to this post.
javadrajabihakamiEduardoVolpi
Quote from luishp on December 21, 2021, 9:15 am

@eduardovolpi @asmat next version will include a simple to use AddFont command that will make unnecesary both steps.
Best regards.

Nice!