ÀÚ¹Ù¿¡¼­ÀÇ ÇÁ¸°Æ® ¹æ¹ý


[ Follow Ups ] [ Post Followup ] [ ÀÚ¹Ù ¹¯°í ´äÇϱâ ]

Posted by ¹é½Â¿ë on September 25, 1997 at 13:17:15:

In Reply to: [Áú¹®]ÀÚ¹Ù¿¡¼­ ÇÁ¸°ÅÍ ? posted by ±Ç°©»ó on September 25, 1997 at 01:03:24:

¿¹Á¦ ¼Ò½º¸¦ ¿Ã¸³´Ï´Ù.
¸¹Àº ÂüÁ¶ ¹Ù¶ø´Ï´Ù.


import java.awt.*;
import java.awt.event.*;


public class Print extends Frame
{
final static TextArea ta = new TextArea();
final static Print p = new Print();
static Button b = new Button("Print");


public static void main(String[] args)
{
p.add(ta, "Center");
p.add(b, "South");
p.setBounds(100,100,200,200);
p.setVisible(true);
}


public boolean action(Event e, Object o)
{
if(e.target == b) {
PrintJob job = p.getToolkit().getPrintJob(p,"TEST", null);


if (job!=null) {
Graphics g = job.getGraphics();
if(g!=null) {
ta.printAll(g);
g.dispose();
}
job.end();
}
return true;
} else return false;
}
}






Follow Ups:



À̾ ±Û¿Ã¸®±â(´äÇϱâ)

À̸§:
E-Mail:
Á¦¸ñ:
³»¿ë:
°ü·Ã URL(¼±ÅÃ):
URL Á¦¸ñ(¼±ÅÃ):
°ü·Ã À̹ÌÁö URL:


[ Follow Ups ] [ Post Followup ] [ ÀÚ¹Ù ¹¯°í ´äÇϱâ ]