ejeschke / ginga

The Ginga astronomical FITS file viewer
BSD 3-Clause "New" or "Revised" License
122 stars 77 forks source link

Ginga error when showBanner is enabled #229

Closed pllim closed 8 years ago

pllim commented 9 years ago

In ~/.ginga/general.cfg:

showBanner = True

Here is the error log:

...
2015-11-17 15:10:38,660 | I | Control.py:573 (load_image) | Loading image from .../ginga/icons/ginga-splash.ppm kwdargs={}
2015-11-17 15:10:38,671 | I | main.py:497 (main) | Entering mainloop...
2015-11-17 15:10:38,676 | I | Thumbs.py:144 (add_image) | making thumb for ginga-splash
2015-11-17 15:10:38,726 | I | Control.py:1001 (_switch_image) | Update image start
2015-11-17 15:10:38,727 | I | Control.py:1006 (_switch_image) | Setting image...
2015-11-17 15:10:38,733 | E | ImageView.py:1297 (_scale_to) | Scale (0.00) exceeds min scale limit (0.00)
2015-11-17 15:10:38,737 | I | WCSMatch.py:147 (new_image_cb) | Channel 'Ginga' setting image
2015-11-17 15:10:38,738 | I | Control.py:1014 (_switch_image) | executing redo() in plugins...
2015-11-17 15:10:38,739 | I | Control.py:1022 (_switch_image) | Large image update: 0.0120 sec
...
ejeschke commented 9 years ago

Does the banner otherwise show up ok?

pllim commented 9 years ago

Yes.

pllim commented 9 years ago

I traced this to a line in ImageView.zoom_fit():

wwidth, wheight = self.get_window_size()

where wwidth and wheight are both zeroes, which resulted in scalefactor, scale_x, and scale_y all being zeroes. For the record, width and height are both 1075.

All I did was starting Ginga with the banner, nothing else.

pllim commented 9 years ago

Also self.t_['scale_min'] is 1e-5.

pllim commented 9 years ago

With the latest dev version, the error is gone, but the banner is shown at a scale of 1/1075.00x by default, which effectively shows a blank screen on the main image display (although you can still see smaller versions of it under Info and Thumbs.

ejeschke commented 8 years ago

The banner seems to be showing up ok (at correct scale) in the latest versions of ginga. Is this still an issue, @pllim ?

pllim commented 8 years ago

Not an issue anymore. I fixed it in #244. Thanks for checking!