diff --git a/panda/src/text/default_font.cxx b/panda/src/text/default_font.cxx index 18bc5e5494..139d582435 100644 --- a/panda/src/text/default_font.cxx +++ b/panda/src/text/default_font.cxx @@ -18,7 +18,7 @@ #include "default_font.h" -#if defined(HAVE_FREETYPE) && defined(COMPILE_IN_DEFAULT_FONT) +#if defined(HAVE_FREETYPE) && defined(COMPILE_IN_DEFAULT_FONT) && !defined(CPPPARSER) // This file was generated from uhvr8ac.pfb, a PostScript Type1 font // installed along with TeX (and it was probably converted there from @@ -28,7 +28,7 @@ // This is used as a standard fallback font when no font file is // specified by the user. -const char default_font_data[] = { +const unsigned char default_font_data[] = { 0x80, 0x01, 0x6e, 0x06, 0x00, 0x00, 0x25, 0x21, 0x50, 0x53, 0x2d, 0x41, 0x64, 0x6f, 0x62, 0x65, 0x46, 0x6f, 0x6e, 0x74, 0x2d, 0x31, 0x2e, 0x30, 0x3a, 0x20, 0x4e, 0x69, 0x6d, 0x62, 0x75, 0x73, 0x53, @@ -3362,4 +3362,4 @@ const char default_font_data[] = { const int default_font_size = sizeof(default_font_data); -#endif // HAVE_FREETYPE && COMPILE_IN_DEFAULT_FONT +#endif // HAVE_FREETYPE && COMPILE_IN_DEFAULT_FONT && !CPPPARSER diff --git a/panda/src/text/default_font.h b/panda/src/text/default_font.h index 571fc66ae6..6326ba5e8b 100644 --- a/panda/src/text/default_font.h +++ b/panda/src/text/default_font.h @@ -21,12 +21,12 @@ #include "pandabase.h" -#if defined(HAVE_FREETYPE) && defined(COMPILE_IN_DEFAULT_FONT) +#if defined(HAVE_FREETYPE) && defined(COMPILE_IN_DEFAULT_FONT) && !defined(CPPPARSER) -extern const char default_font_data[]; +extern const unsigned char default_font_data[]; extern const int default_font_size; -#endif // HAVE_FREETYPE && COMPILE_IN_DEFAULT_FONT +#endif // HAVE_FREETYPE && COMPILE_IN_DEFAULT_FONT && !CPPPARSER #endif diff --git a/panda/src/text/textNode.cxx b/panda/src/text/textNode.cxx index 8ca8944444..8cf643eb6c 100644 --- a/panda/src/text/textNode.cxx +++ b/panda/src/text/textNode.cxx @@ -1316,7 +1316,8 @@ load_default_font() { // Then, attempt to load the compiled-in font, if we have one. #if defined(HAVE_FREETYPE) && defined(COMPILE_IN_DEFAULT_FONT) - _default_font = new DynamicTextFont(default_font_data, default_font_size, 0); + _default_font = new DynamicTextFont((const char *)default_font_data, + default_font_size, 0); if (_default_font->is_valid()) { return; }