1.在程序中调用TextView的方法:
setIncludeFontPadding (boolean includepad)
2.或者在xml中加入下句:
android:includeFontPadding="false"
参考:
本文介绍如何通过设置TextView属性来消除字体周围的空白区域。提供两种方法:一种是在程序中调用setIncludeFontPadding方法;另一种是在XML文件中设置android:includeFontPadding属性为false。
1.在程序中调用TextView的方法:
setIncludeFontPadding (boolean includepad)
2.或者在xml中加入下句:
android:includeFontPadding="false"
参考:
1621
1544

被折叠的 条评论
为什么被折叠?