我现在用fastreport来做报表,发现在预览的时候会缺字,我也按网上的资料修改了frxGraphicUtils.pas并重新编译了,但还是有缺字,难道说这个BUG不好解决吗?有没有什么好的办法可以解决,我用的是4。2版本

解决方案 »

  1.   

    在编报表时,FONT中的CHARSET属性用GB2312_CHARSET,试试。
    可能是因为Fastreport4的DEFAULT_CHARSET字库使用上和windows系统有区别。也可以试试修改修改frxGraphicUtils.pas
    修改frxGraphicUtils.pas
    一、
    查找 "if (Win32Platform <> VER_PLATFORM_WIN32_NT) or (Canvas.Font.Charset <> DEFAULT_CHARSET) then"
    替换为 "if (Win32Platform <> VER_PLATFORM_WIN32_NT) or ((Canvas.Font.Charset <> DEFAULT_CHARSET) and (Canvas.Font.Charset <> GB2312_CHARSET)) then"二、
    查找 "if (C.Font.Charset = DEFAULT_CHARSET) and (Win32Platform = VER_PLATFORM_WIN32_NT) then"
    替换为 "if ((C.Font.Charset = DEFAULT_CHARSET) or (C.Font.Charset = GB2312_CHARSET)) and (Win32Platform = VER_PLATFORM_WIN32_NT) then"
    三、重新执行recompile.exe