public void update(Graphics g) { paint(g); }
public void update(Graphics g) { paint(g); }
@Override public void paint(Graphics g) { super.paint(g); drawOverlay(g); }
@Override public void paint(Graphics g) { super.paint(g); drawOverlay(g); }
public void paint(Graphics g) { super.paint(g); drawOverlay(g); }
public void paint(Graphics g) { super.paint(g); drawOverlay(g); }
public void paint(Graphics g) { if(backBufferWidth!=getSize().width || backBufferHeight!=getSize().height || backBufferImage==null || backBufferGraphics==null) resetBackBuffer(); super.paint(backBufferGraphics); drawOverlay(backBufferGraphics); g.drawImage(backBufferImage,0,0,this); }
@Override public void paint(final Graphics g) { if (backBufferWidth != getSize().width || backBufferHeight != getSize().height || backBufferImage == null || backBufferGraphics == null) resetBackBuffer(); super.paint(backBufferGraphics); drawOverlay(backBufferGraphics); g.drawImage(backBufferImage, 0, 0, this); }
@Override public void paint(final Graphics g) { super.paint(g); srcRect = getSrcRect(); double xM = 0; double yM = 0; final Graphics2D g2 = (Graphics2D) g; g2.setStroke(new BasicStroke(1f)); g2.setFont(font); final ListIterator<CellCntrMarkerVector> it = typeVector.listIterator(); while (it.hasNext()) { final CellCntrMarkerVector mv = it.next(); final int typeID = mv.getType(); g2.setColor(mv.getColor()); final ListIterator<CellCntrMarker> mit = mv.listIterator(); while (mit.hasNext()) { final CellCntrMarker m = mit.next(); final boolean sameSlice = m.getZ() == img.getCurrentSlice(); if (sameSlice || showAll) { xM = ((m.getX() - srcRect.x) * magnification); yM = ((m.getY() - srcRect.y) * magnification); if (sameSlice) g2.fillOval((int) xM - 2, (int) yM - 2, 4, 4); else g2.drawOval((int) xM - 2, (int) yM - 2, 4, 4); if (showNumbers) g2.drawString(Integer.toString(typeID), (int) xM + 3, (int) yM - 3); } } } }
public void paint(Graphics g) { if(backBufferWidth!=getSize().width || backBufferHeight!=getSize().height || backBufferImage==null || backBufferGraphics==null) resetBackBuffer(); int slice = imp.getCurrentSlice(); synchronized(this) { createContoursIfNotExist(slice); super.paint(backBufferGraphics); drawOverlay(backBufferGraphics,slice); } g.drawImage(backBufferImage,0,0,this); }
/** Remove "this" object as mouse listener and mouse motion * listener from the window with ID I. */ private void removeWindow(Integer I) { ImagePlus imp; ImageWindow iw; ImageCanvas ic; imp = WindowManager.getImage(I.intValue()); if (imp != null) { iw = imp.getWindow(); if (iw != null) { ic = iw.getCanvas(); if (ic != null) { ic.removeMouseListener(this); ic.removeMouseMotionListener(this); // Repaint to get rid of sync indicator. ic.paint(ic.getGraphics()); } } } }
/** Remove "this" object as mouse listener and mouse motion * listener from the window with ID I. */ private void removeWindow(Integer I) { ImagePlus imp; ImageWindow iw; ImageCanvas ic; imp = WindowManager.getImage(I.intValue()); if (imp != null) { iw = imp.getWindow(); if (iw != null) { ic = iw.getCanvas(); if (ic != null) { ic.removeMouseListener(this); ic.removeMouseMotionListener(this); // Repaint to get rid of sync indicator. ic.paint(ic.getGraphics()); } } } }
public void paint(Graphics g) { if(backBufferWidth!=getSize().width || backBufferHeight!=getSize().height || backBufferImage==null || backBufferGraphics==null) resetBackBuffer(); final Rectangle src = getSrcRect(); synchronized(this) { super.paint(backBufferGraphics); for (Overlay overlay : overlays) overlay.paint(backBufferGraphics, src.x, src.y, magnification); final Roi roi = super.imp.getRoi(); if(roi != null) roi.draw(backBufferGraphics); } g.drawImage(backBufferImage,0,0,this); }
ic = iw.getCanvas(); ic.paint(ic.getGraphics()); if(iw != iwc) { ic = iw.getCanvas();
ic = iw.getCanvas(); ic.paint(ic.getGraphics()); if(iw != iwc) { ic = iw.getCanvas();
imp.setPositionWithoutUpdate( channel, slice, frame + 1 ); final BufferedImage bi = new BufferedImage( width, height, BufferedImage.TYPE_INT_ARGB ); imp.getCanvas().paint( bi.getGraphics() ); final ColorProcessor cp = new ColorProcessor( bi ); final int index = imp.getStackIndex( channel, slice, frame );
antialiasRendering?RenderingHints.VALUE_ANTIALIAS_ON:RenderingHints.VALUE_ANTIALIAS_OFF); g.drawImage(getImage(), 0, 0, null); ic2.paint(g); imp2.flatteningCanvas = null; ImagePlus imp3 = new ImagePlus("Flat_"+getTitle(), new ColorProcessor(bi));
antialiasRendering?RenderingHints.VALUE_ANTIALIAS_ON:RenderingHints.VALUE_ANTIALIAS_OFF); g.drawImage(getImage(), 0, 0, null); ic2.paint(g); imp2.flatteningCanvas = null; ImagePlus imp3 = new ImagePlus("Flat_"+getTitle(), new ColorProcessor(bi));
canvas.paint(imageGfx);