[barcode] Bugfix for barcode-097 (pcl.c)
Christoph Pross
c.pross@beck-ipc.com
Tue, 6 Nov 2001 11:42:40 +0100
This message is in MIME format. Since your mail reader does not understand
this format, some or all of this message may not be legible.
------_=_NextPart_000_01C166AF.C1D95400
Content-Type: text/plain;
charset="iso-8859-1"
Dear Allessandro Rubini,
I used your barcode-Code and I think I found an error in
the pcl.c for generating PCL-Code.
The problem is, that the code from PS was copied. It seams, that if you want
to
draw a bar with PS you have to give the middle as starting point. In PCL you
have to provide the upper left corner.
As attachment, I'll send you a diff-file.
If you have any questions, don't hesitate to ask me.
Greetings
Christoph Pross
PS: I hope this is the right way to tell you about it, it is the first
time for me...
<<barcode-0.97.diff>>
------_=_NextPart_000_01C166AF.C1D95400
Content-Type: application/octet-stream;
name="barcode-0.97.diff"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: attachment;
filename="barcode-0.97.diff"
diff -urN barcode-0.97.orig/pcl.c barcode-0.97/pcl.c=0A=
--- barcode-0.97.orig/pcl.c Tue Oct 16 15:32:16 2001=0A=
+++ barcode-0.97/pcl.c Tue Nov 6 11:28:07 2001=0A=
@@ -131,7 +131,7 @@=0A=
if (isdigit (*ptr)) j =3D *ptr-'0';=0A=
else j =3D *ptr-'a'+1;=0A=
if (i%2) { /* bar */=0A=
- x0 =3D bc->xoff + xpos + (j*scalef)/2;=0A=
+ x0 =3D bc->xoff + xpos;=0A=
y0 =3D bc->yoff + bc->margin;=0A=
yr =3D bc->height;=0A=
if (!(bc->flags & BARCODE_NO_ASCII)) { /* leave space for =
text */=0A=
------_=_NextPart_000_01C166AF.C1D95400--