mirror of https://github.com/axmolengine/axmol.git
fixed can's set color for LabelTTF correctly on IOS.
This commit is contained in:
parent
bf1ec7d463
commit
6e2caf1c78
|
@ -348,7 +348,7 @@ static bool _initWithString(const char * text, cocos2d::Device::TextAlign align,
|
||||||
}
|
}
|
||||||
|
|
||||||
// text color
|
// text color
|
||||||
CGContextSetRGBFillColor(context, info->tintColorR, info->tintColorG, info->tintColorB, 1);
|
CGContextSetRGBFillColor(context, info->tintColorR / 255.0f, info->tintColorG / 255.0f, info->tintColorB / 255.0f, 1);
|
||||||
// move Y rendering to the top of the image
|
// move Y rendering to the top of the image
|
||||||
CGContextTranslateCTM(context, 0.0f, (dim.height - shadowStrokePaddingY) );
|
CGContextTranslateCTM(context, 0.0f, (dim.height - shadowStrokePaddingY) );
|
||||||
CGContextScaleCTM(context, 1.0f, -1.0f); //NOTE: NSString draws in UIKit referential i.e. renders upside-down compared to CGBitmapContext referential
|
CGContextScaleCTM(context, 1.0f, -1.0f); //NOTE: NSString draws in UIKit referential i.e. renders upside-down compared to CGBitmapContext referential
|
||||||
|
|
Loading…
Reference in New Issue