python - Using pygame2exe and having font issue with sysfont/.ttf -


i tried py2exe, cx_freeze , got using site, made progress pygame2exe. read 2 or 3 other posts dealing this, despite having setup file same instructed, , putting in freesansbold.ttf still 'has requested runtime terminate in unusual way' error.

i go details, strange if set text standard thing "arial" suggested here (pygame distribution - runtime error) , app creates work, problem game rpg, , if text not freesanbold spills everywhere , unreadable, basicly have have text.

here how had font code initially: font=pygame.font.sysfont(none, 48) changed to: font=pygame.font.sysfont("freesansbold.ttf", 48) , included .ttf in folder, no avail. again if change 'arial' pygame2exe creates working file, need freesanbold because of text issues.

here pygame2exe code, copied wiki: def issystemdll(pathname): # checks if freetype , ogg dll files being included if os.path.basename(pathname).lower() in ("libfreetype-6.dll", "libogg-0.dll","sdl_ttf.dll"): # "sdl_ttf.dll" added arit. return 0 return origissystemdll(pathname) # return orginal function py2exe.build_exe.issystemdll = issystemdll # override default function one

i have tried putting .dlls in folder, nothing. super fix, have been @ days, , can't figure out.

likewise followed wiki (http://pygame.org/wiki/pygame2exe) here problem runtime error when .ttf file placed in folder.

i out of ideas, help...

i had same issue default system font. quite silly. ended using pygame.font.sysfont("arial", 16) worked without me having include anything.


Comments

Popular posts from this blog

Need help in packaging app using TideSDK on Windows -

java - Why does my date parsing return a weird date? -

plot - Remove Objects from Legend When You Have Also Used Fit, Matlab -