Date: 16 Dec 2002 20:59:18 -0000 From: Martin Klaffenboeck <martin.klaffenboeck@gmx.at> To: FreeBSD-gnats-submit@FreeBSD.org Cc: gnome@FreeBSD.org Subject: ports/46316: [gimp-devel] wrong eps Message-ID: <20021216205918.3662.qmail@httpd.terions.de>
next in thread | raw e-mail | index | archive | help
>Number: 46316 >Category: ports >Synopsis: [gimp-devel] wrong eps >Confidential: no >Severity: non-critical >Priority: medium >Responsible: freebsd-ports >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Mon Dec 16 13:00:06 PST 2002 >Closed-Date: >Last-Modified: >Originator: Martin Klaffenboeck >Release: FreeBSD 4.7-STABLE i386 >Organization: >Environment: System: FreeBSD martin.kleinerdrache.org 4.7-STABLE FreeBSD 4.7-STABLE #22: Sun Nov 24 21:48:56 CET 2002 martin@martin.kleinerdrache.org:/usr/obj/usr/src/sys/MYKERNEL i386 >Description: When you are creating eps files with a LC_NUMERIC setting where the comma is not a '.' you get a wrong eps file. The workarround is to get a correct eps file by starting gimp with LC_NUMERIC=C. Now we can use this patch so that gimp does not matter about the LC_LOCALE settings while creating eps files, they are now correct. See http://bugzilla.gnome.org/show_bug.cgi?id=101263 for more details. >How-To-Repeat: Can also be found on the bugzilla bug. >Fix: This file in ${PORTSDIR}/graphics/gimp-devel/files makes everything correct. I don't know if this needs a PORTEPOCH. --- patch-plug-ins_common_ps.c begins here --- --- plug-ins/common/ps.c.orig Tue Oct 8 12:53:10 2002 +++ plug-ins/common/ps.c Mon Dec 16 21:28:52 2002 @@ -1808,6 +1808,7 @@ double f1, f2, dx, dy; int xtrans, ytrans; int i_urx, i_ury; + char tmpbuf[G_ASCII_DTOSTR_BUF_SIZE]; /* initialize */ @@ -1865,7 +1866,8 @@ fprintf (ofp, "%%%%EndProlog\n"); fprintf (ofp, "%%%%Page: 1 1\n"); fprintf (ofp, "%% Translate for offset\n"); - fprintf (ofp, "%f %f translate\n", x_offset*72.0, y_offset*72.0); + fprintf (ofp, "%s", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), x_offset*72.0)); + fprintf (ofp, " %s translate\n", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), y_offset*72.0)); /* Calculate translation to startpoint of first scanline */ switch (psvals.rotate) @@ -1882,11 +1884,15 @@ break; } if ((dx != 0.0) || (dy != 0.0)) - fprintf (ofp, "%% Translate to begin of first scanline\n%f %f translate\n", - dx, dy); + { + fprintf (ofp, "%% Translate to begin of first scanline\n"); + fprintf (ofp, "%s", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), dx)); + fprintf (ofp, " %s translate\n", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), dy)); + } if (psvals.rotate) fprintf (ofp, "%d rotate\n", (int)psvals.rotate); - fprintf (ofp, "%f %f scale\n", 72.0*width_inch, -72.0*height_inch); + fprintf (ofp, "%s", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), 72.0*width_inch)); + fprintf (ofp, " %s scale\n", g_ascii_dtostr (tmpbuf, sizeof (tmpbuf), -72.0*height_inch)); /* Write the PostScript procedures to read the image */ if (psvals.level <= 1) --- patch-plug-ins_common_ps.c ends here --- >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20021216205918.3662.qmail>