Ticket #626 (closed defect: fixed)

Opened 8 years ago

Last modified 8 years ago

Newly opened images have wrong window size

Reported by: bdezonia Owned by: gharris
Priority: major Milestone: imagej2-b1-initial
Component: UI Framework Version:
Severity: serious Keywords:
Cc: Blocked By:
Blocking:

Description

Using 7feeec6da90f475fea86cb0e43bfca37dcdfb828: opening new Images results in the image area being a little too small and scrollbars being created.

Change History

comment:1 Changed 8 years ago by bdezonia

  • Owner changed from bdezonia to curtis
  • Status changed from new to assigned

Note that it used to be that the image was a little too big (see ticket #590). Maybe Curtis adjusted this recently. Reassigning to him for clarification.

comment:2 Changed 8 years ago by curtis

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

comment:3 Changed 8 years ago by bdezonia

There are a couple display size oriented bugs scheduled for alpha5. They may not be related but take a look at #605 and #627.

comment:4 Changed 8 years ago by curtis

  • Owner changed from curtis to gharris

comment:5 Changed 8 years ago by gharris

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

Turns out, we needed to add an override for Dimension getPreferredSize() in JHotDrawImageCanvas and add 4 to the w and h. (Don't ask me why it is 4.)

This was after many tests to figure out where the sizing was occurring. The UI component is many-layered (including JScrollPane, JPanel, Drawing, ...)

To do next: Account for the bounds of the desktop/workspace and the positioning of the
window therein... See new ticket #763.

comment:6 Changed 8 years ago by curtis

FYI, the value needed to be 5 to fix the problem on Mac OS X.

Note: See TracTickets for help on using tickets.