Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Making text bold  RSS feed

 
Bilal A.Siddiqui
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi all

I am generating dynamic radiobutton. I want to make the text with radiobutton bold.

my code for generating for radiobutton looks like this


Bold i have defined in my strings.xml as



but the generated text with radio is not coming in bold

 
Monu Tripathi
Rancher
Posts: 1369
1
Android Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Cant you use Typeface.Bold with RadioButton?
 
Bilal A.Siddiqui
Ranch Hand
Posts: 31
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi monu

i have done like this

rb1.setTypeface(null,Typeface.BOLD);

this is making it bold but the colour is not perfect balck, its kind of greyish.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!