If I use the setRotation or setRotationDegrees methods the barcode
disappears completely from the page. Heres the code I'm using;
Barcode128 shipBarCode = new Barcode128();
shipBarCode.setX(0.75f);
shipBarCode.setN(1.5f);
shipBarCode.setChecksumText(true);
shipBarCode.setGenerateChecksum(true);
shipBarCode.setSize(10f);
shipBarCode.setTextAlignment(Element.ALIGN_CENTER);
shipBarCode.setBaseline(10f);
shipBarCode.setCode(data);
shipBarCode.setBarHeight(20f);
Image imgShipBarCode =
shipBarCode.createImageWithBarcode(cb, Color.black, Color.blue);
imgShipBarCode.setRotationDegrees(90);
PdfPCell shipment = new PdfPCell(new
Phrase(new Chunk(imgShipBarCode, 0, 0)));
shipment.setFixedHeight(shipBarCode.getBarcodeSize().height() + 16f);
shipment.setPaddingTop(5f);
shipment.setPaddingBottom(10f);
shipment.setBorder(PdfPCell.NO_BORDER);
shipment.setVerticalAlignment(Element.ALIGN_TOP);
shipment.setHorizontalAlignment(Element.ALIGN_CENTER);
cell.addCell(shipment);
pageTot.addCell(cell);
---------------------------------------------------------
Steve Simpson
Arriva Vehicle Rental
Tel : 0191 520 4029
Mob : 07917 268 934
For WebSphere support : [EMAIL PROTECTED]
-----Original Message-----
From: Bruno Lowagie [mailto:[EMAIL PROTECTED]
Sent: 04 November 2005 15:33
To: Steve Simpson (AVR IT Dept); '[email protected]'
Subject: Re: [iText-questions] Rotating bar codes
Steve Simpson (AVR IT Dept) wrote:
> Hi,
>
>
>
> I currently produce an agreement where we have a barcode in the bottom
> right hand corner of the page running left to right. I now want to
> move the barcode so that it runs down the right hand edge of the page
> - effectively rotated by 90 degrees.
>
>
>
> I can't find how to do this.
>
Are you getting the barcode as an Image object?
In that case, you can rotate it with setRotationDegrees(90)
and maybe use setAbsolutePosition to get it at the correct position.
br,
Bruno
**************************************************
Legal Disclaimer - Arriva plc
The contents of this e-mail are confidential and may be privileged and
protected by law and are intended solely for the use of the person to whom they
are addressed.
If you are not the intended recipient of this message please notify the sender
immediately, disclosure of its content to any other person is prohibited and
may be unlawful.
Please note that any views expressed in this e-mail may be those of the
originator and do not necessarily reflect those of this organisation.
Copyright in this e-mail and attachment(s) belongs to
Arriva plc.
Internet e-mail is not a secure communications medium.
Please note this lack of security when responding by e-mail. Accordingly, we
give no warranties or assurances about the safety and content of this e-mail
and its attachments.
Neither Arriva plc nor the sender accepts any responsibility for viruses and it
is your responsibility to scan the e-mail and attachments.
Any liability arising from any third party acting on any information contained
in this e-mail is hereby excluded.
**************************************************
-------------------------------------------------------
SF.Net email is sponsored by:
Tame your development challenges with Apache's Geronimo App Server. Download
it for free - -and be entered to win a 42" plasma tv or your very own
Sony(tm)PSP. Click here to play: http://sourceforge.net/geronimo.php
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions