1.update lua binding configuration for label.

2.recover old method[createWithTTF]
This commit is contained in:
Dhilan007 2014-01-13 16:32:35 +08:00
parent b2038d14d6
commit fd481d64a0
3 changed files with 7 additions and 1 deletions

View File

@ -66,6 +66,12 @@ Label* Label::createWithTTF(const TTFConfig& ttfConfig, const std::string& text,
}
}
Label* Label::createWithTTF(const std::string& text, const std::string& fontFilePath, int fontSize, int lineSize /* = 0 */, TextHAlignment alignment /* = TextHAlignment::CENTER */, GlyphCollection glyphs /* = GlyphCollection::NEHE */, const char *customGlyphs /* = 0 */, bool useDistanceField /* = false */)
{
TTFConfig ttfConfig(fontFilePath.c_str(),fontSize,glyphs,customGlyphs,useDistanceField);
return createWithTTF(ttfConfig,text,alignment,lineSize);
}
Label* Label::createWithBMFont(const std::string& bmfontFilePath, const std::string& text,const TextHAlignment& alignment /* = TextHAlignment::CENTER */, int lineSize /* = 0 */)
{
Label *ret = new Label();

View File

@ -77,6 +77,7 @@ class CC_DLL Label : public SpriteBatchNode, public LabelProtocol, public LabelT
public:
static Label* create();
CC_DEPRECATED_ATTRIBUTE static Label* createWithTTF(const std::string& label, const std::string& fontFilePath, int fontSize, int lineSize = 0, TextHAlignment alignment = TextHAlignment::CENTER, GlyphCollection glyphs = GlyphCollection::NEHE, const char *customGlyphs = 0, bool useDistanceField = false);
static Label* createWithTTF(const TTFConfig& ttfConfig, const std::string& text, TextHAlignment alignment = TextHAlignment::CENTER, int lineWidth = 0);
static Label* createWithBMFont(const std::string& bmfontFilePath, const std::string& text,const TextHAlignment& alignment = TextHAlignment::CENTER, int lineWidth = 0);

View File

@ -108,7 +108,6 @@ skip = Node::[setGLServerState description getUserObject .*UserData getGLServerS
ccFontDefinition::[*],
Object::[autorelease isEqual acceptVisitor update],
UserDefault::[getInstance (s|g)etDataForKey],
Label::[getLettersInfo],
EGLViewProtocol::[setTouchDelegate],
EGLView::[end swapBuffers],
NewTextureAtlas::[*],