Want to use a custom font style in flutter? Roboto is the default font of the Material style, there is no need to add it in pubspec.yaml. To use the different variations, set a TextStyle:
1 2 3 4 5 6 7 | Text( 'Home', style: TextStyle( fontWeight: FontWeight.w300, // light fontStyle: FontStyle.italic, // italic ), ); |
If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.