xuncl / cocos2d-android

Automatically exported from code.google.com/p/cocos2d-android
Other
0 stars 0 forks source link

Usage of Custom Fonts #28

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I tried to use a custom font, which I added to my assets. Usualy that's not a 
big deal, since I can create a Typeface object and just use that.
But when using the Menu and MenuItemFont classes I just didn't find a way to 
pass a Typeface object. I can only pass a String with the name of the font, 
which will only load the default fonts installed on any device.
Solving this problem would be rather easy, since you just need to add a few 
constructors starting at Texture2D, which use a Typeface object instead of the 
String.

Greetings, AlwaysSpam

Original issue reported on code.google.com by florian....@gmail.com on 4 Feb 2011 at 4:13

GoogleCodeExporter commented 9 years ago
Hello, If you found any solution can you please tell me cause i am having this 
issue and stuck with this thank you,

This is how i am trying to use it
currentVideoLabel = CCLabel.makeLabel(VideosLabels[currentSelected], 
"Faraco_Hand.ttf", winSize.width/41);
        currentVideoLabel.setPosition(CGPoint.make(winSize.width/2, 20));
        addChild(currentVideoLabel);

Original comment by omer.abb...@gmail.com on 9 Jun 2012 at 3:14