How do I paint Swing Components to a PDF file with iText?

后端 未结 3 948
北恋
北恋 2020-12-19 10:34

I would like to print my Swing JComponent via iText to pdf.

JComponent com = new JPanel();
com.add( new JLabel(\"hello\") );

PdfWriter writer = PdfWriter.g         


        
3条回答
  •  清酒与你
    2020-12-19 11:30

    I don't know that much about iText, but... you did close the PdfWriter at some point, right?

提交回复
热议问题