android:textAppearance

 

xml布局里面设置文字的外观:

如“android:textAppearance=“?android:attr/textAppearanceLargeInverse”这里引用的是系统自带的一个外观,

?表示系统是否有这种外观,否则使用默认的外观。

可设置的值如下:

textAppearanceButton/  Android之系统自带的文字外观设置及实际显示效果图

 

textAppearanceInverse/  Android之系统自带的文字外观设置及实际显示效果图

 

 

textAppearanceLarge/  Android之系统自带的文字外观设置及实际显示效果图

 

textAppearanceLargeInverse/ Android之系统自带的文字外观设置及实际显示效果图


textAppearanceMedium/    Android之系统自带的文字外观设置及实际显示效果图

 

textAppearanceSmallInverse/ Android之系统自带的文字外观设置及实际显示效果图

 

textAppearanceMediumInverse/ Android之系统自带的文字外观设置及实际显示效果图
 
textAppearanceSmall/  Android之系统自带的文字外观设置及实际显示效果图
 
代码中加下划线
textView.getPaint().setFlags(Paint. UNDERLINE_TEXT_FLAG ); //下划线
textView.getPaint().setAntiAlias(true);//抗锯齿

相关文章:

  • 2021-11-30
  • 2022-12-23
  • 2021-10-25
  • 2021-05-04
  • 2022-02-04
  • 2021-05-12
  • 2021-06-09
猜你喜欢
  • 2021-09-26
  • 2022-12-23
  • 2021-06-05
  • 2021-08-04
  • 2022-12-23
  • 2021-04-14
  • 2021-11-18
相关资源
相似解决方案