Public Member Functions | |
| __init__ (self, axes, frameSet, *, grid=False, useSexagesimal=False, extraOptions="") | |
| draw (self) | |
| setSexagesimal (self, useSexagesimal) | |
| remove (self) | |
Public Attributes | |
| list | artists = [] |
Protected Member Functions | |
| _plotOptions (self) | |
| _removeArtists (self) | |
| _onLimitsChanged (self, axes) | |
| _redrawNow (self) | |
Protected Attributes | |
| _axes = axes | |
| _frameSet = frameSet | |
| _grid = grid | |
| _useSexagesimal = useSexagesimal | |
| _extraOptions = extraOptions | |
| tuple | _savedVisibility |
| bool | _redrawing = False |
| _redrawTimer = None | |
| list | _callbackIds |
| _redrawNow = True | |
Static Protected Attributes | |
| int | _redrawDelayMs = 200 |
Manage AST-drawn sky coordinate axes on a matplotlib Axes.
All visible axis furniture (border, ticks, labels, optional grid)
is drawn by AST; matplotlib's own axis furniture is hidden while
this manager is active and restored by `remove`.
The axes' data coordinates must be pixel coordinates in the LSST
convention, matching the base frame of ``frameSet`` as produced by
`astFrameSetFromWcs`: the center of the first pixel of the parent
image is at (0, 0), and a subimage keeps its parent's coordinates
(its pixel coordinates start at the subimage's XY0, not at zero).
This differs from the FITS convention, in which the first pixel of
the image is centered at (1, 1).
Parameters
----------
axes : `matplotlib.axes.Axes`
The axes to draw on.
frameSet : `starlink.Ast.FrameSet`
Pixel-to-sky transform, base frame in axes data coordinates.
grid : `bool`, optional
Draw the full curvilinear coordinate grid across the image?
useSexagesimal : `bool`, optional
Format labels as e.g. HH:MM:SS.s rather than decimal degrees.
extraOptions : `str`, optional
Comma-separated AST Plot attribute settings appended after the
defaults, so they take precedence (e.g.
``"Colour(grid)=2, Width(border)=2"``).
Notes
-----
AST colour values are 1-based indices into the grf colour table
(see `starlink.Grf.grf_matplotlib`), not colour names:
1=default, 2=red, 3=green, 4=blue, 5=cyan, 6=magenta, 7=yellow,
8=black, 9=dark grey, 10=grey, 11=light grey, 12=white.
|
protected |
Schedule a redraw for new view limits; matplotlib callback. The redraw is debounced with a one-shot timer so that a stream of limit changes (interactive panning or zooming, or the x/y pair from a single zoom) produces a single rebuild once the view settles. Backends without a running event loop cannot fire timers, so there the redraw happens immediately.
|
protected |
Return the AST Plot options string for the current state.
|
protected |
Rebuild the AST axes for the current view and repaint.
|
protected |
Remove the AST artists from the axes.
| lsst.display.matplotlib.wcsAxes.WcsAxesManager.draw | ( | self | ) |
Draw (or redraw) the AST axes for the current view limits.
| lsst.display.matplotlib.wcsAxes.WcsAxesManager.remove | ( | self | ) |
Remove the AST axes and restore matplotlib's axis furniture.
| lsst.display.matplotlib.wcsAxes.WcsAxesManager.setSexagesimal | ( | self, | |
| useSexagesimal ) |
Switch between sexagesimal and decimal degree labels.
Parameters
----------
useSexagesimal : `bool`
Format labels as e.g. HH:MM:SS.s iff True.
|
protected |
|
protected |