How to make the PNG image cover the display?
I have a general problem with PNG images. When I create a Canvas which only purpose is to display a splash screen there is a title in top of the screen with the appication name.
I want the picture to cover the complete screen. Instead there is a title on top of the page and then the picture.
My code looks like!
public class IntroCanvas extends Canvas implements CommandListener
private Image splash;
private TestMIDlet parent;
public IntroCanvas(TestMIDlet parent)
this.parent = parent;
splash = Image.createImage("/TestScreen.png");
catch (Exception e)
protected void paint( Graphics p1 )
p1.drawImage(splash, 0, 0, Graphics.TOP | Graphics.LEFT);
public void commandAction( Command p1, Displayable p2 )
What am I doing wrong?
Very simple answer:
You are using Canvas
You need to use FullCanvas
You see, Canvas() includes the title at the top - you cannot get rid of that... unless you use FullCanvas() which gives you control of the entire screen!
Thanks a lot. I was going crazy before, but not it works perfect (using FullCanvas)!!!