Package javax.microedition.lcdui

Examples of javax.microedition.lcdui.Graphics.fillRect()


    public void paint( Graphics graphics, final int x0, final int y0, int w, int h )
    {
        final Image buffer = Image.createImage( w, h );
        final Graphics g = buffer.getGraphics();
        g.setColor( 0xFFFFFF );
        g.fillRect( 0, 0, w, h );

        if( showLabel )
        {
            if( labelAbove )
            {
View Full Code Here


            {
                buffer = Image.createImage( getWidth(), height );
                g = buffer.getGraphics();
            }
            g.setColor( background );
            g.fillRect( 0, 0, getWidth(), getHeight() );
            if( mode == GRID )
            {
                paintGrid( g );
            }
            else
View Full Code Here

    public void repaint() {
        //Create base image for table
        iTable = Image.createImage(WIDTH, HEIGHT);
        Graphics gTable = iTable.getGraphics();
        //Fill background with black
        gTable.fillRect(0, 0, WIDTH, HEIGHT);

        if ((screenWidth >= 220) && (screenHeight >= 300)) {

            //Draw deck
            gTable.drawRegion(BACK_CARD, 0, 0, BACK_CARD.getWidth(),
View Full Code Here

                    int width = (numberOfCards < maxCardX)?(numberOfCards + 1) * WIDTH
                                :maxCardX * WIDTH;
                    rendered = Image.createImage(width, HEIGHT * 3);
                    gRender = rendered.getGraphics();
                    //Fill background with black color.
                    gRender.fillRect(0, 0, rendered.getWidth(), rendered.getHeight());

                    int card = 0;
                    int end = numberOfCards - 1;
                    int spacer = 0;
                    int atual = player.getAtualCardP();
View Full Code Here

                int width2 = (numberOfCards < 15)?(numberOfCards + 1) * WIDTH
                                :15 * WIDTH;
                rendered = Image.createImage(width2, HEIGHT*2);
                gRender = rendered.getGraphics();
                //Fill background with black color.
                gRender.fillRect(0, 0, rendered.getWidth(), rendered.getHeight());

                int max = (numberOfCards < 15)?numberOfCards:14;
                //Draw player
                for(int n = 0; n < max; n++) {

View Full Code Here

                int height = (numberOfCards < capacity)?(numberOfCards + 1) * WIDTH
                                                     : (capacity - 1) * WIDTH;
                rendered = Image.createImage(HEIGHT * 2, height);
                gRender = rendered.getGraphics();
                //Fill background with black color.
                gRender.fillRect(0, 0, rendered.getWidth(), rendered.getHeight());
               
                int max = (numberOfCards < capacity - 2)?numberOfCards:capacity - 2;
                for(int n = 0; n < max; n++) {

                    Image render = ((showFace)
View Full Code Here

    }

   public void refresh() {
      
       Graphics g = getGraphics();
       g.fillRect(0, 0, getWidth(), getHeight());

       drawTable(g);
       drawDirection(g);
       drawArrowAtualPlayer(g);
        //Refresh players
View Full Code Here

        final Graphics g = img.getGraphics();
        final int w = img.getWidth();
        final int h = img.getHeight();

        g.setColor(color_bg);
        g.fillRect(0, 0, w, h);

        //#debug
        AlbiteMIDlet.LOGGER.log("Drawing background on " + (BUFFER == null ? "canvas" : "BUFFER") + " from (0, 0) to (" + w + ", " + h + ") " + "using the colour " + Integer.toHexString(color_bg));

        page.draw(g, cp);
View Full Code Here

        final int h = img.getHeight();

        final int color_bg = cp.colors[ColorScheme.COLOR_BACKGROUND];

        g.setColor(color_bg);
        g.fillRect(0, 0, w, h);
       
        page.drawSelected(g, cp, firstElement, lastElement);

        renderRotate(img);
    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.