Package org.eclipse.swt.graphics

Examples of org.eclipse.swt.graphics.GC.drawLine()


    gc.setForeground(fg);
    gc.drawLine(0 + off, 0 + off, size - 1 - off, size - 1 - off);
    gc.drawLine(1 + off, 0 + off, size - 1 - off, size - 2 - off);
    gc.drawLine(0 + off, 1 + off, size - 2 - off, size - 1 - off);
    gc.drawLine(size - 1 - off, 0 + off, 0 + off, size - 1 - off);
    gc.drawLine(size - 1 - off, 1 + off, 1 + off, size - 1 - off);
    gc.drawLine(size - 2 - off, 0 + off, 0 + off, size - 2 - off);
    /*
     * gc.drawLine(1, 0, size-2, 0); gc.drawLine(1, size-1, size-2, size-1);
     * gc.drawLine(0, 1, 0, size-2); gc.drawLine(size-1, 1, size-1, size-2);
     */
 
View Full Code Here


    gc.drawLine(0 + off, 0 + off, size - 1 - off, size - 1 - off);
    gc.drawLine(1 + off, 0 + off, size - 1 - off, size - 2 - off);
    gc.drawLine(0 + off, 1 + off, size - 2 - off, size - 1 - off);
    gc.drawLine(size - 1 - off, 0 + off, 0 + off, size - 1 - off);
    gc.drawLine(size - 1 - off, 1 + off, 1 + off, size - 1 - off);
    gc.drawLine(size - 2 - off, 0 + off, 0 + off, size - 2 - off);
    /*
     * gc.drawLine(1, 0, size-2, 0); gc.drawLine(1, size-1, size-2, size-1);
     * gc.drawLine(0, 1, 0, size-2); gc.drawLine(size-1, 1, size-1, size-2);
     */
    gc.dispose();
 
View Full Code Here

    gc.setAlpha(oldAlpha);
    gc.setAntialias(oldAnti);

    gc.setForeground(systemForeground);
    gc.drawLine(x, y, x, y + height - 1);
    gc.drawLine(x + width, y, x + width, y + height - 1);

    gc.setBackground(oldBackground);
    gc.setForeground(oldForeground);
  }
View Full Code Here

    gc.setAlpha(oldAlpha);
    gc.setAntialias(oldAnti);

    gc.setForeground(systemForeground);
    gc.drawLine(x, y, x, y + height - 1);
    gc.drawLine(x + width, y, x + width, y + height - 1);

    gc.setBackground(oldBackground);
    gc.setForeground(oldForeground);
  }
View Full Code Here

        gc.fillRectangle(0, 0, w, h);

        gc.setForeground(line);
        gc.setLineWidth(width);

        gc.drawLine(2, 2, 2, 4);
        gc.drawLine(2, 2, w - 2, 2);
        gc.drawLine(w - 2, 2, h - 2, 4);
        gc.drawLine(8, 2, 8, h - 2);
        gc.drawLine(4, h - 2, w - 4, h - 2);
View Full Code Here

        gc.setForeground(line);
        gc.setLineWidth(width);

        gc.drawLine(2, 2, 2, 4);
        gc.drawLine(2, 2, w - 2, 2);
        gc.drawLine(w - 2, 2, h - 2, 4);
        gc.drawLine(8, 2, 8, h - 2);
        gc.drawLine(4, h - 2, w - 4, h - 2);

        return descriptor(imageData, image, gc);
View Full Code Here

        gc.setForeground(line);
        gc.setLineWidth(width);

        gc.drawLine(2, 2, 2, 4);
        gc.drawLine(2, 2, w - 2, 2);
        gc.drawLine(w - 2, 2, h - 2, 4);
        gc.drawLine(8, 2, 8, h - 2);
        gc.drawLine(4, h - 2, w - 4, h - 2);

        return descriptor(imageData, image, gc);
    }
View Full Code Here

        gc.setLineWidth(width);

        gc.drawLine(2, 2, 2, 4);
        gc.drawLine(2, 2, w - 2, 2);
        gc.drawLine(w - 2, 2, h - 2, 4);
        gc.drawLine(8, 2, 8, h - 2);
        gc.drawLine(4, h - 2, w - 4, h - 2);

        return descriptor(imageData, image, gc);
    }
View Full Code Here

        gc.drawLine(2, 2, 2, 4);
        gc.drawLine(2, 2, w - 2, 2);
        gc.drawLine(w - 2, 2, h - 2, 4);
        gc.drawLine(8, 2, 8, h - 2);
        gc.drawLine(4, h - 2, w - 4, h - 2);

        return descriptor(imageData, image, gc);
    }

    public static void disable( ImageDescriptor descriptor ) {
View Full Code Here

        gc.fillRectangle(0, 0, w, h);

        gc.setBackground(line);
        gc.setForeground(line);
        gc.setLineWidth(width);
        gc.drawLine(1, h / 2, w - 1, h / 2);

        return descriptor(imageData, image, gc);
    }

    public static ImageDescriptor polygon( int lineColor, int fillColor, int width ) {
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.