Examples of drawLine()


Examples of net.rim.device.api.ui.Graphics.drawLine()

        int x1 = width / 3;
        int x2 = x1 * 2;
        int y1 = height / 3;
        int y2 = y1 * 2;
        pen.setColor(Color.BLACK);
        pen.drawLine(x1, 0, x1, height);
        pen.drawLine(x2, 0, x2, height);
        pen.drawLine(0, y1, width, y1);
        pen.drawLine(0, y2, width, y2);
        return bg;
    }
View Full Code Here

Examples of net.sf.robocode.robotpaint.Graphics2DSerialized.drawLine()

    sg.setColor(Color.YELLOW);
    sg.draw(new Rectangle2D.Double(20, 20, 30, 50));

    sg.setColor(Color.BLACK);
    sg.drawLine(99, 3, 78, 3);
    sg.drawRect(90, 20, 30, 50);

    sg.setColor(Color.CYAN);

    sg.setStroke(new BasicStroke(1, 2, BasicStroke.JOIN_ROUND, 4, null, 0));
View Full Code Here

Examples of org.antlr.works.visualization.graphics.GContext.drawLine()

        context.setColor(context.linkColor);

        if(link.transition.isEpsilon()) {
            if(link.virtualPosition != null) {
                drawDownSloop(context, link, sx, sy, sx+sloopBaseWidth, link.getVirtualY());
                context.drawLine(sx+sloopBaseWidth, link.getVirtualY(), tx-sloopBaseWidth, link.getVirtualY());
                drawUpSloop(context, link, tx-sloopBaseWidth, link.getVirtualY(), tx, ty);
            } else if(sy > ty) {
                // Draw link upward
                if((tx-sx>sloopBaseWidth) && sloopBaseWidth>0) {
                    context.drawLine(sx, sy, tx-sloopBaseWidth, sy);
View Full Code Here

Examples of org.apache.fop.render.java2d.Java2DPainter.drawLine()

                g2d.translate(-boundingBox.x, -boundingBox.y);

                Java2DPainter painter = new Java2DPainter(g2d,
                        getContext(), parent.getFontInfo(), state);
                try {
                    painter.drawLine(start, end, width, color, style);
                } catch (IFException e) {
                    //This should never happen with the Java2DPainter
                    throw new RuntimeException("Unexpected error while painting a line", e);
                }
            }
View Full Code Here

Examples of org.apache.pdfbox.pdmodel.edit.PDPageContentStream.drawLine()

            contentStream.drawString( message);
            contentStream.moveTextPositionByAmount(100, 100);
            contentStream.drawString( message);
            contentStream.endText();
           
            contentStream.drawLine(startX-2, startY-2, startX-2, startY+200+fontSize);
            contentStream.drawLine(startX-2, startY+200+fontSize, startX+100+stringWidth+2, startY+200+fontSize);
            contentStream.drawLine(startX+100+stringWidth+2, startY+200+fontSize, startX+100+stringWidth+2, startY-2);
            contentStream.drawLine(startX+100+stringWidth+2, startY-2, startX-2, startY-2);
            contentStream.close();
View Full Code Here

Examples of org.apache.xmlgraphics.java2d.Graphics2DImagePainter.drawLine()

                g2d.translate(-boundingBox.x, -boundingBox.y);

                Java2DPainter painter = new Java2DPainter(g2d,
                        getContext(), parent.getFontInfo(), state);
                try {
                    painter.drawLine(start, end, width, color, style);
                } catch (IFException e) {
                    //This should never happen with the Java2DPainter
                    throw new RuntimeException("Unexpected error while painting a line", e);
                }
            }
View Full Code Here

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

      gcImage.setForeground(Colors.grey);
      if (borderHorizontalSize > 0) {
        if (borderVerticalSize > 0) {
          gcImage.drawRectangle(0, 0, newWidth - 1, newHeight - 1);
        } else {
          gcImage.drawLine(0, 0, newWidth - 1, 0);
          gcImage.drawLine(0, newHeight -1, newWidth - 1, newHeight - 1);
        }
      } else if (borderVerticalSize > 0) {
        gcImage.drawLine(0, 0, 0, newHeight - 1);
        gcImage.drawLine(newWidth - 1, 0, newWidth - 1, newHeight - 1);
View Full Code Here

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

      if (borderHorizontalSize > 0) {
        if (borderVerticalSize > 0) {
          gcImage.drawRectangle(0, 0, newWidth - 1, newHeight - 1);
        } else {
          gcImage.drawLine(0, 0, newWidth - 1, 0);
          gcImage.drawLine(0, newHeight -1, newWidth - 1, newHeight - 1);
        }
      } else if (borderVerticalSize > 0) {
        gcImage.drawLine(0, 0, 0, newHeight - 1);
        gcImage.drawLine(newWidth - 1, 0, newWidth - 1, newHeight - 1);
      }
View Full Code Here

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

        } else {
          gcImage.drawLine(0, 0, newWidth - 1, 0);
          gcImage.drawLine(0, newHeight -1, newWidth - 1, newHeight - 1);
        }
      } else if (borderVerticalSize > 0) {
        gcImage.drawLine(0, 0, 0, newHeight - 1);
        gcImage.drawLine(newWidth - 1, 0, newWidth - 1, newHeight - 1);
      }

      if (borderSplit > 0) {
        gcImage.setForeground(Colors.white);
View Full Code Here

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

          gcImage.drawLine(0, 0, newWidth - 1, 0);
          gcImage.drawLine(0, newHeight -1, newWidth - 1, newHeight - 1);
        }
      } else if (borderVerticalSize > 0) {
        gcImage.drawLine(0, 0, 0, newHeight - 1);
        gcImage.drawLine(newWidth - 1, 0, newWidth - 1, newHeight - 1);
      }

      if (borderSplit > 0) {
        gcImage.setForeground(Colors.white);
        gcImage.drawLine(x0, completionHeight + borderHorizontalSize,
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.