mirror of https://github.com/axmolengine/axmol.git
Fix TTFconfig construct with nullable customGlyphCollection
This commit is contained in:
parent
6b70fc5ff3
commit
7110de393a
|
@ -66,7 +66,7 @@ typedef struct _ttfConfig
|
||||||
_ttfConfig(std::string_view filePath = {},
|
_ttfConfig(std::string_view filePath = {},
|
||||||
float size = CC_DEFAULT_FONT_LABEL_SIZE,
|
float size = CC_DEFAULT_FONT_LABEL_SIZE,
|
||||||
const GlyphCollection& glyphCollection = GlyphCollection::DYNAMIC,
|
const GlyphCollection& glyphCollection = GlyphCollection::DYNAMIC,
|
||||||
std::string_view customGlyphCollection = {},
|
const char* customGlyphCollection = nullptr, /* nullable */
|
||||||
bool useDistanceField = false,
|
bool useDistanceField = false,
|
||||||
int outline = 0,
|
int outline = 0,
|
||||||
bool useItalics = false,
|
bool useItalics = false,
|
||||||
|
@ -76,7 +76,7 @@ typedef struct _ttfConfig
|
||||||
: fontFilePath(filePath)
|
: fontFilePath(filePath)
|
||||||
, fontSize(size)
|
, fontSize(size)
|
||||||
, glyphs(glyphCollection)
|
, glyphs(glyphCollection)
|
||||||
, customGlyphs(customGlyphCollection)
|
, customGlyphs(customGlyphCollection ? customGlyphCollection : "")
|
||||||
, distanceFieldEnabled(useDistanceField)
|
, distanceFieldEnabled(useDistanceField)
|
||||||
, outlineSize(outline)
|
, outlineSize(outline)
|
||||||
, italics(useItalics)
|
, italics(useItalics)
|
||||||
|
|
Loading…
Reference in New Issue