NOTICE! This is a static HTML version of a legacy ImageJ Trac ticket.

The ImageJ project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Ticket #875 (closed defect: fixed)

Opened 2011-11-17T16:10:01-06:00

Last modified 2012-06-08T12:31:31-05:00

Exception thrown when creating overlays

Reported by: bdezonia Owned by: curtis
Priority: major Milestone: imagej2-b3-headless
Component: Data Model Version:
Severity: serious Keywords:
Cc: Blocked By:
Blocking:

Description

Open any image. Draw an overlay. Exception thrown:

Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException

at imagej.data.AbstractData.getDims(AbstractData.java:115)
at imagej.data.display.AbstractImageDisplay.getDims(AbstractImageDisplay.java:245)
at imagej.data.display.AbstractImageDisplay.getExtents(AbstractImageDisplay.java:285)
at imagej.data.display.AbstractImageDisplay.redoWindowLayout(AbstractImageDisplay.java:182)
at imagej.ui.swing.display.JHotDrawImageCanvas$3.overlayCreated(JHotDrawImageCanvas.java:243)
at imagej.ui.swing.roi.IJCreationTool.fireOverlayCreatedEvent(IJCreationTool.java:116)
at imagej.ui.swing.roi.IJCreationTool.creationFinished(IJCreationTool.java:130)
at org.jhotdraw.draw.tool.CreationTool.mouseReleased(CreationTool.java:262)

Change History

comment:1 Changed 2011-11-17T16:12:10-06:00 by bdezonia

Curtis and Barry discussed this. The issue is that AbstractOverlay::getExtents() always returns null. This is a consequence of a refactor and the fix is not immediately obvious.

comment:2 Changed 2012-02-27T11:00:59-06:00 by curtis

  • Milestone changed from imagej-2.0-beta1 to imagej-2.0-beta2

comment:3 Changed 2012-06-08T12:31:31-05:00 by curtis

  • Status changed from new to closed
  • Resolution set to fixed

There have been many changes since this ticket was filed, and the problem no longer occurs.