可以正常显示呀
参考http://javaboutique.internet.com/tutorials/Java_by_Example/section3_5.html//<applet code=Project10.class width=600 height=400>
//</applet>
import java.awt.*;
import java.applet.*;//you can easily load and display graphics in GIF and JPEG format
//GIFs with transparent colors are also supported!public class Project10 extends Applet
{
Image image = null;
public void init()
{
image = getImage(getCodeBase(), "duck.gif");
setBackground(Color.red);
} public void paint (Graphics g)
{
g.drawImage(image, 0, 0, this);
}
}其中图片为
http://javaboutique.internet.com/tutorials/Java_by_Example/duck.gif
参考http://javaboutique.internet.com/tutorials/Java_by_Example/section3_5.html//<applet code=Project10.class width=600 height=400>
//</applet>
import java.awt.*;
import java.applet.*;//you can easily load and display graphics in GIF and JPEG format
//GIFs with transparent colors are also supported!public class Project10 extends Applet
{
Image image = null;
public void init()
{
image = getImage(getCodeBase(), "duck.gif");
setBackground(Color.red);
} public void paint (Graphics g)
{
g.drawImage(image, 0, 0, this);
}
}其中图片为
http://javaboutique.internet.com/tutorials/Java_by_Example/duck.gif
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货