标签:中文 大小 cst nts span ref print tip board
CCDictionary *strings = CCDictionary::createWithContentsOfFile("tips2.xml");const char *hello = ((CCString*)strings->valueForKey("tp1"))->m_sString.c_str();CCLabelTTF *labelHello = CCLabelTTF::create(hello, "fonts/Microsoft YaHei.ttf", 40);labelHello->setPosition(ccp(100, 100));labelHello->setAnchorPoint(ccp(0.5, 0.5));//设置居中对齐labelHello->setHorizontalAlignment(kCCTextAlignmentLeft);labelHello->setPosition(ccp(267,182));//设置显示框大小labelHello->setDimensions(CCSizeMake(500, 200));labelHello->setColor(ccc3(6, 48, 90));pReliveBoard->addChild(labelHello, 1);
标签:中文 大小 cst nts span ref print tip board
原文地址:http://www.cnblogs.com/feizuzu/p/abdd8dcaa1adf81ec4ef96e02ee312e5.html