• Post Reply Bookmark Topic Watch Topic
  • New Topic

Font change in jtree renderer  RSS feed

 
s Subrjohn
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
HI, I found this multiline Jtree node code in one of this forum, thanks to boris.

However, I made few changes to integrate into my code. The only thing I'm unable to change is it's font. It is taking "javax.swing.plaf.FontUIResource[family=Tahoma,name=Tahoma,style=plain,size=11] "

I tried several things but nothing worked and I thought of giving it a try here. Any help or suggestion would be greatly appreciated.





thanks for the help inadvance
 
Bin Smith
Ranch Hand
Posts: 514
1
Eclipse IDE Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In your renderer MyCellRenderer set font in constructor by calling super.setFont
 
Campbell Ritchie
Sheriff
Posts: 55351
157
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
…and welcome to the Ranch
 
s Subrjohn
Greenhorn
Posts: 2
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

thanks, I already tried it but didn't work

 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!