Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Display of pixel row/col by clicking in ND-window not functioning properly #40

Closed
tboggs opened this issue Feb 24, 2016 · 0 comments
Closed
Labels

Comments

@tboggs
Copy link
Member

tboggs commented Feb 24, 2016

When clicking on a pixel with CTRL+SHIFT in the ND-window display (after calling view_nd), the following exception is raised:

Traceback (most recent call last):
  File "/home/thomas/src/spectral/spectral/graphics/ndwindow.py", line 93, in left_down
    self.window.canvas.SetCurrent(self.canvas.context)
AttributeError: MouseHandler instance has no attribute 'canvas'

This is due not accessing the window canvas properly (should be self.window.canvas).

Furthermore, the pixel coordinate returned incorrectly has a floating point row value (should be int):

Pixel 10264 (70.786206896551718, 114) has class 0.

This was likely introduced when the file began using true division (by importing division from __future__).

@tboggs tboggs added the bug label Feb 24, 2016
@tboggs tboggs closed this as completed in 917ef58 Feb 24, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant