Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Trusted Contributor
Posts: 102
Registered: ‎03-01-2010
My Device: 8310
My Carrier: Ingenieur

setfont for tree field

Hi;

 

 

I have a tree view in my screen and i want to change its size:

 

i  declare this :

FontFamily fontFamily[] = FontFamily.getFontFamilies();
    Font font2 = fontFamily[1].getFont(FontFamily.CBTF_FONT, 12);

 

and i have _mytree= _myTree = new TreeField(_myCallback, TreeField.FOCUSABLE)
  
when i put  _mytree.setfont(font1);

 

it show me an exception illegalArguments!!!!

what the problem i must change its size because it look full and not organized

any idea ????

 

thank in advance ;;

Developer
Posts: 484
Registered: ‎07-17-2008
My Device: Not Specified

Re: setfont for tree field

font1 is not defined in your code snippet.