*** ps_out_orig.c Tue Nov 2 10:34:58 2010 --- ps_out.c Tue Nov 2 11:08:36 2010 *************** *** 226,231 **** --- 226,256 ---- const char *string) { fprintf(getPsFile(ctx), + "%% white box behind '"); + writeEscaped(ctx, string); + fprintf(getPsFile(ctx), + "'\n" + "gsave\n" + "("); + writeEscaped(ctx, string); + fprintf(getPsFile(ctx), + ") stringwidth pop dup\n" + "newpath\n" + "1 setgray\n" + "%d %d 2 sub moveto\n" + "0 fontheight rlineto\n" + "0 rlineto\n" + "0 fontheight neg 1 add rlineto\n" + "neg 0 rlineto\n" + "fill\n" + "closepath\n" + "grestore\n", + x, -y - getSpace(ctx, PsHelvetica.descender)); + fprintf(getPsFile(ctx), + "%% string '"); + writeEscaped(ctx, string); + fprintf(getPsFile(ctx), "'\n"); + fprintf(getPsFile(ctx), "%d %d moveto (", x, -y - getSpace(ctx, PsHelvetica.descender)); writeEscaped(ctx, string); *************** *** 393,401 **** default: assert(0); } ! fprintf(context->of, "/Helvetica findfont\n"); ! fprintf(context->of, "%d scalefont\n", getPsCtx(ctx)->fontPoints); fprintf(context->of, "setfont\n"); } --- 418,426 ---- default: assert(0); } ! fprintf(context->of, "/fontheight %d def\n", getPsCtx(ctx)->fontPoints); fprintf(context->of, "/Helvetica findfont\n"); ! fprintf(context->of, "fontheight scalefont\n"); fprintf(context->of, "setfont\n"); } *************** *** 441,447 **** /* Write the header */ fprintf(context->of, "%%!PS-Adobe-3.0 EPSF-2.0\n" ! "%%%%BoundingBox: 0 0 %f %f\n", w * PS_OUT_SCALE, h * PS_OUT_SCALE); fprintf(context->of, "%%%%Creator: mscgen %s\n", PACKAGE_VERSION); fprintf(context->of, "%%%%EndComments\n"); --- 466,472 ---- /* Write the header */ fprintf(context->of, "%%!PS-Adobe-3.0 EPSF-2.0\n" ! "%%%%BoundingBox: 0 0 %d %d\n", w * PS_OUT_SCALE, h * PS_OUT_SCALE); fprintf(context->of, "%%%%Creator: mscgen %s\n", PACKAGE_VERSION); fprintf(context->of, "%%%%EndComments\n");