X-Git-Url: http://git.mutantstargoat.com/user/nuclear/?a=blobdiff_plain;ds=sidebyside;f=src%2Ffreeglut_menu.c;h=1f9a831918738747a0816606542d2a6cd2c44178;hb=36c6530f942007c5a72c6a3bd6d00077027d8c06;hp=bd945a76e19b6f2e37ef13cb8621e321a5e13e22;hpb=7d0fc844c337b9c8901317d6935c3462b59ceda5;p=freeglut diff --git a/src/freeglut_menu.c b/src/freeglut_menu.c index bd945a7..1f9a831 100644 --- a/src/freeglut_menu.c +++ b/src/freeglut_menu.c @@ -289,7 +289,7 @@ static void fghDisplayMenuBox( SFG_Menu* menu ) glVertex2i( menu->Width - border, border); glEnd( ); - glColor4fv( menu_pen_back ) ; + glColor4fv( menu_pen_back ); glBegin( GL_QUADS ); glVertex2i( border, border); glVertex2i( menu->Width - border, border); @@ -362,7 +362,8 @@ static void fghDisplayMenuBox( SFG_Menu* menu ) /* * Have the label drawn, character after character: */ - glutBitmapString( FREEGLUT_MENU_FONT, menuEntry->Text); + glutBitmapString( FREEGLUT_MENU_FONT, + (unsigned char *)menuEntry->Text); /* * If it's a submenu, draw a right arrow @@ -674,15 +675,20 @@ void fghCalculateMenuBoxSize( void ) /* * Update the menu entry's width value */ - menuEntry->Width = glutBitmapLength( FREEGLUT_MENU_FONT, - menuEntry->Text ); + menuEntry->Width = glutBitmapLength( + FREEGLUT_MENU_FONT, + (unsigned char *)menuEntry->Text + ); /* * If the entry is a submenu, then it needs to be wider to * accomodate the arrow. JCJ 31 July 2003 */ if (menuEntry->SubMenu ) - menuEntry->Width += glutBitmapLength( FREEGLUT_MENU_FONT, "_" ); + menuEntry->Width += glutBitmapLength( + FREEGLUT_MENU_FONT, + (unsigned char *)"_" + ); /* * Check if it's the biggest we've found