I am following an example project "Sky" by Jeff Sharkey using styles in my layout. It is working out quite well, however, I cannot determine how to specify the font type-face using the styles. Without this, I will have to apply the font explicitly to every TextView, EditView, etc., whereas I want to control where and when it is applied throughout my application.
Asked
Active
Viewed 807 times
2 Answers
0
It seems that it is not possible from xml/styles... You can only specify it from java code. check here if you are interesting.
-
That was my conclusion after some dialog with my colleagues -- but I was hoping for a clean solution without modifying the kernel :) – mobibob Jul 27 '10 at 15:14
0
You can do this by creating your own textview class and use that in your layouts.
Inside your new custom class, set the font you want.
Et voila!

Richard Lalancette
- 2,401
- 24
- 29