Hi All,
I tried to set the PdfGState of a Graphic object with following code
PdfGState state = new PdfGState();
state.setBlendMode(PdfGState.BM_MULTIPLY);
state.setFillOpacity(0.8f);
g.setGState(state);
to change the blending mode to multiply with opacity set to 0.8f. I am trying to render a transparent polygon onto a Graphic created with
Graphic g = new Graphic();
However, I just get a null pointer exception throws inside of PdfContentByte as
Exception in thread "main" java.lang.NullPointerException
at com.lowagie.text.pdf.PdfContentByte.setGState(PdfContentByte.java:2647)
.........
Anyone have any ideas as to what I am doing wrong. I don't even know if this is the correct way to get transparent shapes or not :-/
Regards,
William Leeson
Software Development
PILZ Ireland Industrial Automation,
Business & Technology Park, Model Farm Road, Cork, Ireland.
Telephone +353 (021) 4804-982, Fax +353 (021) 4804-994
E-Mail: mailto:[EMAIL PROTECTED], Internet: http://www.pilz.ie
This email is intended solely for the use of the named addressee(s). Any unauthorised disclosure, copying or distribution of the confidential information contained therein, or the taking of any action based on it, is prohibited. The sender disclaims any liability for the integrity of this email. Legally binding declarations must be in written form.
- [iText-questions] Setting the PdfGState of a Graphic object W . Leeson
