我希望能够使 TextView 粗体。这就是我设置它的外观的方式(我需要在代码中这样做):
nameText.setTextAppearance(getApplicationContext(), R.style.BlueText);
priceText.setTextAppearance(getApplicationContext(), R.style.BlueText);
changeText.setTextAppearance(getApplicationContext(), R.style.BlueText);
这是我的 style.xml
<!-- Blue Color -->
<style name="BlueText">
<item name="android:textColor">#4871A8</item>
</style>
如何确保我的 TextView 是粗体的?