开发者

Text alignment in java printing

开发者 https://www.devze.com 2023-03-10 13:37 出处:网络
I am using 2d graphics to print the string on to the paper.开发者_JAVA技巧 I want the string to be aligned on the paper like right, left, centre. How can I do that ?basic Printing tutorial

I am using 2d graphics to print the string on to the paper.开发者_JAVA技巧 I want the string to be aligned on the paper like right, left, centre. How can I do that ?


basic Printing tutorial

EDIT: basic 2D Graphics stuff shows examples about PrinterJob, PrintJob and Print


After reviewing the tutorial, as @mKorbel suggests, you might look at this example that prints the date in the bottom right corner of each page.

0

精彩评论

暂无评论...
验证码 换一张
取 消