//我正在设置具有各种内容的不同TextView作为文本我正在做的是为所有textview设置字体。自定义字体也显示正常。
((TextView) findViewById (R.id.tutor_ps_tv_home)) .setTypeface(mFace);
((TextView) findViewById (R.id.tutor_ps_tv_plus)) .setTypeface(mFace);
((TextView) findViewById (R.id.tutor_ps_tv_settings)) .setTypeface(mFace);
((TextView) findViewById (R.id.tutor_ps_tv_undo)) .setTypeface(mFace);
((TextView) findViewById (R.id.tutor_ps_tv_cam)) .setTypeface(mFace);
((TextView) findViewById (R.id.tutor_ps_tv_share)) .setTypeface(mFace);
//是否可以为所有文本视图仅设置一个 id 来更改我的字体,如下所示。
android:id="@+id/all_textview"
android:id="@id/all_textview"
android:id="@id/all_textview"
android:id="@id/all_textview"
//我将在我的活动中设置为
((TextView) findViewById (R.id.all_textview)) .setTypeface(mFace);
// 有没有人知道更好的解决方案。
注意:我只想更改字体而不是其他任何东西/与 textview 一起使用。