This question is locked. New answers and comments are not allowed.
Hi,
I am trying to add Roboto font to my iOS app.
As read I have to use the name of the font not the path name.
So my font is inserted in app\fonts\Roboto-Regular.ttf
As I checked with Font Book the name is "Roboto"
In my app I have in the app.css file
Label
{
font-family:Roboto ;
}
But it seems not apply to the Label .
I have tried also this example, which also doesn't work for me .
https://github.com/NickIliev/NS-Issues/tree/master/stackoverflow/robotoFont/app
4 Answers, 1 is accepted
0
Accepted
Hi Dimitar,
Thank you for contacting us.
I tested your case with using a custom font in the project while using the latest NativeScript 3.3, however, was unable to recreate an issue while building it for iOS.
For your convenience, I am attaching sample project and Gif file, which demonstrates that the font is applied properly. In the project, I set up the font family, while using the font name.
Regarding the attached project in your comment, I notice that the application refers NativeScript 2.5. I would recommend testing the same case with the latest version of NativeScript
Regards,
nikolay.tsonev
Progress Telerik
Thank you for contacting us.
I tested your case with using a custom font in the project while using the latest NativeScript 3.3, however, was unable to recreate an issue while building it for iOS.
For your convenience, I am attaching sample project and Gif file, which demonstrates that the font is applied properly. In the project, I set up the font family, while using the font name.
Regarding the attached project in your comment, I notice that the application refers NativeScript 2.5. I would recommend testing the same case with the latest version of NativeScript
Regards,
nikolay.tsonev
Progress Telerik
Did you know that you can open private support tickets which are reviewed and answered within 24h by the same team who built the components? This is available in our UI for NativeScript Pro + Support offering.
0

Dimitar
Top achievements
Rank 1
answered on 20 Dec 2017, 08:30 AM
Hi ,
Thanks Nikolay. Its working now.
How I could implement Robot-Regular , Bold, etc. for iOS . I have tried with font-weight and font style but didn't succeed .
0
Hello Dimitar,
You should add in the font folder the ttf files, which corresponds to the Bold font weight in the fonts folder. For example in your case, you should also copy Roboto-Bold file inside the folder.
Then you should be able to setup the font-weight property in the CSS file. I am attaching sample project and Screenshot from the simulator.
Regards,
nikolay.tsonev
Progress Telerik
You should add in the font folder the ttf files, which corresponds to the Bold font weight in the fonts folder. For example in your case, you should also copy Roboto-Bold file inside the folder.
Then you should be able to setup the font-weight property in the CSS file. I am attaching sample project and Screenshot from the simulator.
Regards,
nikolay.tsonev
Progress Telerik
Did you know that you can open private support tickets which are reviewed and answered within 24h by the same team who built the components? This is available in our UI for NativeScript Pro + Support offering.
0

Dimitar
Top achievements
Rank 1
answered on 20 Dec 2017, 02:11 PM
Hi, thank you . It's work now