Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Why drawString method cannot be print out?

 
kakashi blue
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
public void paint(Graphics g)
{
int currentFace = Font.FACE_SYSTEM;
int height = 0;
g.setColor(255,255,255);
g.fillRect(0, 0, getWidth(),30);

g.setFont(Font.getFont(currentFace,
Font.STYLE_PLAIN,
Font.SIZE_LARGE));
g.drawString("Regular plain", 0, height, Graphics.TOP|Graphics.LEFT);
height += g.getFont().getHeight();
}
What shld i do to print out the Regular plain?
 
Matthew Phillips
Ranch Hand
Posts: 2676
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It appears that you are working with an applet. I will move this post to the applets forum for you.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic