企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持知识库和私有化部署方案 广告
# 1. 字体加粗 ## 1.1 直接通过xml方式 ~~~ android:textStyle="bold" ~~~ ## 1.2 非xml方式 ``` TextView textView = (TextView)findViewById(R.id.text_view); //设置为加粗 textView .setTypeface(Typeface.defaultFromStyle(Typeface.BOLD)); //设置为不加粗 textView.setTypeface(Typeface.defaultFromStyle(Typeface.NORMAL)); ```